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

Add pueblo.util.proc.process utility #39

Merged
merged 1 commit into from
Dec 5, 2023
Merged

Add pueblo.util.proc.process utility #39

merged 1 commit into from
Dec 5, 2023

Conversation

amotl
Copy link
Member

@amotl amotl commented Dec 4, 2023

About

This snippet is a wrapper around subprocess.Popen to also terminate child processes after exiting.

Source

It has been conceived at mlflow-cratedb::tests/util.py. There, it takes care of terminating an embedded MLflow instance spawned when running ml training programs in standalone mode.

Origin

The code has been shared by @pcattori at https://gist.github.com/jizhilong/6687481#gistcomment-3057122. Thanks!

@amotl amotl force-pushed the util-process branch 2 times, most recently from 0818116 to c8a1acc Compare December 5, 2023 21:39
@amotl amotl changed the title Add pueblo.util.command.process utility Add pueblo.util.proc.process utility Dec 5, 2023
It is a wrapper around `subprocess.Popen` to also terminate child
processes after exiting.
Copy link

codecov bot commented Dec 5, 2023

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (692a135) 75.21% compared to head (8240dd4) 75.35%.

Files Patch % Lines
pueblo/util/proc.py 81.25% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main      #39      +/-   ##
==========================================
+ Coverage   75.21%   75.35%   +0.13%     
==========================================
  Files          20       21       +1     
  Lines         694      710      +16     
==========================================
+ Hits          522      535      +13     
- Misses        172      175       +3     
Flag Coverage Δ
main 75.35% <81.25%> (+0.13%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@amotl amotl marked this pull request as ready for review December 5, 2023 21:57
@amotl amotl merged commit a7379fe into main Dec 5, 2023
4 checks passed
@amotl amotl deleted the util-process branch December 5, 2023 22:12
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.

None yet

1 participant