Unable to Install Spree

38 views
Skip to first unread message

kapilvas...@gmail.com

unread,
Oct 23, 2018, 6:17:16 AM10/23/18
to Spree
Hi,
I am a php developer & now moving to spree cms. But while installing spree i stuck with these two commands:-
rails g spree:auth:install and rails g spree_gateway:install  .. Please help

/var/lib/gems/2.5.0/gems/railties-5.2.1/lib/rails/app_loader.rb:53: warning: Insecure world writable dir /usr in PATH, mode 040777
 append vendor
/assets/javascripts/spree/frontend/all.js
 conflict config
/initializers/devise.rb
Overwrite /var/www/html/ror/spree-cms/spree-project/config/initializers/devise.rb? (enter "h" for help) [Ynaqdh] Y
 force config
/initializers/devise.rb
 run bundle
exec rake railties:install:migrations FROM=spree_auth from "."
 run bundle
exec rake db:migrate VERBOSE=false from "."
rake aborted
!
StandardError: An error has occurred, this and all later migrations canceled:

Could not find table 'spree_payment_methods'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/sqlite3_adapter.rb:397:in `table_structure'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `
columns'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `
load_schema!'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `
block in load_schema'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `
type_for_attribute'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `
block in expand_from_hash'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `
expand_from_hash'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `
where!'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/var/lib/gems/2.5.0/gems/paranoia-2.4.1/lib/paranoia.rb:246:in `
paranoia_scope'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `public_send'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `block in method_missing'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:281:in `
scoping'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `method_missing'

/var/lib/gems/2.5.0/gems/paranoia-2.4.1/lib/paranoia.rb:251:in `block in acts_as_paranoid'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:122:in `
instance_exec'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:122:in `block (2 levels) in build_default_scope'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:120:in `each'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:120:in `
inject'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:120:in `block in build_default_scope'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:144:in `evaluate_default_scope'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:119:in `
build_default_scope'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/named.rb:51:in `default_scoped'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/named.rb:36:in `all'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `
where'
/var/www/html/ror/spree-cms/spree-project/db/migrate/20181023051928_update_braintree_payment_method_type.spree_gateway.rb:4:in `up'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:817:in `exec_migration'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:798:in `
block (2 levels) in migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:797:in `block in migrate'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:414:in `with_connection'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:796:in `
migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:977:in `migrate'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1292:in `block in execute_migration_in_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1343:in `
block in ddl_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:254:in `block in transaction'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/transaction.rb:239:in `block in within_new_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/transaction.rb:236:in `
within_new_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:254:in `transaction'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/transactions.rb:212:in `transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1343:in `
ddl_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1291:in `execute_migration_in_transaction'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1263:in `block in migrate_without_lock'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `
each'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `migrate_without_lock'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1212:in `migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1036:in `
up'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1011:in `migrate'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/tasks/database_tasks.rb:172:in `migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/railties/databases.rake:60:in `
block (2 levels) in <main>'
/var/lib/gems/2.5.0/gems/rake-12.3.1/exe/rake:27:in `<top (required)>'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli/exec.rb:74:in `load'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli/exec.rb:74:in `
kernel_load'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli/exec.rb:28:in `run'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli.rb:424:in `exec'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `
run'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli.rb:27:in `
dispatch'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli.rb:18:in `start'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/exe/bundle:30:in `
block in <top (required)>'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/friendly_errors.rb:124:in `with_friendly_errors'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/exe/bundle:22:in `<top (required)>'
/usr/local/bin/bundle:23:in `
load'
/usr/local/bin/bundle:23:in `<main>'


Caused by:
ActiveRecord::StatementInvalid: Could not find table 'spree_payment_methods'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/sqlite3_adapter.rb:397:in `table_structure'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/schema_statements.rb:113:in `
columns'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:69:in `columns'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/schema_cache.rb:75:in `columns_hash'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:466:in `
load_schema!'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/attributes.rb:234:in `load_schema!'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/attribute_decorators.rb:51:in `load_schema!'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:459:in `
block in load_schema'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:456:in `load_schema'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:346:in `attribute_types'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/model_schema.rb:370:in `
type_for_attribute'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/table_metadata.rb:33:in `type'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:51:in `build'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:107:in `
block in expand_from_hash'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `each'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `flat_map'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:71:in `
expand_from_hash'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/predicate_builder.rb:21:in `build_from_hash'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/where_clause_factory.rb:19:in `build'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:591:in `
where!'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/query_methods.rb:584:in `where'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `where'
/var/lib/gems/2.5.0/gems/paranoia-2.4.1/lib/paranoia.rb:246:in `
paranoia_scope'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `public_send'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `block in method_missing'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation.rb:281:in `
scoping'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/relation/delegation.rb:84:in `method_missing'

/var/lib/gems/2.5.0/gems/paranoia-2.4.1/lib/paranoia.rb:251:in `block in acts_as_paranoid'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:122:in `
instance_exec'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:122:in `block (2 levels) in build_default_scope'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:120:in `each'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:120:in `
inject'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:120:in `block in build_default_scope'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:144:in `evaluate_default_scope'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/default.rb:119:in `
build_default_scope'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/named.rb:51:in `default_scoped'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/scoping/named.rb:36:in `all'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/querying.rb:12:in `
where'
/var/www/html/ror/spree-cms/spree-project/db/migrate/20181023051928_update_braintree_payment_method_type.spree_gateway.rb:4:in `up'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:817:in `exec_migration'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:798:in `
block (2 levels) in migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:797:in `block in migrate'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/connection_pool.rb:414:in `with_connection'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:796:in `
migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:977:in `migrate'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1292:in `block in execute_migration_in_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1343:in `
block in ddl_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:254:in `block in transaction'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/transaction.rb:239:in `block in within_new_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/transaction.rb:236:in `
within_new_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/connection_adapters/abstract/database_statements.rb:254:in `transaction'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/transactions.rb:212:in `transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1343:in `
ddl_transaction'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1291:in `execute_migration_in_transaction'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1263:in `block in migrate_without_lock'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `
each'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1262:in `migrate_without_lock'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1212:in `migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1036:in `
up'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/migration.rb:1011:in `migrate'

/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/tasks/database_tasks.rb:172:in `migrate'
/var/lib/gems/2.5.0/gems/activerecord-5.2.1/lib/active_record/railties/databases.rake:60:in `
block (2 levels) in <main>'
/var/lib/gems/2.5.0/gems/rake-12.3.1/exe/rake:27:in `<top (required)>'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli/exec.rb:74:in `load'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli/exec.rb:74:in `
kernel_load'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli/exec.rb:28:in `run'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli.rb:424:in `exec'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor/command.rb:27:in `
run'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor/invocation.rb:126:in `invoke_command'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor.rb:387:in `dispatch'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli.rb:27:in `
dispatch'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/vendor/thor/lib/thor/base.rb:466:in `start'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/cli.rb:18:in `start'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/exe/bundle:30:in `
block in <top (required)>'
/var/lib/gems/2.5.0/gems/bundler-1.16.6/lib/bundler/friendly_errors.rb:124:in `with_friendly_errors'

/var/lib/gems/2.5.0/gems/bundler-1.16.6/exe/bundle:22:in `<top (required)>'
/usr/local/bin/bundle:23:in `
load'
/usr/local/bin/bundle:23:in `<main>'

Tasks: TOP => db:migrate
(See full trace by running task with --trace)

Enter code here...



Surya

unread,
Oct 23, 2018, 7:22:36 AM10/23/18
to spree...@googlegroups.com
It looks like it is unable to find table spree_payment_methods.  Did you run `rake db:migrate` and cancel at some point?

If this is a fresh install then try following the steps mentioned in GitHub - https://github.com/spree/spree#rails-52
--

 Please consider the environment before printing this email.

Regards,
Surya


 This is my Footrr

Deepak Mahakale

unread,
Oct 24, 2018, 12:23:30 AM10/24/18
to Spree
Seems like you haven't run rails g spree:install 
Reply all
Reply to author
Forward
0 new messages