Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

syntax error in all commands #317

Open
cascer1 opened this issue Dec 7, 2016 · 3 comments
Open

syntax error in all commands #317

cascer1 opened this issue Dec 7, 2016 · 3 comments

Comments

@cascer1
Copy link

cascer1 commented Dec 7, 2016

Hi,

I am trying out prmd, but no matter which command I run, I always get a syntax error:

root@PC0075:/mnt/.../spec$ prmd verify definitions.json
/var/lib/gems/1.9.1/gems/prmd-0.12.0/lib/prmd/commands.rb:4:in `require_relative': /var/lib/gems/1.9.1/gems/prmd-0.12.0/lib/prmd/commands/verify.rb:78: syntax error, unexpected tLABEL (SyntaxError)
    def self.verify(schema_data, custom_schema: nil)
                                               ^
/var/lib/gems/1.9.1/gems/prmd-0.12.0/lib/prmd/commands/verify.rb:97: syntax error, unexpected tLABEL
  def self.verify(schema_data, custom_schema: nil)
                                             ^
        from /var/lib/gems/1.9.1/gems/prmd-0.12.0/lib/prmd/commands.rb:4:in `<top (required)>'
        from /var/lib/gems/1.9.1/gems/prmd-0.12.0/lib/prmd.rb:3:in `require_relative'
        from /var/lib/gems/1.9.1/gems/prmd-0.12.0/lib/prmd.rb:3:in `<top (required)>'
        from /var/lib/gems/1.9.1/gems/prmd-0.12.0/bin/prmd:3:in `require_relative'
        from /var/lib/gems/1.9.1/gems/prmd-0.12.0/bin/prmd:3:in `<top (required)>'
        from /usr/local/bin/prmd:23:in `load'
        from /usr/local/bin/prmd:23:in `<main>'

I'm running Ruby version 1.9.3 on Bash on Ubuntu on Windows.

prmd version is 0.12.0

@geemus
Copy link
Member

geemus commented Dec 8, 2016

The code uses a syntax option for hashes that was added in the 1.9 series of ruby, but the error here seems to imply that the version being used doesn't support it? Is there any way you could bump to a newer version of ruby?

@cascer1
Copy link
Author

cascer1 commented Dec 9, 2016

I just used apt-get to update to the latest version:

$ apt-get update
...
$ apt-get upgrade ruby
...
$ ruby --version
ruby 1.9.3p484 (2013-11-22 revision 43786) [x86_64-linux]

Unfortunately, I still get the same error.

@geemus
Copy link
Member

geemus commented Dec 9, 2016

Hmm. Commands seem to be working ok in other contexts, and the ruby 1.9 series is deprecated in favor of the higher 2.0 rubies at this point, which makes me reticent to try and support these older versions. You may need to get ruby from somewhere other than that source in order to get a non-deprecated version, then you should hopefully have better luck.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants