I'm having a problem with the Gallery extension:
When setting up a new site most deployment related rake tasks stop
working if your Radiant app contains the Gallery extension.
This happends because of the first statement in the GalleryItem class
(vendor/extensions/gallery/app/models/gallery_item.rb):
has_attachment :storage => :file_system,
:path_prefix => Radiant::Config["gallery.path_prefix"],
:processor => Radiant::Config["gallery.processor"]
As you can see in the above code, the Gallery extension uses the
has_attachment plugin. When setting up the ruby environment the
gallery_item.rb file is loaded and the above code is executed. When
executed it makes a call to the "[]" method in Radiants config.rb
which in turn tries to find the key "gallery.path_prefix" in the
database by calling "find_by_key(key)". This fails with the message:
Mysql::Error: Table 'radiant.config' doesn't exist: SHOW FIELDS
FROM `config`
This is because the config table has not yet been created (remember
we are setting up a brand new site and have not run the db:bootstrap
rake task yet).
Whos fault is this?
Is it the Gallery extension that must check to see if the config
table exists? Or is it the config handler in Radiant that should make
this check?
I'll happely fix and submit a patch for this "bug", but need to hear
what you guys think is the best solution.
/watson
_______________________________________________
Radiant mailing list
Post: Radiant@radiantcms.org
Search: http://radiantcms.org/mailing-list/search/
Site: http://lists.radiantcms.org/mailman/listinfo/radiant