Skip to content

Instantly share code, notes, and snippets.

@effkay
Last active December 19, 2015 19:49
Show Gist options
  • Save effkay/6008724 to your computer and use it in GitHub Desktop.
Save effkay/6008724 to your computer and use it in GitHub Desktop.
Rails says missing PG gem, but pg gem is in Gemfile
10] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> migration_status = Dir.chdir(application_path) { `grep pg Gemfile` }
=> "gem 'pg'\n"
[11] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> migration_status = Dir.chdir(application_path) { `bundle` }
=> "Using rake (10.0.4) \nUsing i18n (0.6.4) \nUsing minitest (4.7.5) \nUsing multi_json (1.7.7) \nUsing atomic (1.1.10) \nUsing thread_safe (0.1.0) \nUsing tzinfo (0.3.37) \nUsing activesupport (4.0.0) \nUsing builder (3.1.4) \nUsing erubis (2.7.0) \nUsing rack (1.5.2) \nUsing rack-test (0.6.2) \nUsing actionpack (4.0.0) \nUsing mime-types (1.23) \nUsing polyglot (0.3.3) \nUsing treetop (1.4.14) \nUsing mail (2.5.4) \nUsing actionmailer (4.0.0) \nUsing activemodel (4.0.0) \nUsing activerecord-deprecated_finders (1.0.3) \nUsing arel (4.0.0) \nUsing activerecord (4.0.0) \nUsing json (1.8.0) \nUsing airbrake (3.1.12) \nUsing diff-lcs (1.2.4) \nUsing posix-spawn (0.3.6) \nUsing grit (2.5.0) \nUsing little-plugger (1.1.3) \nUsing logging (1.8.1) \nUsing thor (0.18.1) \nUsing blazing (0.4.0.beta3) \nUsing bundler (1.3.5) \nUsing coderay (1.0.9) \nUsing ffi (1.8.1) \nUsing formatador (0.2.4) \nUsing rb-fsevent (0.9.3) \nUsing rb-inotify (0.9.0) \nUsing rb-kqueue (0.2.0) \nUsing listen (1.1.6) \nUsing lumberjack (1.0.3) \nUsing method_source (0.8.1) \nUsing slop (3.4.5) \nUsing pry (0.9.12.2) \nUsing guard (1.8.0) \nUsing rspec-core (2.14.0.rc1) \nUsing rspec-expectations (2.14.0.rc1) \nUsing rspec-mocks (2.14.0.rc1) \nUsing rspec (2.14.0.rc1) \nUsing guard-rspec (3.0.0) \nUsing hike (1.2.3) \nUsing railties (4.0.0) \nUsing tilt (1.4.1) \nUsing sprockets (2.10.0) \nUsing sprockets-rails (2.0.0) \nUsing rails (4.0.0) \nUsing ruby_gntp (0.3.4) \nUsing shoestrap (1.0.0.pre1) \nYour bundle is complete!\nUse `bundle show [gemname]` to see where a bundled gem is installed.\n"
[12] pry(#<RSpec::Core::ExampleGroup::Nested_1>)> migration_status = Dir.chdir(application_path) { `bundle exec rake db:migrate:status` }
rake aborted!
Specified 'postgresql' for database adapter, but the gem is not loaded. Add `gem 'pg'` to your Gemfile.
/Users/felipe/src/screenconcept/shoestrap/features/test_app/config/environment.rb:5:in `<top (required)>'
Tasks: TOP => db:migrate:status => environment
(See full trace by running task with --trace)
=> ""
@senny
Copy link

senny commented Jul 16, 2013

can you post the complete Gemfile and .bundle/config?

@effkay
Copy link
Author

effkay commented Jul 16, 2013

fixed: aparently something was setting ENV[BUNDLE_GEMFILE]!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment