Exit Status Code from Lettuce

83 views
Skip to first unread message

Dave Sykes

unread,
Jun 17, 2012, 6:05:03 PM6/17/12
to lettuc...@googlegroups.com
Hi Guys,

I'm new to lettuce, and am currently working to integrate lettuce, web2y and jenkins. Once I've got it all working, I'll be blogging the working solution.

All is going well, apart from all my jenkins jobs work right until the end where it says the job failed. It appears to be failing because the exit status of the lettuce call is always 1. This is if all my steps pass or not.

I have had a look through the code on GitHub, and think I have found the offending part
result = runner.run()
    failed = bool(result or result.steps != result.steps_passed)
    raise SystemExit(int(failed))
 
Now it appears that the result will be a TotalResult and is created in the finally section of the Runner.Run method

This TotalResult is passed to the @after.all fucntion in terrain.py, so I have tested this, and basically the bool(result or result.steps != result.steps_passed) always returns a true, which is then converted to 1 on the raise SystemExit line.

Is this correct behaviour? I've seen some other issues in the group, where it was returning 1 in other scenarios.

Hope this makes sense, and that I've just made a mistake somewhere, I'm pretty new to Python, so it's quite likely

Thanks
Dave

Dave Sykes

unread,
Jun 17, 2012, 6:07:43 PM6/17/12
to lettuc...@googlegroups.com
Obviously I meant  lettuce, web2py and jenkins there! 

Gabriel Falcão

unread,
Jul 25, 2012, 3:15:31 PM7/25/12
to lettuc...@googlegroups.com
Could you post the code you are using to setup lettuce with web2py so that I can inspect what's wrong?
It's hard to tell what's going on, and lettuce has several automated tests to ensure nothing wrong happens in its side.

 -- Gabriel Falcão
Reply all
Reply to author
Forward
0 new messages