Another Edge Rails Issue (Sorry)


#1

I know that this general topic has been covered a lot in on this list,
so I apologize for adding another, but this problem seems to be slightly
different from what others have experienced.

Like everyone else, I’m trying to get engines working with edge rails.
I’ve obtained the trunk brach of the engines, login_engine, and
user_engine plugins (tried various ways with the same result - svn
checkout, svn export, script\plugin
–source=http://svn.rails-engines.org/engines/trunk/ install engines,
svn externals, etc.). I have the lines:

module Engines
CONFIG={:edge => true}
end

at the very top of environment.rb, before anything else. I have
revision 309 of the engines/login_engine/user_engine plugins. However,
whenever I attempt to do a rake engine_info or engine_migrate, I get the
“undefined method ‘log’ for Engines:module” error message from rake in
dependencies_extensions.rb:28. I’ve been wrestling with this for the
better part of a day now, and I’ve tried everything I could think of,
including clearing out my local plugin directories, using the different
methods of getting them listed above, googling, etc., to no avail. Any
suggestions on what I could be messing up?

Jay


#2

I should add two things that might help narrow this down. One, I found
this link while googling:

http://www.freeonrails.com/node/228

It seems like the same issue, but it doesn’t seem like he managed to
find a solution either.

Also, when I try changing the first three lines in environment.rb to

Engines.config :edge, true

I get the error “uninitialized constant Engines” from rake.


#3

Hi

Engines.config won’t work at the very top of environment.rb, since
that syntax requires the plugin to be loaded, and at that point Rails
itself has barely started. You need to more verbose version:

module Engines
CONFIG={:edge=>true}
end

Since you’re using revision 309 of the engines trunk, you should see
in the README that the syntax for the engines rake tasks has changed
to fall in line with the new Rake namespacing that Rails has adopted.
Technically you should be getting the error:

Don’t know how to build task ‘engines_info’

This pretty much indicates that you don’t have the latest version of
the engines plugin. Please double check your SVN urls, and check the
README or the engines.rake file for the new tasks.

… ain’t edge fun :slight_smile:

  • james

On 3/24/06, Jay removed_email_address@domain.invalid wrote:

Engines.config :edge, true

I get the error “uninitialized constant Engines” from rake.


Posted via http://www.ruby-forum.com/.


engine-users mailing list
removed_email_address@domain.invalid
http://lists.rails-engines.org/listinfo.cgi/engine-users-rails-engines.org

  • J *
    ~

#4

I just pulled out a lot of air over this as well, and I just fixed it.

My error was that I checked out

http://svn.rails-engines.org/plugins/engines

assuming that this was the latest edge engines. It is not. (I swear I
read somewhere on the engines site that it is an alias for the
latest…)

To use engines with rails edge, you need to check out

http://svn.rails-engines.org/engines/trunk

But you refrenced the correct url in your message, so i’m not sure. I
would make sure your plugins directory is completely clean, and let svn
know it is clean, then check out the engines trunk again.

If you have the correct version, you should see stuff like this in the
vendor/plugins/engines/lib directory:

bundles bundles.rb engines engines.rb

The old (stable) engines only has ‘engines engines.rb’.

Good luck…

Patrick

Jay wrote:

I know that this general topic has been covered a lot in on this list,
so I apologize for adding another, but this problem seems to be slightly
different from what others have experienced.

Like everyone else, I’m trying to get engines working with edge rails.
I’ve obtained the trunk brach of the engines, login_engine, and
user_engine plugins (tried various ways with the same result - svn
checkout, svn export, script\plugin
–source=http://svn.rails-engines.org/engines/trunk/ install engines,
svn externals, etc.). I have the lines:

module Engines
CONFIG={:edge => true}
end

at the very top of environment.rb, before anything else. I have
revision 309 of the engines/login_engine/user_engine plugins. However,
whenever I attempt to do a rake engine_info or engine_migrate, I get the
“undefined method ‘log’ for Engines:module” error message from rake in
dependencies_extensions.rb:28. I’ve been wrestling with this for the
better part of a day now, and I’ve tried everything I could think of,
including clearing out my local plugin directories, using the different
methods of getting them listed above, googling, etc., to no avail. Any
suggestions on what I could be messing up?

Jay