Gemfile parsing error for gem'pg'

Alex's Avatar


15 Sep, 2017 09:34 PM

I've included gem 'pg', '0.18.1', group: :production in my Gemfile and get the following error:

[!] There was an error parsing `Gemfile`: syntax error, unexpected '(', expecting end-of-input - group: :productiongit_source(:github) do |repo_name|
                              ^. Bundler cannot continue.
 > gem 'pg', '0.18.1', group: :productiongit_source(:github) do |repo_name|
 # repo_name = "#{repo_name}/#{repo_name}" unless repo_name.include?("/")
 # -------------------------------------------

Even if I remove the line I still get this error. I'm trying to launch in Heroku and can't move further.
Can I get some help.

Thank you, Alex

  1. Support Staff 1 Posted by Evan Phoenix on 15 Sep, 2017 10:01 PM

    Evan Phoenix's Avatar

    This forum is for help, not really bundler. That being said, the problem is a syntax error in the Gemfile. It looks like you're missing a newline after production perhaps? Try doing ruby -c Gemfile to see the syntax errors.

  2. Evan Phoenix closed this discussion on 15 Sep, 2017 10:01 PM.

Comments are currently closed for this discussion. You can start a new one.

Keyboard shortcuts


? Show this help
ESC Blurs the current field

Comment Form

r Focus the comment reply box
^ + ↩ Submit the comment

You can use Command ⌘ instead of Control ^ on Mac