similar to: Couldn't reload a module when it's changed. Tried :require_dependency, :watchable_dirs, :unloadable

Displaying 20 results from an estimated 700 matches similar to: "Couldn't reload a module when it's changed. Tried :require_dependency, :watchable_dirs, :unloadable"

2012 Apr 07
3
Is require_dependency supposed to be a public API?
If so, shouldn''t it be documented in the Rails API? Or is there a better way to allow class reloading of my files under lib. I mean, I know about config.autoload_paths, but I want to be explicit about my requires. I just want to be able to reload then on each request when I''m working on them. require_dependency seems to do just that but I''m worried since it is not
2007 Mar 13
0
aliasing, require_dependency and require
I''d really appreciate it if someone [with a decent understanding of the rails Dependencies mechanism] could help me explain the behaviour seen in this pastie. http://pastie.caboo.se/46630 The desired behaviour is simply aliasing a method in ApplicationController from a plugin while retaining automatic reloading in dev mode. The pastie is basically divided into 4 parts: - Setup of
2008 Nov 03
1
concerned_with, and maybe require_dependency issues only when running specs?
Hi all, So in the interests of keeping a few areas of my code a bit under control, I''ve been investigating the concept of "concerned_with" as described here: http://paulbarry.com/articles/2008/08/30/concerned-with-skinny-controller-skinny-model Basically allowing me to have: /app/models/user.rb class User < ActiveRecord::Base concerned_with :something end
2005 Sep 27
5
Am I misunderstanding "require_dependency"?
Hi From what I understand about documentation about require_dependency, this function will work like require but the file will be reloaded on every request to the server when in development mode. I have bootstrapped am minimal RoR project with 0.13.1 Rails. I have created a minimal Controller and hooked up it''s "index" action at the site root. I have also created a
2011 Feb 04
6
A plugin inside an engine
In Rails 3, is it possible to have a plugin inside an engine? Adding the lib dir of the plugin to autoload_paths doesn''t seem to work. I can manage to load it by adding that path to $: and requiring the init.rb file, but I''m not sure that''s the correct approach. Thanks! -- You received this message because you are subscribed to the Google Groups "Ruby on Rails:
2007 Nov 28
8
include vs. require vs. require_dependency
i am struggling a bit with all of them .. could someone be so nice a describe me the exact differences, pros & cons of all of them ... thx a lot! -- Posted via http://www.ruby-forum.com/. --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to
2006 Aug 10
6
Migrations suddenly broken: undefined method autoload_paths
I really need some help here because I am at a loss. I have been using migrations just fine now for a while and I suddenly started getting a very bizarre error when migrations are run: undefined method `autoload_paths='' for Dependencies:Module I have tried rolling back my application code, and rolling back the rails edge revision I am running but neither seem to help. I have
2012 Jul 12
1
engines: accessing classes from the hosting-apps lib
I have an engine and can access model-classes of the hosting app without any troubles. But when I try to access classes that are defined in the lib-directory of the hosting app, they are not found and I get a uninitialized constant Redmine where Redmine is a module defined in the lib-directory of the hosting app. The lib-directory has added this dir to the autoload_paths, but the engine
2010 Jul 27
4
Ruby on Rails 3 RC and files in "lib" directory
In Rails 3b4 my ruby files in the lib directory of my application were automaticaly loaded/required. In Rails 3rc1, there are not anymore. Is this normal? Where is the commit that changed this? What is the best prefered way to load the files in "lib"? Thanks for your answers. Nicolas. -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed
2010 Aug 17
6
Overly aggressive constant unloading of Rails 3.0
In Rails 3.0 (both RC and edge), any constant that''s defined while loading a file in development mode will get unloaded on each request, regardless of whether it comes from an autoload path in the application or from external code such as a gem. Example file (tested on a fresh edge app): # kittens.rb require ''nibbler/json'' # "nibbler" is a gem specified
2012 Oct 21
1
load_missing_constant
I have a model ''site'' defined in a sub-folder ''cms'' class Cms::Site < ActiveRecord::Base ..... the model is loaded correctly , checked in console: application.rb config.autoload_paths += Dir["#{config.root}/app/models/**/"] console >Cms::Site.all => [] Now trying to access this model from a sites_controller ( in backoffice/cms
2010 Mar 01
4
Dependency loading confusion
Hey guys, I have a module Foo::Bar, which extends ActiveRecord::Base with some custom functionality. This module is in lib/foo/bar.rb. Inside this file is also the code, that includes the module into ActiveRecord::Base: module Foo module Bar # stuff ... end end ActiveRecord::Base.send(:include, Foo::Bar) Then, this file is required in config/initializers/foo.rb:
2012 Nov 06
1
Understanding the Rails /lib/ Directory
I am trying to learn how the Rails /lib/ directory works - and how to reference variables defined in a file placed in the the /lib/ directory for use in a View. I have a file called helloworld.rb and it''s saved in the /lib/ directory in my Rails application. The helloworld.rb file has the following code: module HelloWorld def hello @howdy = "Hello World!"
2003 Jul 12
2
usb.ko is unloadable?
Dear colleagues, I'm planning to debug usb connection with my new SONY CLIE handheld, and found that this process is much complicated by the fact usb.ko module can not be unloaded 'cause some process is referencing it: marck@revamp:~/tmp> kldstat -v -i 11 Id Refs Address Size Name 11 1 0xc0cf7000 1b000 usb.ko Contains modules: Id Name
2019 Oct 17
2
llvm-strip creates unloadable shared objects on linux-armv7hf
Hello, Recently we tried to streamline our toolchain by removing some GNU tools with LLVM tools to avoid having multiple copies of strip, nm, ar and similar tools. Today we ran into a really strange issue where shared objects where not loadable. We where able to track this down to llvm-strip with default arguments creating a shared object that doesn't load correctly. It works if we switch
2012 Jun 08
1
Rspec include paths
''m using rspec 2.10 with Rails 3.2.1 and have problems with classes not being found. I have put a class called DbTasks under a dir app/util. Under spec, i''ve created file util/db_tasks_spec.rb which runs afer i included the line: require File.join(File.dirname(FILE), ''../../app/util/db_tasks'') However, rspec now isn''t able to find my models. I
2010 Sep 30
3
Plugins Not Loading
Hi. I''m running Rails 3.0 on Mac OS X, and I''m trying to get the acts_as_list, other plugins, as well as libraries running. From what I understand, rails should be loading those automatically once placed in the proper directories. However, that is not happening in my case, and I''m getting errors such as "undefined method `acts_as_list'' for
2010 Nov 05
4
Inheritance alternative
I have to objects with common functionalities and a lot of difference. So I want that each have his own table but inherit the common functionalities from a parent class. How can I do this in Rails ? -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to
2019 Oct 17
4
llvm-strip creates unloadable shared objects on linux-armv7hf
Hello Rui, Thanks for your reply. I tried with the keep-section argument and that made the shared library work. Should these sections be kept around by default maybe? -- Tobias On Thu, Oct 17, 2019 at 11:06 AM Rui Ueyama <ruiu at google.com> wrote: > > One thing I noticed is that llvm-strip seemed to remove a .ARM.attributes section. Can you try --keep-section=.ARM.attributes to
2019 Oct 17
2
llvm-strip creates unloadable shared objects on linux-armv7hf
Hello Tobias, I think that looks reasonable to me, I think it will be down to the llvm-objcopy team whether they want to make .ARM.attributes a special case or not. The best way to find out is to submit a patch, citing the problems with old versions of libc, I'd expect that you'll need to add a test case for the patch to be accepted. To do that it is probably best to look at the existing