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

Remove .ONESHELL Makefile directive so multi-step targets properly fail #2888

Merged
merged 1 commit into from
Aug 16, 2022

Conversation

kevin-bates
Copy link
Member

#2886 documents an issue where the lint-server Makefile target does not stop when the flake8 portion of the multi-step target encounters a non-zero exit code. Based on initial investigation, there appears to have been a change in behavior between GNU make 3.81 (which I, and probably others, use on our desktops) and 4.2.1 (which is used in CI, with 4.3 being the latest). In versions < 4, the multi-step targets will stop on non-zero exit status, but with versions < 4, that is not the case.

It turns out that the .ONESHELL directive was causing this issue - which makes sense - because only the last command of the target is the status that is checked. Not sure why 3.x versions work - perhaps they don't properly support .ONESHELL.

At any rate, .ONESHELL was added in #2721 and there's no mention during the review as to why. I have confirmed appropriate behavior without the directive so perhaps the reason for it is no longer present or it was thought to be an improvement - especially since desktop builds were still behaving okay. Since this is a fairly serious issue, we should move forward without .ONESHELL and tackle any related issues of that when they come up.

Resolves #2886

Developer's Certificate of Origin 1.1

   By making a contribution to this project, I certify that:

   (a) The contribution was created in whole or in part by me and I
       have the right to submit it under the Apache License 2.0; or

   (b) The contribution is based upon previous work that, to the best
       of my knowledge, is covered under an appropriate open source
       license and I have the right under that license to submit that
       work with modifications, whether created in whole or in part
       by me, under the same open source license (unless I am
       permitted to submit under a different license), as indicated
       in the file; or

   (c) The contribution was provided directly to me by some other
       person who certified (a), (b) or (c) and I have not modified
       it.

   (d) I understand and agree that this project and the contribution
       are public and that a record of the contribution (including all
       personal information I submit with it, including my sign-off) is
       maintained indefinitely and may be redistributed consistent with
       this project or the open source license(s) involved.

@kevin-bates kevin-bates requested a review from akchinSTC August 16, 2022 16:59
@elyra-bot
Copy link

elyra-bot bot commented Aug 16, 2022

Thanks for making a pull request to Elyra!

To try out this branch on binder, follow this link: Binder

Copy link
Member

@akchinSTC akchinSTC left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

confirmed that once one shell was removed linting and exiting was running as it should
image

@kevin-bates
Copy link
Member Author

Thanks @akchinSTC. I'm curious what version of make you use.

@akchinSTC
Copy link
Member

Thanks @akchinSTC. I'm curious what version of make you use.

image

@akchinSTC akchinSTC merged commit 61ceb4f into elyra-ai:main Aug 16, 2022
@ptitzler ptitzler added kind:bug Something isn't working kind:CI Impacts continuous integration (build, test, etc.) labels Aug 17, 2022
@ptitzler ptitzler added this to the 3.11.0 milestone Aug 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:bug Something isn't working kind:CI Impacts continuous integration (build, test, etc.)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CI does not properly handle lint errors
3 participants