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

Error when running with Rails4, Ruby2 #42

Closed
johnbeynon opened this issue Jul 9, 2013 · 19 comments
Closed

Error when running with Rails4, Ruby2 #42

johnbeynon opened this issue Jul 9, 2013 · 19 comments

Comments

@johnbeynon
Copy link

When running guard-cucumber I get the following output at the end of tests;

/Users/john/.rvm/gems/ruby-2.0.0-p195@mindr/gems/minitest-4.7.5/lib/minitest/unit.rb:1037:in `block in process_args': invalid option: --no-profile (OptionParser::InvalidOption)
        from /Users/john/.rvm/gems/ruby-2.0.0-p195@mindr/gems/minitest-4.7.5/lib/minitest/unit.rb:1016:in `new'
        from /Users/john/.rvm/gems/ruby-2.0.0-p195@mindr/gems/minitest-4.7.5/lib/minitest/unit.rb:1016:in `process_args'
        from /Users/john/.rvm/gems/ruby-2.0.0-p195@mindr/gems/minitest-4.7.5/lib/minitest/unit.rb:1066:in `_run'
        from /Users/john/.rvm/gems/ruby-2.0.0-p195@mindr/gems/minitest-4.7.5/lib/minitest/unit.rb:1059:in `run'
        from /Users/john/.rvm/gems/ruby-2.0.0-p195@mindr/gems/minitest-4.7.5/lib/minitest/unit.rb:795:in `block in autorun'

i don't get this if I run cucumber directly from the command line.

I'm not sure where to start looking.

@johnbeynon
Copy link
Author

I should note, it's the same error on 1.9.3 - so it seems like a Rails4 thing.

@cpb
Copy link
Contributor

cpb commented Jul 10, 2013

Hi @johnbeynon

I haven't been able to reproduce your issue. I've created a skeletal rails app attempting to, but I think I'm missing some details.

I've added you as a collaborator to https://github.com/cpb/guard-cucumber-issue-42 -- could you tweak it to reproduce?

Cheers,
Caleb

@johnbeynon
Copy link
Author

it's so weird, I've been trying to duplicate it in the app but I just can't and somehow in doing so I've managed to get rid of the error that was appearing in mine. Grrrr.

@marnen
Copy link

marnen commented Jul 29, 2013

Still happening for me. Reopen?

@cpb
Copy link
Contributor

cpb commented Jul 30, 2013

@marnen I've added you to my repo that I encouraged @johnbeynon to try and create a repro with. Please push your repro steps to my repo

@marnen
Copy link

marnen commented Jul 30, 2013

I will try to look at this tomorrow.

(@johnbeynon: nice to see a fellow former Fuseboxer in the Rails world!)

@paulspencerwilliams
Copy link

I too reproduced this issue today with vanilla Rails 4 on Ruby 2.p247, cucumber-rails & guard-cucumber.

I've created a script to reproduce it at https://gist.github.com/paulspencerwilliams/6131755

@cpb
Copy link
Contributor

cpb commented Aug 8, 2013

@paulspencerwilliams I got it to reproduce with your script with slight modifications: https://gist.github.com/cpb/6187945

@cpb
Copy link
Contributor

cpb commented Aug 8, 2013

@paulspencerwilliams my latest revision of your repo.sh (omits rspec) and passes... https://gist.github.com/cpb/6187945/revisions

@paulspencerwilliams
Copy link

@cpb strange. I've tried mine, and your two amended scripts and agree with your summary. I also notice that running my script, and your first amendment presents the error on Guard startup. It then repeatedly outputs the error if you invoke 'cucumber' within Guard, but not 'rspec'. Therefore it certainly seems linked to cucumber :-/ Can you advise anything else I can do to help track it down? I'm more than happy to help if I can!

@cpb
Copy link
Contributor

cpb commented Aug 14, 2013

I am encountering this bug presently on a project I am working on.

https://gist.github.com/cpb/6187945 -- changes the sequence, with cucumber first

I just need to get a bigger stack trace now...

@cpb
Copy link
Contributor

cpb commented Aug 14, 2013

Well if not a bigger stack trace:

["--color",
 "--format",
 "progress",
 "--strict",
 "--require",
 "/Users/caleb/.rbenv/versions/2.0.0-p247/lib/ruby/gems/2.0.0/gems/guard-cucumber-1.4.0/lib/guard/cucumber/notification_formatter.rb",
 "--format",
 "Guard::Cucumber::NotificationFormatter",
 "--out",
 "/dev/null",
 "--require",
 "features",
 "features"]

Checkout what cucumber is doing to ARGV

@cpb
Copy link
Contributor

cpb commented Aug 14, 2013

A much more interesting stack trace (though, more of a caller result)

[
#...
"gems/activesupport-4.0.0/lib/active_support/testing/autorun.rb:5:in `<top (required)>'",
"gems/railties-4.0.0/lib/rails/test_help.rb:5:in `<top (required)>'",
"gems/cucumber-rails-1.3.0/lib/cucumber/rails.rb:11:in `<top (required)>'",
"BugReproduce/features/support/env.rb:7:in `require'",
"BugReproduce/features/support/env.rb:7:in `<top (required)>'",
#...
]

@cpb
Copy link
Contributor

cpb commented Aug 14, 2013

@cpb
Copy link
Contributor

cpb commented Aug 14, 2013

@johnbeynon this is a bug from cucumber/rails that apparently has been solved in master 17 hours ago

@cpb
Copy link
Contributor

cpb commented Aug 14, 2013

and then it was reverted

@rwillrich
Copy link

I''m getting the same error. I'm using Ruby 2 and Rails 4, the cucumber-rails gem at version 1.4.0, so as is the guard-cucumber gem.

@rwillrich
Copy link

My stack trace was the following:

/home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/minitest-4.7.5/lib/minitest/unit.rb:1037:in `block in process_args': invalid option: --profile (OptionParser::InvalidOption)
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/minitest-4.7.5/lib/minitest/unit.rb:1016:in `new'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/minitest-4.7.5/lib/minitest/unit.rb:1016:in `process_args'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/minitest-4.7.5/lib/minitest/unit.rb:1066:in `_run'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/minitest-4.7.5/lib/minitest/unit.rb:1059:in `run'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/minitest-4.7.5/lib/minitest/unit.rb:795:in `block in autorun'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application.rb:72:in `fork'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application.rb:72:in `serve'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application.rb:55:in `block in run'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application.rb:49:in `loop'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application.rb:49:in `run'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application.rb:43:in `start'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:96:in `block in start_child'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:83:in `fork'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:83:in `start_child'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:26:in `start'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:53:in `block in with_child'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:20:in `synchronize'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:42:in `with_child'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/application_manager.rb:61:in `run'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/server.rb:54:in `serve'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/server.rb:41:in `block in boot'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/server.rb:41:in `loop'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/server.rb:41:in `boot'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/server.rb:19:in `boot'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/client/run.rb:33:in `block in boot_server'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/client/run.rb:31:in `fork'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/client/run.rb:31:in `boot_server'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/client/run.rb:16:in `call'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/client/command.rb:7:in `call'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/lib/spring/client.rb:23:in `run'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/gems/spring-0.0.10/bin/spring:6:in `<top (required)>'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/bin/spring:23:in `load'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/bin/spring:23:in `<main>'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/bin/ruby_noexec_wrapper:14:in `eval'
    from /home/rwillrich/.rvm/gems/ruby-2.0.0-p247@universidade-ja/bin/ruby_noexec_wrapper:14:in `<main>'

@copyhacker
Copy link

Bundling cucumber-rails at edge seems to solve this for me.

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

6 participants