It looks to me like you need to run `rake db:migrate` (step 4 on the Updating card). The error suggests that the table still has a "type" field, but if the migrations were successful, that field would now be called "typecode".
That particular migration is small, but the permissions migrations involved in this upgrade are more dramatic and may take quite a while, depending on the size of your database.
I did try to re-run upgrading & cache:clear but did not produce any log. It produces the same error as before.
I have run all the scripts as written on that card.
--tukanos (Not signed in).....Thu Nov 03 10:11:29 -0700 2011
the migrate command didn't produce any output at all? that's odd.
Can you look for two things in the database:
1. does the cards table have a "typecode" field?
2. what do you get when you run this: "select max(version) from schema_migrations;"?
--Ethan McCutchen.....Thu Nov 03 10:34:14 -0700 2011
Hello Ethan,
nice to see you again.
The attribute "typecode" is not n the cards table.
This is the complete list of card table's attributes with definitions:
id int(11)
trunk_id int(11)
created_at datetime
updated_at datetime
current_revision_id int(11)
name varchar(255)
type varchar(255)
extension_id int(11)
extension_type varchar(255)
created_by int(11)
updated_by int(11)
reader_id int(11)
reader_type varchar(255)
tag_id int(11)
key varchar(255)
trash tinyint(1)
appender_type varchar(255)
appender_id int(11)
references_expired int(11)
indexed_name text
indexed_content text
settings varchar(255)
codename varchar(255)
pattern_keys varchar(255)
The result of the select (SELECT max( version ) FROM schema_migrations ):
max(version)
20110511221913
--Tukanos (Not signed in).....Fri Nov 04 02:55:16 -0700 2011
Hmm. The issue is clearly that the migration is not running. Both of those results indicate that.
What exactly do you see when you run `rake db:migrate`? Nothing at all? What if you run `bundle exec rake db:migrate --trace` ?
--Ethan McCutchen.....Sat Nov 19 12:11:42 -0800 2011
I don't really get why the migration process did not proceed as everything looks fine.
This is what I get when I run the rake & bundle.
[heze]$ rake db:migrate
rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
Running without hoptoad
----------- Wagn Loaded -----------
[heze]$ bundle exec rake db:migrate --trace
rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
Running without hoptoad
** Invoke db:migrate (first_time)
** Invoke environment (first_time)
** Invoke setup (first_time)
** Execute setup
** Execute environment
----------- Wagn Loaded -----------
** Execute db:migrate
** Invoke db:schema:dump (first_time)
** Invoke environment
** Execute db:schema:dump
--Tukanos.....Thu Nov 24 10:27:44 -0800 2011
Hi Ethan,
I concluded during my search that something must have gone wrong during the update process so I decided to recover my wagn from backup (yes, actually have one ;) and start all over again.
So this is a complete report what I have found:
I)
[]$ git pull git://github.com/wagn/wagn.git master
From git://github.com/wagn/wagn
* branch master -> FETCH_HEAD
Updating b1d8ae7..fb6fd20
error: Your local changes to 'config/environment.rb' would be overwritten by merge. Aborting.
Please, commit your changes or stash them before you can merge.
-----------------------------------------------------------------------------------------
[]$ diff environment.rb $HOME/source/wagn-1.6.0/config/environment.rb
5c5
< ENV['RAILS_ENV'] ||= 'production'
---
> # ENV['RAILS_ENV'] ||= 'production'
41d40
< ENV['LD_LIBRARY_PATH']=":{homedir}/.packages/include:{homedir}/.packages/lib"
=> So delted the env file and tagged the # production line. So the pull went fine 454 files changed, 35021 insertions(+), 40803 deletions(-)
II) These are the rake tasks executed:
[heze]$ rake db:migrate
rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
Running without hoptoad
----------- Wagn Loaded -----------
== AddReaderSettingFields: migrating =========================================
-- add_column(:cards, :read_rule_class, :string)
-> 2.0609s
-- add_column(:cards, :read_rule_id, :integer)
-> 0.9382s
== AddReaderSettingFields: migrated (2.9994s) ================================
== TypeToCardtype: migrating =================================================
-- rename_column(:cards, :type, :typecode)
-> 0.4105s
== TypeToCardtype: migrated (0.4106s) ========================================
== PermissionsIntoSettings: migrating ========================================
-- execute("update cards set extension_type=null where extension_type in('SoftTemplate','HardTemplate')")
-> 0.1617s
-- execute("update cards set typecode='Basic' where not exists (select * from cardtypes where class_name = typecode)")
-> 0.1770s
- create rule for *star, CREATE: Administrator
- create rule for *rstar, CREATE: Administrator
- create rule for HTML+*type, CREATE: Administrator
- create rule for Cardtype+description+*type plus right, CREATE: Administrator
- create rule for *star, UPDATE: Administrator
- create rule for *rstar, UPDATE: Administrator
- create rule for HTML+*type, UPDATE: Administrator
- create rule for Cardtype+description+*type plus right, UPDATE: Administrator
- create rule for *star, DELETE: Administrator
- create rule for *rstar, DELETE: Administrator
- create rule for HTML+*type, DELETE: Administrator
- create rule for Cardtype+description+*type plus right, DELETE: Administrator
- create rule for *watcher+*right, CREATE: Anyone Signed In
- create rule for *watcher+*right, UPDATE: Anyone Signed In
updating *all for create
- create rule for *all, CREATE: Anyone Signed In
- create rule for *all plus, CREATE: _left
updating *all for read
- create rule for *all, READ: Anyone
- create rule for *all plus, READ: _left
-- execute("update cards set read_rule_id=561, read_rule_class='*all' where trash is false and tag_id is null")
-> 0.0740s
-- execute("update cards set read_rule_id=561, read_rule_class='*all plus' where trash is false and tag_id is not null")
-> 0.0984s
updating *all for edit
- create rule for *all, EDIT: Anyone Signed In
- create rule for *all plus, EDIT: _left
updating *all for delete
- create rule for *all, DELETE: Anyone Signed In
- create rule for *all plus, DELETE: _left
updating *all for comment
- create rule for *all, COMMENT:
updating types for create
- create rule for Role+*type, CREATE: Administrator
- create rule for Account Request+*type, CREATE: Anyone
creating *type set perms
creating *right set perms
- create rule for *plus cards+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=571, read_rule_class='*right' where trash is false and tag_id=33")
-> 0.0312s
- create rule for *plus parts+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=572, read_rule_class='*right' where trash is false and tag_id=35")
-> 0.0323s
- create rule for *includers+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=573, read_rule_class='*right' where trash is false and tag_id=37")
-> 0.0260s
- create rule for *linkers+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=574, read_rule_class='*right' where trash is false and tag_id=39")
-> 0.0418s
- create rule for *inclusions+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=575, read_rule_class='*right' where trash is false and tag_id=41")
-> 0.0372s
- create rule for *links+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=576, read_rule_class='*right' where trash is false and tag_id=43")
-> 0.0346s
- create rule for *editors+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=577, read_rule_class='*right' where trash is false and tag_id=92")
-> 0.0320s
- create rule for *editing+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=578, read_rule_class='*right' where trash is false and tag_id=138")
-> 0.0304s
- create rule for *roles+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=579, read_rule_class='*right' where trash is false and tag_id=96")
-> 0.0342s
- create rule for *members+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=580, read_rule_class='*right' where trash is false and tag_id=98")
-> 0.0340s
- create rule for *plusses+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=581, read_rule_class='*right' where trash is false and tag_id=110")
-> 0.0300s
- create rule for *community+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=582, read_rule_class='*right' where trash is false and tag_id=115")
-> 0.0232s
- create rule for *account+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=583, read_rule_class='*right' where trash is false and tag_id=100")
-> 0.0294s
- create rule for discussion+*right, COMMENT: Anyone
- create rule for *outgoing+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=585, read_rule_class='*right' where trash is false and tag_id=168")
-> 0.0455s
- create rule for *incoming+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=586, read_rule_class='*right' where trash is false and tag_id=170")
-> 0.0393s
- create rule for *tagged+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=587, read_rule_class='*right' where trash is false and tag_id=172")
-> 0.0656s
- create rule for by update+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=588, read_rule_class='*right' where trash is false and tag_id=178")
-> 0.0526s
- create rule for by name+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=589, read_rule_class='*right' where trash is false and tag_id=184")
-> 0.0327s
- create rule for by create+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=590, read_rule_class='*right' where trash is false and tag_id=190")
-> 0.0364s
- create rule for *watching+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=591, read_rule_class='*right' where trash is false and tag_id=222")
-> 0.0313s
- create rule for *right+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=592, read_rule_class='*right' where trash is false and tag_id=260")
-> 0.0926s
- create rule for *type plus right+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=593, read_rule_class='*right' where trash is false and tag_id=262")
-> 0.0439s
- create rule for *self+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=594, read_rule_class='*right' where trash is false and tag_id=264")
-> 0.0578s
- create rule for *type+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=595, read_rule_class='*right' where trash is false and tag_id=266")
-> 0.0514s
- create rule for email config+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=596, read_rule_class='*right' where trash is false and tag_id=371")
-> 0.0544s
- create rule for watcher instructions for related tab+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=597, read_rule_class='*right' where trash is false and tag_id=397")
-> 0.0557s
- create rule for *count+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=598, read_rule_class='*right' where trash is false and tag_id=419")
-> 0.1293s
- create rule for *last edited+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=599, read_rule_class='*right' where trash is false and tag_id=425")
-> 0.0936s
- create rule for *creator+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=600, read_rule_class='*right' where trash is false and tag_id=428")
-> 0.0925s
- create rule for *created+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=601, read_rule_class='*right' where trash is false and tag_id=431")
-> 0.0352s
- create rule for *when created+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=602, read_rule_class='*right' where trash is false and tag_id=435")
-> 0.0603s
- create rule for *when last edited+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=603, read_rule_class='*right' where trash is false and tag_id=438")
-> 0.0377s
- create rule for *refers to+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=604, read_rule_class='*right' where trash is false and tag_id=445")
-> 0.0378s
- create rule for *referred to by+*right, READ: Anyone Signed In
-- execute("update cards set read_rule_id=605, read_rule_class='*right' where trash is false and tag_id=448")
-> 0.0345s
creating *self set perms
- create rule for Home+*self, READ: Anyone Signed In
-- execute("update cards set read_rule_id=607, read_rule_class='*self' where trash is false and id=80")
-> 0.1345s
- create rule for Menu+*self, READ: Anyone Signed In
-- execute("update cards set read_rule_id=609, read_rule_class='*self' where trash is false and id=85")
-> 0.1720s
- create rule for Administrator links+*self, READ: Administrator
-- execute("update cards set read_rule_id=611, read_rule_class='*self' where trash is false and id=151")
-> 0.1652s
- create rule for Default Layout+*self, EDIT: Anyone Signed In
- create rule for Default Layout+*self, DELETE: Anyone Signed In
== PermissionsIntoSettings: migrated (174.9466s) =============================
== GenerateReadRules: migrating ==============================================
updating read_rule fields
updating read rule for Wagn Bot; rule tag_name = *all, read_rule_class =
updating read rule for Anyone; rule tag_name = *all, read_rule_class =
updating read rule for Anyone Signed In; rule tag_name = *all, read_rule_class =
updating read rule for Administrator; rule tag_name = *all, read_rule_class =
updating read rule for *all+*default; rule tag_name = *all plus, read_rule_class =
updating read rule for Home; rule tag_name = *self, read_rule_class = *all
updating read rule for Menu; rule tag_name = *self, read_rule_class = *all
updating read rule for Administrator links; rule tag_name = *self, read_rule_class = *all
updating read rule for Cardtype+description; rule tag_name = *all plus, read_rule_class =
updating read rule for *type plus right; rule tag_name = *all, read_rule_class =
updating read rule for *type plus right+*right+*content; rule tag_name = *all plus, read_rule_class =
updating read rule for *input+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *watchers+*right; rule tag_name = *right, read_rule_class =
updating read rule for *all; rule tag_name = *all, read_rule_class =
updating read rule for *table of contents+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *option label+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *thanks+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *autoname+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *options+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *captcha+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for HTML+*type; rule tag_name = *right, read_rule_class =
updating read rule for Role+*type; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *right+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *type plus right+*right; rule tag_name = *right, read_rule_class =
updating read rule for *type+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *watching+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *account+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for Image+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *incoming+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for by create+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for by name+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *plusses+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *tagged+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *outgoing+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *community+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for by update+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *members+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *related+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *linkers+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *links+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *inclusions+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *includers+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *plus parts+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *plus cards+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *editing+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *editors+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *roles+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for discussion+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for tags+*right; rule tag_name = *right, read_rule_class = *all plus
updating read rule for *all plus; rule tag_name = *all, read_rule_class =
updating read rule for *star; rule tag_name = *all, read_rule_class =
updating read rule for *rstar; rule tag_name = *all, read_rule_class =
updating read rule for *create; rule tag_name = *all, read_rule_class =
updating read rule for *read; rule tag_name = *all, read_rule_class =
updating read rule for *update; rule tag_name = *all, read_rule_class =
updating read rule for *delete; rule tag_name = *all, read_rule_class =
updating read rule for Cardtype+description+*type plus right; rule tag_name = *right, read_rule_class =
updating read rule for *all+*update; rule tag_name = *all plus, read_rule_class =
updating read rule for *all plus+*update; rule tag_name = *all plus, read_rule_class =
updating read rule for *all+*delete; rule tag_name = *all plus, read_rule_class =
updating read rule for *all plus+*delete; rule tag_name = *all plus, read_rule_class =
updating read rule for *all+*comment; rule tag_name = *all plus, read_rule_class =
updating read rule for Role+*type+*create; rule tag_name = *all plus, read_rule_class =
updating read rule for Account Request+*type; rule tag_name = *right, read_rule_class =
updating read rule for Account Request+*type+*create; rule tag_name = *all plus, read_rule_class =
updating read rule for *plus cards+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *plus parts+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *includers+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *linkers+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *inclusions+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *links+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *editors+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *editing+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *roles+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *members+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *plusses+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *community+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *account+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for discussion+*right+*comment; rule tag_name = *all plus, read_rule_class =
updating read rule for *outgoing+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *incoming+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *tagged+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for by update+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for by name+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for by create+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *watching+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *right+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *type plus right+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *self+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *type+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for email config+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for watcher instructions for related tab+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *count+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *last edited+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *creator+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *created+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *when created+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *when last edited+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *refers to+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for *referred to by+*right+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for Home+*self; rule tag_name = *right, read_rule_class =
updating read rule for Home+*self+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for Menu+*self; rule tag_name = *right, read_rule_class =
updating read rule for Menu+*self+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for Administrator links+*self; rule tag_name = *right, read_rule_class =
updating read rule for Administrator links+*self+*read; rule tag_name = *all plus, read_rule_class =
updating read rule for Default Layout+*self; rule tag_name = *right, read_rule_class =
updating read rule for Default Layout+*self+*update; rule tag_name = *all plus, read_rule_class =
updating read rule for Default Layout+*self+*delete; rule tag_name = *all plus, read_rule_class =
successfully updated read rules for 109 cards
== GenerateReadRules: migrated (19.9138s) ====================================
== PermissionSettingsDetails: migrating ======================================
== PermissionSettingsDetails: migrated (8.0961s) =============================
== RepairBrokenPlusPermissions: migrating ====================================
== RepairBrokenPlusPermissions: migrated (68.8975s) ==========================
== AddReadRuleIdIndex: migrating =============================================
-- add_index(:cards, :read_rule_id)
-> 0.6528s
== AddReadRuleIdIndex: migrated (0.6529s) ====================================
== AddImportantSetContent: migrating =========================================
== AddImportantSetContent: migrated (3.3829s) ================================
-----------------------------------------------------------------------------------------------------------------------
[heze]$ rake cache:clear
rake/rdoctask is deprecated. Use rdoc/task instead (in RDoc 2.4.2+)
Running without hoptoad
----------- Wagn Loaded -----------
III) In the end I'm getting same error:
Processing CardController#index (for 90.181.53.236 at 2011-11-25 13:28:47) [GET]
ActiveRecord::SubclassNotFound (The single-table inheritance mechanism failed to locate the subclass: 'Basic'. This error is raised because the column 'type' is reserved for storing the class in case of inheritance. Please rename this column if you didn't intend it to be used for storing the inheritance class or overwrite Card.inheritance_column to use another column for that information.):
lib/wagn/model/acts_as_card_extension.rb:7:in `card'
app/models/user.rb:90:in `[]'
app/controllers/application_controller.rb:45:in `per_request_setup'
/dh/passenger/lib/phusion_passenger/rack/request_handler.rb:92:in `process_request'
/dh/passenger/lib/phusion_passenger/abstract_request_handler.rb:207:in `main_loop'
/dh/passenger/lib/phusion_passenger/railz/application_spawner.rb:400:in `start_request_handler'
/dh/passenger/lib/phusion_passenger/railz/application_spawner.rb:351:in `handle_spawn_application'
/dh/passenger/lib/phusion_passenger/utils.rb:184:in `safe_fork'
/dh/passenger/lib/phusion_passenger/railz/application_spawner.rb:349:in `handle_spawn_application'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:352:in `__send__'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:352:in `main_loop'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:196:in `start_synchronously'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:163:in `start'
/dh/passenger/lib/phusion_passenger/railz/application_spawner.rb:209:in `start'
/dh/passenger/lib/phusion_passenger/spawn_manager.rb:262:in `spawn_rails_application'
/dh/passenger/lib/phusion_passenger/abstract_server_collection.rb:126:in `lookup_or_add'
/dh/passenger/lib/phusion_passenger/spawn_manager.rb:256:in `spawn_rails_application'
/dh/passenger/lib/phusion_passenger/abstract_server_collection.rb:80:in `synchronize'
/dh/passenger/lib/phusion_passenger/abstract_server_collection.rb:79:in `synchronize'
/dh/passenger/lib/phusion_passenger/spawn_manager.rb:255:in `spawn_rails_application'
/dh/passenger/lib/phusion_passenger/spawn_manager.rb:154:in `spawn_application'
/dh/passenger/lib/phusion_passenger/spawn_manager.rb:287:in `handle_spawn_application'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:352:in `__send__'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:352:in `main_loop'
/dh/passenger/lib/phusion_passenger/abstract_server.rb:196:in `start_synchronously'
Rendering /home/vedma/know/public/500.html (500 Internal Server Error)
=> To me the upgrade looks fine. Where could it go wrong? If any more info would be helpful then just tell me.
--Tukanos.....Fri Nov 25 13:41:36 -0800 2011
Well, this is very helpful.
Have you restarted the server?
If so, I think the thing to focus on is the "type" column, which is supposed to get renamed to "typecode" in the second migration run. Judging by the log it seems like it was successful:
== TypeToCardtype: migrating =================================================
-- rename_column(:cards, :type, :typecode)
-> 0.4105s
== TypeToCardtype: migrated (0.4106s) ========================================
But the error you're seeing suggests that there is still a field named "type". (the name "type" has special meaning to rails, which is part of the motivation for renaming it). That is very strange.
Do you have multiple databases referred to in your database.yml? Is it possible that the migrations are taking effect on one database while the server is looking at another? For example, if you have a development database and a production database, you may need to do env RAILS_ENV=production rake db:migrate to migrate the production database.
That could explain this behavior. If not, the more you can tell me about your database setup the better, though I understand some of this info may be sensitive. If you prefer, you can send some details to support@wagn.org.
The good news is that the migrations include some very complicated permissions updates, which appear to have gone smoothly. If we can just figure out why the server seems to be actings as if the migrations haven't happened, we'll be in good shape.
- ethan
--Ethan McCutchen.....Sun Nov 27 19:26:36 -0800 2011
Hello Ethan,
Sorry for late reply. I had health issues so had to recover.
So finally I got the upgrade working. In the end I have created exact copies of hosting on my computer. I have created test, dev, and prod. Then I decided to monitor what exactly happens during the upgrade process.
To cut long story short, only the dev platform got upgraded. So then I used your export to env properties which upgraded the production DB. The only thing I noticed there are some issues with indexes left there.
For example, in the table cards I get this message:
"The indexes cards_name_uniq and cards_name_index seem to be equal and one of them could possibly be removed."
"The indexes cards_extension_type_id_index and cards_extension_index seem to be equal and one of them could possibly be removed."
I can, of course, drop these indexes manually but maybe it is good idea to have them removed during the update process. I really appreciate your time you dedicate this project and wanted to ask if there are ways to support you.
Thank you,
Tukanos
--Tukanos.....Tue Dec 27 07:33:57 -0800 2011
Oh good. Glad we got that problem solved. Nice work.
You know, I noticed that issue with the indeces recently. I'll get those migrated out in Wagn 1.8 (coming soon).
Thanks for offering to support the project! With each release between now and 2.0 there will be more and more ways to get involved. Are you on the mailing lists? Those will be getting active very soon.
--Ethan McCutchen.....Tue Dec 27 16:17:11 -0800 2011
Hi Ethan,
Thank you for the mailing lists link. I have added myself to both of them. I will think about a way how to support you ;).
All the best,
Patrik
--Tukanos.....Thu Dec 29 09:27:16 -0800 2011