RefineryCMS: app not running on Heroku - ruby-on-rails

I did not add the --heroku option according to the guides/heroku. So I skipped to
2 Deploying an existing local Refinery application
And this is now my Gemfile
source 'https://rubygems.org'
gem 'rails', '3.2.14'
# Bundle edge Rails instead:
# gem 'rails', :git => 'git://github.com/rails/rails.git'
group :development, :test do
gem 'sqlite3'
end
group :production do
gem 'pg'
end
# Gems used only for assets and not required
# in production environments by default.
group :assets do
gem 'sass-rails', '~> 3.2.3'
gem 'coffee-rails', '~> 3.2.1'
# See https://github.com/sstephenson/execjs#readme for more supported runtimes
# gem 'therubyracer', :platforms => :ruby
gem 'uglifier', '>= 1.0.3'
end
gem 'jquery-rails'
gem 'taps'
# To use ActiveModel has_secure_password
# gem 'bcrypt-ruby', '~> 3.0.0'
# To use Jbuilder templates for JSON
# gem 'jbuilder'
# Use unicorn as the app server
# gem 'unicorn'
# Deploy with Capistrano
# gem 'capistrano'
# To use debugger
# gem 'debugger'
# Refinery CMS
gem 'refinerycms', '~> 2.1.0'
# Optionally, specify additional Refinery CMS Extensions here:
gem 'refinerycms-acts-as-indexed', '~> 1.0.0'
# gem 'refinerycms-blog', '~> 2.1.0'
# gem 'refinerycms-inquiries', '~> 2.1.0'
# gem 'refinerycms-search', '~> 2.1.0'
# gem 'refinerycms-page-images', '~> 2.1.0'
gem 'refinerycms-events', :path => 'vendor/extensions'
I already had an app created on Heroku. So I just ran the obvious heroku git:remote -a rickrolling and yes I did test it.
jgallardo:rickrockstar juan.gallardo$ git remote -v
heroku git#heroku.com:rickrolling.git (fetch)
heroku git#heroku.com:rickrolling.git (push)
I then did as instructed in
2.3 Step 3: Set up asset precompilation
Here is my application.rb
require File.expand_path('../boot', __FILE__)
require 'rails/all'
if defined?(Bundler)
# If you precompile assets before deploying to production, use this line
Bundler.require(*Rails.groups(:assets => %w(development test)))
# If you want your assets lazily compiled in production, use this line
# Bundler.require(:default, :assets, Rails.env)
end
module Rickrockstar
class Application < Rails::Application
# Settings in config/environments/* take precedence over those specified here.
# Application configuration should go into files in config/initializers
# -- all .rb files in that directory are automatically loaded.
# Custom directories with classes and modules you want to be autoloadable.
# config.autoload_paths += %W(#{config.root}/extras)
# Only load the plugins named here, in the order given (default is alphabetical).
# :all can be used as a placeholder for all plugins not explicitly named.
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
# Activate observers that should always be running.
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
# Run "rake -D time" for a list of tasks for finding time zone names. Default is UTC.
config.time_zone = 'Pacific Time (US & Canada)'
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
# config.i18n.default_locale = :de
# Configure the default encoding used in templates for Ruby 1.9.
config.encoding = "utf-8"
# Configure sensitive parameters which will be filtered from the log file.
config.filter_parameters += [:password]
# Enable escaping HTML in JSON.
config.active_support.escape_html_entities_in_json = true
# Use SQL instead of Active Record's schema dumper when creating the database.
# This is necessary if your schema can't be completely dumped by the schema dumper,
# like if you have constraints or database-specific column types
# config.active_record.schema_format = :sql
# Enforce whitelist mode for mass assignment.
# This will create an empty whitelist of attributes available for mass-assignment for all models
# in your app. As such, your models will need to explicitly whitelist or blacklist accessible
# parameters by using an attr_accessible or attr_protected declaration.
config.active_record.whitelist_attributes = true
# Enable the asset pipeline
config.assets.enabled = true
# Version of your assets, change this if you want to expire all your assets
config.assets.version = '1.0'
config.assets.initialize_on_precompile = true
end
end
Then I ran heroku labs:enable user-env-compile and yes I verified what stack it was on
jgallardo:rickrockstar juan.gallardo$ heroku stack
=== rickrolling Available Stacks
bamboo-mri-1.9.2
bamboo-ree-1.8.7
* cedar
Because I already had data that I wanted to push I followed
2.5 Step 4 (Option 2): Copy your data from your local database to the Heroku app
which said to and did gem insall taps and heroku db:push but I got this error
jgallardo:rickrockstar juan.gallardo$ heroku db:push
/Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/sqlite3-1.3.8/lib/sqlite3 /sqlite3_native.bundle: [BUG] Segmentation fault
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin10.8.0]
-- Control frame information -----------------------------------------------
c:0020 p:-545436774 s:0082 b:0082 l:000081 d:000081 TOP
c:0019 p:---- s:0080 b:0080 l:000079 d:000079 CFUNC :require
c:0018 p:0036 s:0076 b:0076 l:000075 d:000075 METHOD /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:36
c:0017 p:0029 s:0069 b:0069 l:000065 d:000068 BLOCK /Users/juan.gallardo/.rvm/gems/ruby-2.0.0- p195/gems/sqlite3-1.3.8/lib/sqlite3.rb:6
c:0016 p:0035 s:0066 b:0066 l:000065 d:000065 TOP /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/sqlite3-1.3.8/lib/sqlite3.rb:2
c:0015 p:---- s:0064 b:0064 l:000063 d:000063 FINISH
c:0014 p:---- s:0062 b:0062 l:000061 d:000061 CFUNC :require
c:0013 p:0089 s:0058 b:0058 l:000054 d:000057 BLOCK /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:60
c:0012 p:0158 s:0055 b:0055 l:000054 d:000054 METHOD /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:35
c:0011 p:0109 s:0048 b:0047 l:000046 d:000046 TOP /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/cli.rb:10
c:0010 p:---- s:0045 b:0045 l:000044 d:000044 FINISH
c:0009 p:---- s:0043 b:0043 l:000042 d:000042 CFUNC :require
c:0008 p:0036 s:0039 b:0039 l:000038 d:000038 METHOD /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:36
c:0007 p:0040 s:0032 b:0032 l:000031 d:000031 METHOD /Users/juan.gallardo/.heroku/client/lib/heroku/command/db.rb:208
c:0006 p:0011 s:0028 b:0028 l:000027 d:000027 METHOD /Users/juan.gallardo/.heroku/client/lib/heroku/command/db.rb:24
c:0005 p:0046 s:0024 b:0024 l:000023 d:000023 METHOD /Users/juan.gallardo/.heroku/client/lib/heroku/command.rb:206
c:0004 p:0112 s:0014 b:0014 l:000013 d:000013 METHOD /Users/juan.gallardo/.heroku/client/lib/heroku/cli.rb:28
c:0003 p:0232 s:0008 b:0008 l:0002a8 d:0003d8 EVAL /usr/local/heroku/bin/heroku:24
c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH
c:0001 p:0000 s:0002 b:0002 l:0002a8 d:0002a8 TOP
-- Ruby level backtrace information ----------------------------------------
/usr/local/heroku/bin/heroku:24:in `<main>'
/Users/juan.gallardo/.heroku/client/lib/heroku/cli.rb:28:in `start'
/Users/juan.gallardo/.heroku/client/lib/heroku/command.rb:206:in `run'
/Users/juan.gallardo/.heroku/client/lib/heroku/command/db.rb:24:in `push'
/Users/juan.gallardo/.heroku/client/lib/heroku/command/db.rb:208:in `load_taps'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/cli.rb:10:in `<top (required)>'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:35:in `require'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:60:in `rescue in require'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:60:in `require'
/Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/sqlite3-1.3.8/lib/sqlite3.rb:2:in `<top (required)>'
/Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/sqlite3-1.3.8/lib/sqlite3.rb:6:in `rescue in <top (required)>'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
/usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
-- C level backtrace information -------------------------------------------
See Crash Report log file under ~/Library/Logs/CrashReporter or
/Library/Logs/CrashReporter, for the more detail of.
-- Other runtime information -----------------------------------------------
* Loaded script: /usr/local/heroku/bin/heroku
* Loaded features:
0 enumerator.so
1 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/enc/encdb.bundle
2 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/enc/trans/transdb.bundle
3 /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/defaults.rb
4 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/rbconfig.rb
5 /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/deprecate.rb
6 /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/exceptions.rb
7 /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems/custom_require.rb
8 /usr/local/heroku/ruby/lib/ruby/1.9.1/rubygems.rb
9 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/pathname.bundle
10 /usr/local/heroku/ruby/lib/ruby/1.9.1/pathname.rb
11 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/digest.bundle
12 /usr/local/heroku/ruby/lib/ruby/1.9.1/digest.rb
13 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/etc.bundle
14 /usr/local/heroku/ruby/lib/ruby/1.9.1/fileutils.rb
15 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/stringio.bundle
16 /usr/local/heroku/lib/vendor/heroku/okjson.rb
17 /usr/local/heroku/lib/heroku/helpers.rb
18 /usr/local/heroku/lib/heroku/updater.rb
19 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/parseexception.rb
20 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/formatters/default.rb
21 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/formatters/pretty.rb
22 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/node.rb
23 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/child.rb
24 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/parent.rb
25 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/xmltokens.rb
26 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/namespace.rb
27 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/encoding.rb
28 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/source.rb
29 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/entity.rb
30 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/attlistdecl.rb
31 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/doctype.rb
32 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/text.rb
33 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/attribute.rb
34 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/cdata.rb
35 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/functions.rb
36 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/syncenumerator.rb
37 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/parsers/xpathparser.rb
38 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/xpath_parser.rb
39 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/xpath.rb
40 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/element.rb
41 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/xmldecl.rb
42 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/comment.rb
43 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/instruction.rb
44 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/rexml.rb
45 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/output.rb
46 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/undefinednamespaceexception.rb
47 /usr/local/heroku/ruby/lib/ruby/1.9.1/set.rb
48 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/parsers/baseparser.rb
49 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/parsers/streamparser.rb
50 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/validation/validationexception.rb
51 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/parsers/treeparser.rb
52 /usr/local/heroku/ruby/lib/ruby/1.9.1/rexml/document.rb
53 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/common.rb
54 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/generic.rb
55 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/ftp.rb
56 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/http.rb
57 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/https.rb
58 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/ldap.rb
59 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/ldaps.rb
60 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri/mailto.rb
61 /usr/local/heroku/ruby/lib/ruby/1.9.1/uri.rb
62 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/date_core.bundle
63 /usr/local/heroku/ruby/lib/ruby/1.9.1/date/format.rb
64 /usr/local/heroku/ruby/lib/ruby/1.9.1/date.rb
65 /usr/local/heroku/ruby/lib/ruby/1.9.1/time.rb
66 /usr/local/heroku/ruby/lib/ruby/1.9.1/cgi/core.rb
67 /usr/local/heroku/ruby/lib/ruby/1.9.1/cgi/cookie.rb
68 /usr/local/heroku/ruby/lib/ruby/1.9.1/cgi/util.rb
69 /usr/local/heroku/ruby/lib/ruby/1.9.1/cgi.rb
70 /Users/juan.gallardo/.heroku/client/vendor/gems/netrc-0.7.7/lib/netrc.rb
71 /Users/juan.gallardo/.heroku/client/lib/heroku/auth.rb
72 /Users/juan.gallardo/.heroku/client/lib/heroku/plugin.rb
73 /Users/juan.gallardo/.heroku/client/lib/heroku/version.rb
74 /usr/local/heroku/ruby/lib/ruby/1.9.1/optparse.rb
75 /Users/juan.gallardo/.heroku/client/lib/heroku/command.rb
76 /Users/juan.gallardo/.heroku/client/lib/heroku/client/ssl_endpoint.rb
77 /Users/juan.gallardo/.heroku/client/lib/heroku/client.rb
78 /Users/juan.gallardo/.heroku/client/lib/heroku.rb
79 /Users/juan.gallardo/.heroku/client/lib/heroku/cli.rb
80 /usr/local/heroku/ruby/lib/ruby/1.9.1/timeout.rb
81 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/socket.bundle
82 /usr/local/heroku/ruby/lib/ruby/1.9.1/socket.rb
83 /Users/juan.gallardo/.heroku/client/lib/heroku/client/rendezvous.rb
84 /Users/juan.gallardo/.heroku/client/lib/heroku/command/base.rb
85 /Users/juan.gallardo/.heroku/client/lib/heroku/command/account.rb
86 /Users/juan.gallardo/.heroku/client/lib/heroku/command/accounts.rb
87 /Users/juan.gallardo/.heroku/client/lib/heroku/helpers/heroku_postgresql.rb
88 /Users/juan.gallardo/.heroku/client/lib/heroku/command/addons.rb
89 /Users/juan.gallardo/.heroku/client/lib/heroku/command/apps.rb
90 /Users/juan.gallardo/.heroku/client/lib/heroku/command/auth.rb
114 /Users/juan.gallardo/.heroku/client/vendor/gems/excon-0.23.0/lib/excon.rb
115 /Users/juan.gallardo/.heroku/client/lib/heroku/command/certs.rb
116 /Users/juan.gallardo/.heroku/client/lib/heroku/command/config.rb
117 /Users/juan.gallardo/.heroku/client/lib/heroku/command/db.rb
118 /Users/juan.gallardo/.heroku/client/lib/heroku/command/domains.rb
119 /Users/juan.gallardo/.heroku/client/lib/heroku/command/drains.rb
120 /Users/juan.gallardo/.heroku/client/lib/heroku/client/cisaurus.rb
121 /Users/juan.gallardo/.heroku/client/lib/heroku/command/fork.rb
122 /Users/juan.gallardo/.heroku/client/lib/heroku/command/git.rb
123 /Users/juan.gallardo/.heroku/client/lib/heroku/deprecated.rb
124 /Users/juan.gallardo/.heroku/client/lib/heroku/deprecated/help.rb
125 /Users/juan.gallardo/.heroku/client/lib/heroku/command/help.rb
126 /Users/juan.gallardo/.heroku/client/lib/heroku/command/keys.rb
127 /Users/juan.gallardo/.heroku/client/lib/heroku/command/labs.rb
128 /Users/juan.gallardo/.heroku/client/lib/heroku/helpers/log_displayer.rb
129 /Users/juan.gallardo/.heroku/client/lib/heroku/command/logs.rb
130 /Users/juan.gallardo/.heroku/client/lib/heroku/command/maintenance.rb
131 /Users/juan.gallardo/.heroku/client/lib/heroku/client/heroku_postgresql.rb
132 /Users/juan.gallardo/.heroku/client/lib/heroku/command/pg.rb
133 /Users/juan.gallardo/.heroku/client/lib/heroku/client/pgbackups.rb
134 /Users/juan.gallardo/.heroku/client/lib/heroku/command/pgbackups.rb
135 /Users/juan.gallardo/.heroku/client/lib/heroku/command/plugins.rb
136 /Users/juan.gallardo/.heroku/client/lib/heroku/command/ps.rb
137 /Users/juan.gallardo/.heroku/client/lib/heroku/command/regions.rb
138 /Users/juan.gallardo/.heroku/client/lib/heroku/command/releases.rb
139 /usr/local/heroku/ruby/lib/ruby/1.9.1/x86_64-darwin10.8.0/readline.bundle
140 /Users/juan.gallardo/.heroku/client/lib/heroku/command/run.rb
141 /Users/juan.gallardo/.heroku/client/lib/heroku/command/sharing.rb
142 /Users/juan.gallardo/.heroku/client/lib/heroku/command/ssl.rb
143 /Users/juan.gallardo/.heroku/client/lib/heroku/command/stack.rb
144 /Users/juan.gallardo/.heroku/client/lib/heroku/command/status.rb
145 /Users/juan.gallardo/.heroku/client/lib/heroku/command/update.rb
146 /Users/juan.gallardo/.heroku/client/lib/heroku/command/version.rb
245 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/version.rb
246 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/config.rb
247 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/errors.rb
248 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/chunksize.rb
249 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/utils.rb
250 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/monkey.rb
251 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/rack-1.5.2/lib/rack/multipart.rb
252 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/rack-1.5.2/lib/rack/utils.rb
253 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/vendor/okjson.rb
254 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/multipart.rb
255 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/log.rb
256 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/data_stream.rb
257 /Users/juan.gallardo/.rvm/gems/ruby-2.0.0-p195/gems/taps-0.3.24/lib/taps/operation.rb
[NOTE]
You may have encountered a bug in the Ruby interpreter or extension libraries.
Bug reports are welcome.
For details: http://www.ruby-lang.org/bugreport.html
Abort trap: 6
Some lines are missing because I exceeded the character count. But the full file is at https://gist.github.com/JGallardo/6370370
And yes, I did try heroku restart per https://groups.google.com/forum/#!topic/refinery-cms/VjjTQijkM6k
So tyring to figure out the next step from here. Not too savvy yet with interpretting the error reports.

Ordinarily I would have thought having sqlite3 in there under the development group would be fine but the error is coming from Heroku trying to install sqlite3 and the sqlite3 gem is not compatible with Heroku. So, I'd try removing that from your Gemfile completely and seeing whether that helps.

Unfortunatly your gist links is not working but I am assuming you have an issue with dates columns.
Sqlite and postgresql don't handle dates the same way. So copying your data from your local sqlite database would be an issue.
You can reset your heroku db then run merge, and seed commands so you can see your app up and running.
heroku pg:reset DATABASE --confirm YOUR_APP_NAME
heroku run rake db:setup
Then you have to figure a way to populate your local data.

Related

Rails 6 session variables not persisting

I have a relatively new Rails 6 app (Rails 6.1.3.1), so there's not a whole lot of customization yet. However, I cannot get session variables to persist.
For example, if I put something like the following in a controller action:
class PagesController < ApplicationController
skip_before_action :authenticate_user!
def home
byebug
session[:foo] = 'bar'
end
end
I would expect session[:foo] to be nil on the first request, but I would expect it to be set to 'bar' on all subsequent requests. However, it's nil every time.
This is causing a major problem with CSRF functionality, because the session[:_csrf_token] is being reset on every request. This means that no request has a valid CSRF token, so I can't get login to work.
For the life of me, I cannot figure out what is going on. I've tried monkeying around with browser settings and environment settings, but nothing has worked.
I've been banging my head on this for a couple days now. What am I missing? What might cause the session to be reset on every request?
Here is some more context:
# Gemfile
source 'https://rubygems.org'
git_source(:github) { |repo| "https://github.com/#{repo}.git" }
ruby '3.0.1'
gem 'rails', '6.1.3.1'
gem 'pg'
gem 'puma'
gem 'bootsnap', require: false
gem 'jbuilder'
gem 'webpacker'
gem 'redis'
gem 'autoprefixer-rails'
gem 'aws-sdk-s3'
gem 'delayed_job_active_record'
gem 'devise'
gem 'image_processing'
gem 'kaminari'
gem 'money-rails'
gem 'pg_search'
gem 'postmark-rails'
gem 'pundit'
gem 'roadie-rails'
gem 'rollbar'
gem 'sassc-rails'
gem 'tailwindcss-rails'
gem 'view_component', require: 'view_component/engine'
group :development, :test do
gem 'byebug'
end
group :development do
gem 'guard'
gem 'guard-minitest'
gem 'binding_of_caller'
gem 'listen'
gem 'spring'
gem 'web-console'
end
group :test do
gem 'capybara'
gem 'minitest-focus'
gem 'minitest-rails'
gem 'minitest-reporters'
gem 'mocha'
gem 'pdf-inspector'
gem 'selenium-webdriver'
gem 'rexml'
gem 'webdrivers'
end
group :development, :production do
gem 'stripe'
end
# application.rb
require_relative "boot"
require "rails/all"
# Require the gems listed in Gemfile, including any gems
# you've limited to :test, :development, or :production.
Bundler.require(*Rails.groups)
class Env
def self.var(*args)
var = args.join('_').upcase
ENV[var] || Rails.application.credentials[Rails.env.to_sym].dig(*args)
end
end
module Foobar
class Application < Rails::Application
# Initialize configuration defaults for originally generated Rails version.
config.load_defaults 6.1
# Configuration for the application, engines, and railties goes here.
#
# These settings can be overridden in specific environments using the files
# in config/environments, which are processed later.
#
# config.time_zone = "Central Time (US & Canada)"
# config.eager_load_paths << Rails.root.join("extras")
config.autoload_paths += %W( #{config.root}/app/components )
config.autoload_paths += %W( #{config.root}/app/forms )
config.autoload_paths += %W( #{config.root}/app/utilities )
# Look in components folder when determining which classes to include.
config.assets.css_compressor = Tailwindcss::Compressor.new(files_with_class_names: Rails.root.glob("app/components/**/*.*"))
end
end
# application_controller.rb
class ApplicationController < ActionController::Base
include Pundit
protect_from_forgery with: :reset_session, prepend: true
before_action :authenticate_user!
default_form_builder Forms::Builder
attr_writer :title
helper_method :body_class, :title
def authorize(record, query = nil)
super([:authorization, record], query)
end
def body_class
"#{params[:controller].gsub('/', '_')}"
end
def policy_scope(scope)
super([:authorization, scope])
end
def title
#title || default_title
end
private
def default_title
controller_name.singularize.humanize.capitalize
end
end
# development.rb
require "active_support/core_ext/integer/time"
Rails.application.configure do
config.session_store :cache_store
# Settings specified here will take precedence over those in config/application.rb.
# In the development environment your application's code is reloaded any time
# it changes. This slows down response time but is perfect for development
# since you don't have to restart the web server when you make code changes.
config.cache_classes = false
# Do not eager load code on boot.
config.eager_load = false
# Show full error reports.
config.consider_all_requests_local = true
# Enable/disable caching. By default caching is disabled.
# Run rails dev:cache to toggle caching.
if Rails.root.join('tmp', 'caching-dev.txt').exist?
config.action_controller.perform_caching = true
config.action_controller.enable_fragment_cache_logging = true
config.cache_store = :memory_store
config.public_file_server.headers = {
'Cache-Control' => "public, max-age=#{2.days.to_i}"
}
else
config.action_controller.perform_caching = false
config.cache_store = :null_store
end
# Store uploaded files on the local file system (see config/storage.yml for options).
config.active_storage.service = :local
# Don't care if the mailer can't send.
config.action_mailer.raise_delivery_errors = false
config.action_mailer.perform_caching = false
config.action_mailer.default_url_options = { host: 'localhost', port: 3000 }
# Print deprecation notices to the Rails logger.
config.active_support.deprecation = :log
# Raise exceptions for disallowed deprecations.
config.active_support.disallowed_deprecation = :raise
# Tell Active Support which deprecation messages to disallow.
config.active_support.disallowed_deprecation_warnings = []
# Raise an error on page load if there are pending migrations.
config.active_record.migration_error = :page_load
# Highlight code that triggered database queries in logs.
config.active_record.verbose_query_logs = true
# Debug mode disables concatenation and preprocessing of assets.
# This option may cause significant delays in view rendering with a large
# number of complex assets.
config.assets.debug = false
# Suppress logger output for asset requests.
config.assets.quiet = true
# Raises error for missing translations.
# config.i18n.raise_on_missing_translations = true
# Annotate rendered view with file names.
# config.action_view.annotate_rendered_view_with_filenames = true
# Use an evented file watcher to asynchronously detect changes in source code,
# routes, locales, etc. This feature depends on the listen gem.
config.file_watcher = ActiveSupport::EventedFileUpdateChecker
# Uncomment if you wish to allow Action Cable access from any origin.
# config.action_cable.disable_request_forgery_protection = true
end
Ok, found the problem. Turns out that I had copied the setting config.session_store :cache_store in development.rb from a different project I had been working on. However, this setting was added as part of the StimulusReflex setup for that other project.
From the StimulusReflex docs:
Cookie-based session storage is not currently supported by StimulusReflex.
Instead, we enable caching in the development environment so that we can assign our user session data to be managed by the cache store.
The default setting for this option is cookie_store. By changing it to :cache_store without specifying a cache repo, it implements ActionDispatch::Session::CacheStore and defaults to storing it in Rails.cache, which uses the :file_store option, which dumps it in tmp/cache.
However, further down in development.rb, there is some conditional logic that assigns config.cache_store to :null_store if there is no caching-dev.txt file. This implements ActiveSupport::Cache::NullStore, which is "a cache store implementation which doesn't actually store anything."
So because I had not enabled caching with rails dev:cache for this project, the session cache was getting toasted with every request.
LESSON LEARNED: Be very careful when copying config settings from an old project to a new one!

Message: Failure/Error: require File.expand_path('../../config/environment', __FILE__)

First i read other posts of users with similiar problems, but couldnt come along where my mistake is. I wanted to start a test with RSpec on the following file:
dashboard_view_spec.rb:
require 'rails_helper'
RSpec.feature "Dashboard", type: :feature do
before(:each) do
#current_user = User.create!(email: "xyz#xyz.com", password: "xyz123")
sign_in_with(#current_user.email,#current_user.password)
end
#NAV BAR RSPEC TEST
scenario 'Home bar nav link present' do
visit "/"
expect(page).to have_text('Home')
end
scenario 'How it work nav bar link present' do
visit "/"
expect(page).to have_text('How it work')
end
scenario 'Support nav bar link present' do
visit "/"
expect(page).to have_text('Support')
end
end
On rails_helper.rb on the top:
# This file is copied to spec/ when you run 'rails generate rspec:install'
ENV['RAILS_ENV'] ||= 'test'
require File.expand_path('../../config/environment', __FILE__)
Dir[Rails.root.join("spec/support/**/*.rb")].each {|f| require f}
# Prevent database truncation if the environment is production
abort("The Rails environment is running in production mode!") if Rails.env.production?
require 'rake'
require 'spec_helper'
require 'rspec/rails'
require 'shoulda/matchers'
require 'capybara/rails'
require 'capybara/rspec'
require 'rspec/retry'
require 'devise'
Error message:
Failure/Error: require File.expand_path('../../config/environment', __FILE__)
NoMethodError:
undefined method `[]' for nil:NilClass
# ./config/initializers/devise.rb:258:in `block in <top (required)>'
# ./config/initializers/devise.rb:5:in `<top (required)>'
# ./config/environment.rb:5:in `<top (required)>'
# ./spec/rails_helper.rb:4:in `require'
# ./spec/rails_helper.rb:4:in `<top (required)>'
# ./spec/views/dashboard_view_spec.rb:1:in `require'
# ./spec/views/dashboard_view_spec.rb:1:in `<top (required)>'
No examples found.
Randomized with seed 14549
Then the command i used on the terminal
bundle exec rspec spec/views/dashboard_view_spec.rb
After watching the documentation of testing with Devise i changed the code in dashboard_view_spec.rb and used to sign_in as a user and got the same error message.
Line 258 of devise.rb
config.omniauth :facebook, Rails.application.secrets.facebook[:key], Rails.application.secrets.facebook[:secret], scope: 'email', info_fields: 'email, name'
In the gemfile
group :development, :test do
# Call 'byebug' anywhere in the code to stop execution and get a debugger console
gem 'byebug', platforms: [:mri, :mingw, :x64_mingw]
# Adds support for Capybara system testing and selenium driver
gem 'capybara', '~> 2.13'
gem 'selenium-webdriver'
gem 'rspec-rails', '~> 3.8'
gem 'factory_girl_rails'
gem 'faker'
gem 'database_cleaner'
end
and
group :development do
# Access an IRB console on exception pages or by using <%= console %> anywhere in the code.
gem 'web-console', '>= 3.3.0'
gem 'listen', '>= 3.0.5', '< 3.2'
# Spring speeds up development by keeping your application running in the background. Read more: https://github.com/rails/spring
gem 'spring'
gem 'spring-watcher-listen', '~> 2.0.0'
end
The problem is that you're missing a variable that your devise initializer expects to find, but only missing it in the test environment. (not the development environment)
The stack trace that you provided and line 258 from config/initializers/devise.rb are all that are needed. First, let's look at the stack trace:
NoMethodError:
undefined method `[]' for nil:NilClass
# ./config/initializers/devise.rb:258:in `block in <top (required)>'
# ./config/initializers/devise.rb:5:in `<top (required)>'
# ./config/environment.rb:5:in `<top (required)>'
# ./spec/rails_helper.rb:4:in `require'
# ./spec/rails_helper.rb:4:in `<top (required)>'
# ./spec/views/dashboard_view_spec.rb:1:in `require'
# ./spec/views/dashboard_view_spec.rb:1:in `<top (required)>'
Starting from the bottom up, we can see that the first line of your spec is what's causing the issue. If you follow the stack you'll see that it ends up in config/initializers/devise.rb:258 and is complaining that something making a [] method call isn't getting the expected object type in return, and is instead getting nil in return.
Looking at line 258 you find:
config.omniauth :facebook, Rails.application.secrets.facebook[:key], Rails.application.secrets.facebook[:secret], scope: 'email', info_fields: 'email, name'
So you can see that there are two times that [] is called:
Rails.application.secrets.facebook[:key]
Rails.application.secrets.facebook[:secret]
What is expected is that calling Rails.application.secrets.facebook will return an Enumerable object (like an array or a hash) but instead it is returning nil, and when it attempts to run nil[:key] or nil[:secret] it raises an exception because NilClass is not an Enumerable and does not have a [] method. You can test this yourself in the rails console:
nil[:secret]
=> NoMethodError: undefined method `[]' for nil:NilClass
The solution is to ensure that calling Rails.application.secrets.facebook returns the expected object type. The short answer is to edit config/secrets.yml to ensure that the values you require for the test environment are present.
I haven't worked with devise in a long time, but I assume that you can safely use the same values that you're using for the development environment for the test environment. You can read more about secrets() elsewhere, but the basic template for config/secrets.yml is as follows:
environment:
key: value
For example:
test:
my_secret_key: my_secret_value
It should be fairly straightforward to copy and paste the missing facebook secrets into the test environment. After making the change you can verify it worked:
$ RAILS_ENV=test rails console
Rails.application.secrets.facebook[:key]
=> <your key here>
If that worked, then run your spec with rspec and it should successfully get past line 1. (assuming there are no other bugs or missing secrets)
I had very similar errors. Here's how I solved
Run rspec --backtrace
This could produce a lot of console output. Scroll right to the top, and start reading from the top. It will tell you the file your problem started in, and the line it happened on. Go to that file (and that line), and figure out what's missing.
In my case, it was actually a missing variable in credentials.yml, but cases will vary. Like in the excellent answer by #anothermh, it's basically telling you something is missing, so you have to figure out what's missing and make sure you provide it.
Just got the same error, but when I ran bundle exec rake spec instead of bundle exec rspec it worked.

How to require ''pg" gem on iron.io with iron_worker

.worker file
runtime "ruby"
name "UserMailer"
merge_gem "activerecord", "=3.2.8"
merge_gem 'actionmailer', '=3.2.8'
merge_gem 'devise', '=2.1.2'
merge_gem 'pg', "=0.14.0"
merge_file "../app/views/user_mailer/new_user.html.erb" , "user_mailer"
merge_file "../app/mailers/user_mailer.rb"
merge_dir "../app/models"
merge_exec "user_mailer_worker.rb"
.rb file
require 'action_mailer'
require 'active_record'
require 'pg'
require 'bcrypt'
require 'devise'
require 'user_mailer.rb'
require 'models/user.rb'
def init_mailer
#Need to convert to proper hashes
mailer_config = params['mailer'].inject({}) { |memo, (k, v)| memo[k.to_sym] = v; memo }
# set default views dir to current dir
ActionMailer::Base.prepend_view_path('.')
ActionMailer::Base.smtp_settings = mailer_config
ActionMailer::Base.delivery_method = :smtp
end
def setup_database
puts "Database connection details:#{params['database'].inspect}"
return unless params['database']
# estabilsh database connection
ActiveRecord::Base.establish_connection(params['database'])
end
init_mailer
setup_database
puts "I got '#{params.inspect}' parameters"
#send email!
# you could use here any active_record queries with models
UserMailer.new_user(User.find(params[:id])).deliver!
I have uploaded code to iron worker but i got following output
Skipping ruby gem with name='pg' and version='0.14.0' as it contains native extensions, switching to full remote build should fix this
and after i queue task on iron.io i got error
/usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require': cannot load such file -- pg (LoadError)
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /task/user_mailer_worker.rb:4:in `<top (required)>'
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from __runner__.rb:190:in `<main>'
how to require 'pg' gem on iron.io ??
Add this line to .worker file:
full_remote_build true

Initialising new rails project after upgrading to Ruby 1.9.3

I have been working on Ruby on rails project for a while now, when I followed the instructions in the newest instalment of Agile Web Development in Rails and installed the newest edition of Ruby. Before I only used the version that comes with OSX Lion, but with rvm I have installed this version:
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]
When I set this to execute using e.g. irb this works great, also running scripts with the ruby command line tool works good.
My problem is that when I start a new project with 'rails new', or run the server or the console, rails won't work. I have the Rails 3.2.3 version.
The error stacks is as follows:
BigMac:Coding ola$ rails new depot
create
create README.rdoc
create Rakefile
create config.ru
create .gitignore
create Gemfile
create app
create app/assets/images/rails.png
create app/assets/javascripts/application.js
create app/assets/stylesheets/application.css
create app/controllers/application_controller.rb
create app/helpers/application_helper.rb
create app/mailers
create app/models
create app/views/layouts/application.html.erb
create app/mailers/.gitkeep
create app/models/.gitkeep
create config
create config/routes.rb
create config/application.rb
create config/environment.rb
create config/environments
create config/environments/development.rb
create config/environments/production.rb
create config/environments/test.rb
create config/initializers
create config/initializers/backtrace_silencers.rb
create config/initializers/inflections.rb
create config/initializers/mime_types.rb
create config/initializers/secret_token.rb
create config/initializers/session_store.rb
create config/initializers/wrap_parameters.rb
create config/locales
create config/locales/en.yml
create config/boot.rb
create config/database.yml
create db
create db/seeds.rb
create doc
create doc/README_FOR_APP
create lib
create lib/tasks
create lib/tasks/.gitkeep
create lib/assets
create lib/assets/.gitkeep
create log
create log/.gitkeep
create public
create public/404.html
create public/422.html
create public/500.html
create public/favicon.ico
create public/index.html
create public/robots.txt
create script
create script/rails
create test/fixtures
create test/fixtures/.gitkeep
create test/functional
create test/functional/.gitkeep
create test/integration
create test/integration/.gitkeep
create test/unit
create test/unit/.gitkeep
create test/performance/browsing_test.rb
create test/test_helper.rb
create tmp/cache
create tmp/cache/assets
create vendor/assets/javascripts
create vendor/assets/javascripts/.gitkeep
create vendor/assets/stylesheets
create vendor/assets/stylesheets/.gitkeep
create vendor/plugins
create vendor/plugins/.gitkeep
run bundle install
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:799: [BUG] Segmentation fault
ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-darwin11.4.0]
-- Control frame information -----------------------------------------------
c:0038 p:---- s:0217 b:0217 l:000216 d:000216 CFUNC :connect
c:0037 p:0011 s:0214 b:0214 l:0019a0 d:000213 BLOCK /Users/ola/.rvm/rubies/ruby-1.9.3- p194/lib/ruby/1.9.1/net/http.rb:799
c:0036 p:0031 s:0212 b:0212 l:000211 d:000211 METHOD /Users/ola/.rvm/rubies/ruby-1.9.3- p194/lib/ruby/1.9.1/timeout.rb:54
c:0035 p:0026 s:0200 b:0200 l:000199 d:000199 METHOD /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/timeout.rb:99
c:0034 p:0485 s:0194 b:0194 l:0019a0 d:0019a0 METHOD /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:799
c:0033 p:0011 s:0186 b:0186 l:000185 d:000185 METHOD /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:755
c:0032 p:0089 s:0183 b:0183 l:000182 d:000182 METHOD /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:750
c:0031 p:0340 s:0180 b:0180 l:000179 d:000179 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/net/http/persistent.rb:224
c:0030 p:0157 s:0172 b:0172 l:000171 d:000171 METHOD /Users/ola/.rvm/gems/ruby-1.9.3- p194#global/gems/bundler-1.1.3/lib/bundler/vendor/net/http/persistent.rb:358
c:0029 p:0081 s:0158 b:0158 l:000157 d:000157 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:135
c:0028 p:0105 s:0150 b:0150 l:000149 d:000149 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:163
c:0027 p:0141 s:0140 b:0140 l:000139 d:000139 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:122
c:0026 p:0178 s:0130 b:0130 l:000129 d:000129 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:70
c:0025 p:0042 s:0122 b:0122 l:000111 d:000121 BLOCK /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:234
c:0024 p:---- s:0117 b:0117 l:000116 d:000116 FINISH
c:0023 p:---- s:0115 b:0115 l:000114 d:000114 CFUNC :each
c:0022 p:0079 s:0112 b:0112 l:000111 d:000111 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:232
c:0021 p:0018 s:0102 b:0102 l:000101 d:000101 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:165
c:0020 p:0025 s:0098 b:0098 l:000097 d:000097 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:70
c:0019 p:0059 s:0095 b:0094 l:000076 d:000093 BLOCK /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:205
c:0018 p:---- s:0090 b:0090 l:000089 d:000089 FINISH
c:0017 p:---- s:0088 b:0088 l:000087 d:000087 CFUNC :each
c:0016 p:0043 s:0085 b:0085 l:000076 d:000084 BLOCK /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:202
c:0015 p:0020 s:0081 b:0081 l:000080 d:000080 METHOD /Users/ola/.rvm/gems/ruby-1.9.3- p194#global/gems/bundler-1.1.3/lib/bundler/index.rb:9
c:0014 p:0031 s:0077 b:0077 l:000076 d:000076 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:198
c:0013 p:0139 s:0074 b:0071 l:000070 d:000070 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:192
c:0012 p:0027 s:0066 b:0066 l:000065 d:000065 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:127
c:0011 p:0047 s:0060 b:0060 l:000059 d:000059 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:122
c:0010 p:0303 s:0057 b:0057 l:000056 d:000056 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/installer.rb:48
c:0009 p:0033 s:0051 b:0051 l:000050 d:000050 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/installer.rb:12
c:0008 p:0978 s:0044 b:0044 l:000043 d:000043 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/cli.rb:220
c:0007 p:0036 s:0036 b:0036 l:000035 d:000035 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/task.rb:22
c:0006 p:0071 s:0030 b:0030 l:000029 d:000029 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/invocation.rb:118
c:0005 p:0221 s:0024 b:0024 l:000023 d:000023 METHOD /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor.rb:263
c:0004 p:0082 s:0013 b:0013 l:000012 d:000012 METHOD /Users/ola/.rvm/gems/ruby-1.9.3 -p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/base.rb:386
c:0003 p:0054 s:0007 b:0007 l:001ba8 d:0024a0 EVAL /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/bin/bundle:13
c:0002 p:---- s:0004 b:0004 l:000003 d:000003 FINISH
c:0001 p:0000 s:0002 b:0002 l:001ba8 d:001ba8 TOP
-- Ruby level backtrace information ----------------------------------------
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/bin/bundle:13:in `<main>'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler- 1.1.3/lib/bundler/vendor/thor/base.rb:386:in `start'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor.rb:263:in `dispatch'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/invocation.rb:118:in `invoke_task'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/task.rb:22:in `run'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/cli.rb:220:in `install'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/installer.rb:12:in `install'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/installer.rb:48:in `run'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:122:in `resolve_remotely!'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:127:in `specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:192:in `resolve'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:198:in `index'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/index.rb:9:in `build'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:202:in `block in index'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:202:in `each'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb:205:in `block (2 levels) in index'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:70:in `specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:165:in `fetch_specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:232:in `remote_specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:232:in `each'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb:234:in `block in remote_specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:70:in `specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:122:in `fetch_remote_specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:163:in `fetch_dependency_remote_specs'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb:135:in `fetch'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/net/http/persistent.rb:358:in `request'
/Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/net/http/persistent.rb:224:in `connection_for'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:750:in `start'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:755:in `do_start'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:799:in `connect'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/timeout.rb:99:in `timeout'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/timeout.rb:54:in `timeout'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:799:in `block in connect'
/Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb:799:in `connect'
-- C level backtrace information -------------------------------------------
See Crash Report log file under ~/Library/Logs/CrashReporter or
/Library/Logs/CrashReporter, for the more detail of.
-- Other runtime information -----------------------------------------------
* Loaded script: /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/bin/bundle
* Loaded features:
0 enumerator.so
1 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/enc/encdb.bundle
2 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/enc/trans/transdb.bundle
3 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/defaults.rb
4 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/rbconfig.rb
5 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/deprecate.rb
6 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/exceptions.rb
7 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb
8 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems.rb
9 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/ubygems.rb
10 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/version.rb
11 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/requirement.rb
12 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/platform.rb
13 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/specification.rb
14 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/path_support.rb
15 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/dependency.rb
16 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/etc.bundle
17 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/fileutils.rb
18 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/pathname.bundle
19 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/pathname.rb
20 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/syntax_error.rb
21 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/psych.bundle
22 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/stringio.bundle
23 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/node.rb
24 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/stream.rb
25 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/document.rb
26 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/sequence.rb
27 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/scalar.rb
28 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/mapping.rb
29 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes/alias.rb
30 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/nodes.rb
31 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/streaming.rb
32 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors/visitor.rb
33 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/strscan.bundle
34 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/scalar_scanner.rb
35 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors/to_ruby.rb
36 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors/emitter.rb
37 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors/yaml_tree.rb
38 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/json/ruby_events.rb
39 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors/json_tree.rb
40 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors/depth_first.rb
41 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/visitors.rb
42 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/handler.rb
43 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/tree_builder.rb
44 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/parser.rb
45 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/omap.rb
46 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/set.rb
47 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/coder.rb
48 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/core_ext.rb
49 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/date_core.bundle
50 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/date/format.rb
51 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/date.rb
52 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/deprecated.rb
53 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/stream.rb
54 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/json/yaml_events.rb
55 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/json/tree_builder.rb
56 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/json/stream.rb
57 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych/handlers/document_stream.rb
58 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/psych.rb
59 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/yaml.rb
60 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/psyched_yaml.rb
61 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/gem_helpers.rb
62 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/match_platform.rb
63 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/rubygems_ext.rb
64 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/config_file.rb
65 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/psych_additions.rb
66 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/psych_tree.rb
67 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/syck_hack.rb
68 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/rubygems_integration.rb
69 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/version.rb
70 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler.rb
71 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/core_ext/hash_with_indifferent_access.rb
72 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/core_ext/ordered_hash.rb
73 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/error.rb
74 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/shell.rb
75 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/invocation.rb
76 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/parser/argument.rb
77 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/parser/arguments.rb
78 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/parser/option.rb
79 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/parser/options.rb
80 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/parser.rb
81 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/task.rb
82 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/util.rb
83 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/base.rb
84 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor.rb
85 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/common.rb
86 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/generic.rb
87 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/ftp.rb
88 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/http.rb
89 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/https.rb
90 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/ldap.rb
91 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/ldaps.rb
92 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri/mailto.rb
93 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/uri.rb
94 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/core_ext/file_binary_read.rb
95 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions/empty_directory.rb
96 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions/create_file.rb
97 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions/create_link.rb
98 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions/directory.rb
99 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/erb.rb
100 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/time.rb
101 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/open-uri.rb
102 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions/file_manipulation.rb
103 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions/inject_into_file.rb
104 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/actions.rb
105 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendored_thor.rb
106 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/user_interaction.rb
107 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/cli.rb
108 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/delegate.rb
109 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/tmpdir.rb
110 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/thread.rb
111 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/tempfile.rb
112 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/shell/basic.rb
113 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/thor/shell/color.rb
114 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/ui.rb
115 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/settings.rb
116 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/shared_helpers.rb
117 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/socket.bundle
118 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/socket.rb
119 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/timeout.rb
120 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/protocol.rb
121 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/zlib.bundle
122 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/net/http.rb
123 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/net/http/faster.rb
124 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/cgi/core.rb
125 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/cgi/cookie.rb
126 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/cgi/util.rb
127 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/cgi.rb
128 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/vendor/net/http/persistent.rb
129 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/fetcher.rb
130 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/tsort.rb
131 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/dependency_list.rb
132 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/f_sync_dir.rb
133 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/tar_header.rb
134 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/enc/iso_8859_1.bundle
135 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/tar_input.rb
136 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/tar_output.rb
137 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/tar_reader/entry.rb
138 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/tar_reader.rb
139 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package/tar_writer.rb
140 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/package.rb
141 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/format.rb
142 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/ext/builder.rb
143 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/ext/configure_builder.rb
144 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/optparse.rb
145 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/command.rb
146 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/ext/ext_conf_builder.rb
147 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/ext/rake_builder.rb
148 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/ext.rb
149 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/require_paths_builder.rb
150 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/installer.rb
151 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/remote_fetcher.rb
152 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/errors.rb
153 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/text.rb
154 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/spec_fetcher.rb
155 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/site_ruby/1.9.1/rubygems/dependency_installer.rb
156 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/environment.rb
157 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/installer.rb
158 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/digest.bundle
159 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/digest.rb
160 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/digest/sha1.bundle
161 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/set.rb
162 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/definition.rb
163 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/dependency.rb
164 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/dsl.rb
165 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/open3.rb
166 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/gem_installer.rb
167 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/source.rb
168 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/forwardable.rb
169 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/spec_set.rb
170 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/resolver.rb
171 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/dep_proxy.rb
172 /Users/ola/.rvm/gems/ruby-1.9.3-p194#global/gems/bundler-1.1.3/lib/bundler/index.rb
173 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/openssl.bundle
174 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/bn.rb
175 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/cipher.rb
176 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/config.rb
177 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/digest.rb
178 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/buffering.rb
179 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/x86_64-darwin11.4.0/fcntl.bundle
180 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/ssl-internal.rb
181 /Users/ola/.rvm/rubies/ruby-1.9.3-p194/lib/ruby/1.9.1/openssl/x509-internal.rb
182 /Users/ola/.rvm/rubi
Just happened to me the same, probably you are using rvm + macports.
I found the solution in the RVM documentation: https://rvm.io/integration/macports/
In order to use MacPorts libraries when installing RVM Rubies, set the
following variables in your $HOME/.rvmrc:
export CFLAGS="-O2 -arch x86_64"
export LDFLAGS="-L/opt/local/lib"
export CPPFLAGS="-I/opt/local/include"
rvm install 1.9.3 --with-opt-dir=/opt/local
Try gem update bundler once before doing this.

Cannot start server with "rack-recaptcha" gem

I have followed steps, described in rack-recaptcha readme.
I have done all the steps, instead of "You have to require 'rack-recaptcha' in your gemfile."
Server is unable to start, because of a following error:
Booting Mongrel
=> Rails 2.3.5 application starting on http://127.0.0.1:3001
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:440:in `load_missing_constant'
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:80:in `const_missing'
/{path_to_my_project}/config/environment.rb:29
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/initializer.rb:111:in `run'
/{path_to_my_project}/config/environment.rb:9
/Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
/Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:156:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:521:in `new_constants_in'
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/activesupport-2.3.5/lib/active_support/dependencies.rb:156:in `require'
/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/commands/server.rb:84
/Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `gem_original_require'
/Library/Ruby/Site/1.8/rubygems/custom_require.rb:31:in `require' ./script/server:3
/Library/Ruby/Gems/1.8/gems/ruby-debug-ide-0.4.9/lib/ruby-debug-ide.rb:109:in `debug_load'
/Library/Ruby/Gems/1.8/gems/ruby-debug-ide-0.4.9/lib/ruby-debug-ide.rb:109:in `debug_program'
/Library/Ruby/Gems/1.8/gems/ruby-debug-ide-0.4.9/bin/rdebug-ide:87
/usr/bin/rdebug-ide:19:in `load'
/usr/bin/rdebug-ide:19
-e:2:in `load'
-e:2
Uncaught exception: uninitialized constant Rack::Recaptcha
I think, the step with "gemfile", that i'm skipped, is the reason of this error.
But, i don't know, where should i look for the mentioned "gemfile" ?
Help, please
Update:
environment.rb is following
# Be sure to restart your server when you modify this file
# Specifies gem version of Rails to use when vendor/rails is not present
RAILS_GEM_VERSION = '2.3.5' unless defined? RAILS_GEM_VERSION
# Bootstrap the Rails environment, frameworks, and default configuration
require File.join(File.dirname(__FILE__), 'boot')
Rails::Initializer.run do |config|
# Settings in config/environments/* take precedence over those specified here.
# Application configuration should go into files in config/initializers
# -- all .rb files in that directory are automatically loaded.
# Add additional load paths for your own custom dirs
#config.load_paths += %W( #{RAILS_ROOT}/extras )
config.load_paths += %W( #{RAILS_ROOT}/public )
# Specify gems that this application depends on and have them installed with rake gems:install
# config.gem "bj"
# config.gem "hpricot", :version => '0.6', :source => "http://code.whytheluckystiff.net"
config.gem "sqlite3-ruby", :lib => "sqlite3"
# config.gem "aws-s3", :lib => "aws/s3"
# NOTE: jquery.js must be updated to the latest version 1.4.2
# to avoid differences in behaviour of HTML makeup and Rails
config.gem 'jrails'
config.gem 'nokogiri
config.gem 'uuid
config.gem 'rack-recaptcha', :lib => 'rack/recaptcha'
config.middleware.use Rack::Recaptcha, :public_key => 'my_secret', :private_key => 'my_secret', :paths => 'http://localhost:3001/my_controller'
# Only load the plugins named here, in the order given (default is alphabetical).
# :all can be used as a placeholder for all plugins not explicitly named
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
# Skip frameworks you're not going to use. To use Rails without a database,
# you must remove the Active Record framework.
# config.frameworks -= [ :active_record, :active_resource, :action_mailer ]
# Activate observers that should always be running
# config.active_record.observers = :cacher, :garbage_collector, :forum_observer
config.active_record.observers = :user_observer
# Set Time.zone default to the specified zone and make Active Record auto-convert to this zone.
# Run "rake -D time" for a list of tasks for finding time zone names.
config.time_zone = 'UTC'
# The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
# config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}')]
config.i18n.default_locale = :ru
end
The Gemfile is a packaging element introduced in Rails 3. As you're running Rails 2 you need to do something slightly different. In you environment.rb add this line inside the Rails::Initializer.run block:
config.gem 'rack-recaptcha', :lib => 'rack/recaptcha'
I've figured it out.
I must add "require" statement for reCAPTCHA library

Resources