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

BoostCalcQt segfaults on travis #169

Closed
konserw opened this issue Sep 13, 2017 · 12 comments
Closed

BoostCalcQt segfaults on travis #169

konserw opened this issue Sep 13, 2017 · 12 comments

Comments

@konserw
Copy link
Contributor

konserw commented Sep 13, 2017

Summary

Travis fails for all (3 of them) PRs: https://travis-ci.org/cucumber/cucumber-cpp/pull_requests since 2 weeks ago
Reason is boost version of calcqt example, not sure why as it runs well on my linux machine.

Possible Solution

I'll check if it fails also when using unix sockets, but it is more like workaround, not the solution.

Exact error message:


+wait %

+[ -f build/examples/CalcQt/QtTestCalculatorQtSteps -a -n :99 ]

+[ -f build/examples/CalcQt/BoostCalculatorQtSteps -a -n :99 ]

+sleep 1

+build/examples/CalcQt/BoostCalculatorQtSteps

+cucumber examples/CalcQt

# language: en

Feature: Addition

  In order to avoid silly mistakes

  As a math idiot 

  I want to be told the sum of two numbers

  Scenario Outline: Add two numbers       # examples/CalcQt/features/addition.feature:7

    Given I just turned on the calculator # examples/CalcQt/features/addition.feature:8

    When I press <button1>                # examples/CalcQt/features/addition.feature:9

    And I press add                       # examples/CalcQt/features/addition.feature:10

    And I press <button2>                 # examples/CalcQt/features/addition.feature:11

    And I press calculate                 # examples/CalcQt/features/addition.feature:12

    Then the display should show <result> # examples/CalcQt/features/addition.feature:13

    Examples: 

      | button1 | button2 | result |

      | 2       | 3       | 5      |

      Timed out calling wire server with message 'invoke' (Timeout::Error)

      examples/CalcQt/features/addition.feature:17:in `Given I just turned on the calculator'

      examples/CalcQt/features/addition.feature:8:in `Given I just turned on the calculator'

Timed out calling wire server with message 'step_matches' (Timeout::Error)

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/connection.rb:43:in `block in fetch_data_from_socket'

/home/travis/.rvm/rubies/ruby-2.4.1/lib/ruby/2.4.0/timeout.rb:108:in `timeout'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/connection.rb:43:in `fetch_data_from_socket'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/connection.rb:20:in `call_remote'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/request_handler.rb:10:in `execute'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/wire_protocol/requests.rb:14:in `execute'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/wire_protocol.rb:8:in `step_matches'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/wire_language.rb:34:in `block in step_matches'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/wire_language.rb:34:in `map'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/wire_support/wire_language.rb:34:in `step_matches'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime/support_code.rb:214:in `block in matches'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime/support_code.rb:213:in `map'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime/support_code.rb:213:in `matches'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime/support_code.rb:201:in `step_match_without_cache'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime/support_code.rb:195:in `step_match'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime/support_code.rb:138:in `find_match'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/filters/activate_steps.rb:28:in `attempt_to_activate'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/filters/activate_steps.rb:24:in `map'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/filters/activate_steps.rb:24:in `new_test_steps'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/filters/activate_steps.rb:18:in `test_case'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/filters/activate_steps.rb:8:in `test_case'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/test/case.rb:21:in `describe_to'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/filters/quit.rb:11:in `test_case'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/test/case.rb:21:in `describe_to'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/test/filters/locations_filter.rb:17:in `block in done'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/test/filters/locations_filter.rb:16:in `each'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/test/filters/locations_filter.rb:16:in `done'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/filter.rb:61:in `done'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/test/filters/tag_filter.rb:18:in `done'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/compiler.rb:23:in `done'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core/gherkin/parser.rb:31:in `done'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core.rb:29:in `parse'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-core-1.1.3/lib/cucumber/core.rb:18:in `compile'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/runtime.rb:70:in `run!'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/lib/cucumber/cli/main.rb:38:in `execute!'

/home/travis/.rvm/gems/ruby-2.4.1/gems/cucumber-2.0.0/bin/cucumber:9:in `<top (required)>'

/home/travis/.rvm/gems/ruby-2.4.1/bin/cucumber:23:in `load'

/home/travis/.rvm/gems/ruby-2.4.1/bin/cucumber:23:in `<main>'

/home/travis/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:15:in `eval'

/home/travis/.rvm/gems/ruby-2.4.1/bin/ruby_executable_hooks:15:in `<main>'

The command "./travis.sh" exited with 1.

Done. Your build exited with 1.

@konserw
Copy link
Contributor Author

konserw commented Sep 13, 2017

I've triggered travis build for my new branch based on master without any changes and it fails as well:
https://travis-ci.org/konserw/cucumber-cpp/jobs/275224230
See here if it works with unix socks: https://travis-ci.org/konserw/cucumber-cpp/builds/275225967
EDIT:
Ok unix sockets didn't help. There is still timeout. I wonder what might have changed in travis during last 2 weeks.

konserw added a commit to konserw/cucumber-cpp that referenced this issue Sep 18, 2017
@konserw
Copy link
Contributor Author

konserw commented Sep 18, 2017

I've created PR #170 - It is more like workaround - using old travis image fixes our false fails in CI.
I think we should merge it ASAP and then think about next steps. Maybe contact travis team? What else can we do apart of disabling xvfb - based tests?

@muggenhor
Copy link
Contributor

Could you create a bug report at https://github.com/travis-ci/travis-ci for this?

@konserw
Copy link
Contributor Author

konserw commented Sep 22, 2017

done: travis-ci/travis-ci#8481 Care to add anything ?

konserw added a commit to konserw/cucumber-cpp that referenced this issue Sep 23, 2017
@muggenhor
Copy link
Contributor

I've added some extra code to get some extra debugging from the travis script. That produces this: https://travis-ci.org/muggenhor/cucumber-cpp/jobs/279609591

It seems that we're getting an exit code 139 from the step definition executable, which is a bashism for signal 139-128=11 aka SIGSEGV. I.e. we're getting a memory access violation, so probably have a bug somewhere that's being triggered. So maybe this is not a buggy Travis but instead something flaky with our code that we're lucky enough to have Travis trigger for us.

@muggenhor muggenhor changed the title BoostCalcQt fails on travis BoostCalcQt segfaults on travis Sep 25, 2017
@konserw
Copy link
Contributor Author

konserw commented Sep 26, 2017

I wonder how is this possible as new (failing) and old (OK) travis images have the exact same versions of gcc, gmock, boost, qt, bash, docker, cmake, ruby, xvfb (although on the new image it is preinstlled, not from apt)
There is small difference in versions of git, kernel, clang
And the code is the same. And it's fine on OSX (on travis), Windows (appveyor), Arch (my PC)

@muggenhor
Copy link
Contributor

I'm wondering the same, which is why I tried to make it produce a coredump and have gdb analyze it: for some reason the problem turns into an apparent deadlock then (10 minutes no terminal output timeout causes Travis to kill it then).

konserw added a commit to konserw/cucumber-cpp that referenced this issue Oct 3, 2017
Switch to old travis linux image to fix issue cucumber#169
Enable Xvfb driven examples execution on OSX
Move Xvfb-related logic to functions in bash script
konserw added a commit to konserw/cucumber-cpp that referenced this issue Oct 3, 2017
Switch to old travis linux image to fix issue cucumber#169
Enable Xvfb driven examples execution on OSX
Move Xvfb-related logic to functions in bash script
@konserw
Copy link
Contributor Author

konserw commented Oct 8, 2017

Ok, so after merging #170 I've kicked builds for #164 and #165 - now linux builds pass, and OSX fail on killing Xvfb - any idea why? Master branch build after merging is green...

@muggenhor
Copy link
Contributor

Have you tried restarting just the OSX build for those?

@konserw
Copy link
Contributor Author

konserw commented Oct 9, 2017

Yes - same result :/

@konserw
Copy link
Contributor Author

konserw commented Oct 13, 2017

(just for information of others) Ok, so for old PRs rebasing onto of master is needed to get all green travis ;)

@mattwynne
Copy link
Member

I'm closing this due to inactivity.

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

No branches or pull requests

3 participants