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

Fix return code when subprocess fails #33

Merged
merged 7 commits into from
Sep 28, 2024

Conversation

git-developer
Copy link

This PR fixes the following problem: when a subprocess fails, the application returns with exit code 0.

This behaviour complicates AppImage tests because output must be parsed to check if a test failed.

A GitHub Action run is available

@C0rn3j
Copy link
Owner

C0rn3j commented Sep 28, 2024

For the things you're adding and reworking in the Python part, could you please add types for both the function variables and returns?

I've edited the PR to have docstrings and at least the obvious str type as I don't have my usual editor atm.

@git-developer
Copy link
Author

Tried my best, but it's not my main business, please check.

@C0rn3j C0rn3j merged commit 926b053 into C0rn3j:python3 Sep 28, 2024
1 check passed
@C0rn3j
Copy link
Owner

C0rn3j commented Sep 28, 2024

Thanks!
The run_osd_tool just straight out exits and doesn't return anything.
I added some more since I already had it open.

I highly recommend you setup your editor to actually makes use of the type hints if you haven't already, it's fairly convoluted to navigate the codebase without them.

Not that a lot of it is covered by them yet...

@git-developer
Copy link
Author

git-developer commented Sep 29, 2024

Thanks for your review and the code style improvements!

@git-developer git-developer deleted the fix-return-code branch September 29, 2024 06:24
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

Successfully merging this pull request may close these issues.

2 participants