title: Errors in Gemfile
body: <p>I've cloned my app from Github but I've got errors on Gemfile. So I think, this app. is still running on heroku and it said that all up to date when I've used following commands:</p>
  
  <pre><code> git status 
  //On branch master
  Your branch is up-to-date with 'origin/master'.
  nothing to commit, working tree clean
  
   git push  heroku
  //Everything up-to-date
  </code></pre>
  
  <p>Also I could see output in heroku.
  How to fix the error in Gemfile?
  thanks.</p>
  
  <pre><code>//error as below:
  There was an error parsing `Gemfile`: The `branch` option for `gem 'recaptcha'` is not allowed. Only gems with a git source can specify a branch. Bundler cannot continue.
  
   #  from /home/ubuntu/workspace/typo-1/Gemfile:46
   #  -------------------------------------------
   #  gem 'acts_as_tree_rails3'
   &gt;  gem 'recaptcha', :require =&gt; 'recaptcha/rails', :branch =&gt; 'rails3'
   #  
  </code></pre>
  
  <p>//Gemfile </p>
  
  <pre><code>env = ENV["RAILS_ENV"] || 'development'
  dbfile = File.expand_path("../config/database.yml", __FILE__)
  
  #unless File.exists?(dbfile)
  #  raise "You need to configure config/database.yml first"
  #else
  #  conf = YAML.load(File.read(dbfile))
  #  adapter = conf[env]['adapter']
  #  raise "You need define an adapter in your database.yml" if adapter == '' || adapter.nil?
  #  case adapter
  #  when 'sqlite3'
  #    gem 'sqlite3'
  #  when 'postgresql'
  #    gem 'pg'
  #  when 'mysql'
  #    gem 'sam-mysql-ruby'
  #  else
  #    raise "Don't know what gem to use for adapter #{adapter}"
  #  end
  #end
  
  group :production do
    gem 'pg'
  end
  
  source 'https://rubygems.org'
  ruby "1.9.3"
  
  gem 'thin'
  gem 'rails', '~&gt; 3.0.10'
  gem 'require_relative'
  gem 'htmlentities'
  gem 'json'
  gem 'bluecloth', '~&gt; 2.1'
  gem 'coderay', '~&gt; 0.9'
  gem 'kaminari'
  gem 'RedCloth', '~&gt; 4.2.8'
  gem 'addressable', '~&gt; 2.1', :require =&gt; 'addressable/uri'
  gem 'mini_magick', '~&gt; 1.3.3', :require =&gt; 'mini_magick'
  gem 'uuidtools', '~&gt; 2.1.1'
  gem 'flickraw-cached'
  gem 'rubypants', '~&gt; 0.2.0'
  gem 'rake', '~&gt; 0.9.2'
  gem 'acts_as_list'
  gem 'acts_as_tree_rails3'
  gem 'recaptcha', :require =&gt; 'recaptcha/rails', :branch =&gt; 'rails3'
  
  group :development, :test do
    gem 'ruby-debug19'
    gem 'factory_girl', '~&gt; 2.2'
    gem 'webrat'
    gem 'rspec-rails', '~&gt; 2.0'
    gem 'simplecov', :require =&gt; false
    gem 'sqlite3'
    gem 'cucumber'
    gem 'cucumber-rails', :require =&gt; false
    gem 'cucumber-rails-training-wheels'
    gem 'database_cleaner'
    gem 'capybara'
  end
  </code></pre>
  
  <p>//edited
  I took off branch but got error as below when run bundle install:
  bundle install</p>
  
  <p>"Your Ruby version is 2.3.0, but your Gemfile specified 1.9.3"</p>
  
  <p>Version 2.4 create the same error. So,I've changed to 2.3.0 - it went through until  another error as below:</p>
  
  <p>Results logged to
  /usr/local/rvm/gems/ruby-2.3.0/extensions/x86_64-linux/2.3.0/json-1.7.5/gem_make.out</p>
  
  <p>An error occurred while installing json (1.7.5), and Bundler cannot continue.
  Make sure that <code>gem install json -v '1.7.5'</code> succeeds before bundling.</p>
  
  <p>//editing </p>
  
  <p>I've follow the answer suggested to  use the old version 1.9.2 and I be able to use command bundle install but after pushing to heroku, I've got empty page on heroku and errors as below:</p>
  
  <p>//errors</p>
  
  <pre><code>2017-07-23T18:09:50.995656+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.0/lib/thin/controllers/controller.rb:181:in `load_rackup_config'
  2017-07-23T18:09:50.995657+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.0/lib/thin/controllers/controller.rb:71:in `start'
  2017-07-23T18:09:50.995657+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.0/lib/thin/runner.rb:187:in `run_command'
  2017-07-23T18:09:50.995658+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.0/lib/thin/runner.rb:152:in `run!'
  2017-07-23T18:09:50.995659+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/gems/thin-1.5.0/bin/thin:6:in `&lt;top (required)&gt;'
  2017-07-23T18:09:50.995659+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/bin/thin:23:in `load'
  2017-07-23T18:09:50.995660+00:00 app[web.1]:   /app/vendor/bundle/ruby/1.9.1/bin/thin:23:in `&lt;top (required)&gt;'
  2017-07-23T18:09:51.185918+00:00 heroku[web.1]: Process exited with status 1
  2017-07-23T18:09:51.200309+00:00 heroku[web.1]: State changed from starting to crashed
  2017-07-23T18:09:51.845236+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=typoa.herokuapp.com request_id=7c8caa3e-8bad-4431-9da6-8ddf2f52a4d1 fwd="108.211.182.6" dyno= connect= service= status=503 bytes= protocol=https
  2017-07-23T18:19:04.542770+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=typoa.herokuapp.com request_id=798e1c83-078a-4da6-b2cd-dfbf47b80687 fwd="108.211.182.6" dyno= connect= service= status=503 bytes= protocol=https
  </code></pre>
  
  <p>//edited</p>
  
  <p>When I took off  suggested line( with recaptcha), I could not see app. locally.
  With this line I could see app. locally.</p>
  
  <p>Errors without this line as below:</p>
  
  <pre><code>rails server -b $IP -p $PORT
  =&gt; Booting WEBrick
  =&gt; Rails 3.0.17 application starting in development on http://0.0.0.0:8080
  =&gt; Call with -d to detach
  =&gt; Ctrl-C to shutdown server
  Exiting
  
  
      home/ubuntu/workspace/typo-1/config/initializers/recaptcha.rb:1:in `&lt;top (required)&gt;': uninitialized constant Recaptcha (NameError)
              from /usr/local/rvm/gems/ruby-1.9.3-p551/gems/railties-3.0.17/lib/rails/engine.rb:201:in `block (2 levels) in &lt;class:Engine&gt;'
  </code></pre>
  
  <p>In any cases, I could not push to heroku: 
  Errors as below(it recommends to use the latest version of Ruby):</p>
  
  <pre><code>Ruby app detected
  remote: -----&gt; Compiling Ruby/Rails
  remote:  !
  remote:  !     An error occurred while installing ruby-1.9.3
  remote:  !     
  remote:  !     Heroku recommends you use the latest supported Ruby version listed here:
  </code></pre>
  
  <p>//edit
  I could not find a working app to see the solution of  this problem...Error message as below:
  <a href="http://typosphere.org/stable.tar.gz#" rel="nofollow noreferrer">http://typosphere.org/stable.tar.gz#</a></p>