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

(#28) Ensure sigterm is handled by coverage #63

Merged
merged 1 commit into from
Jul 22, 2023

Conversation

imranariffin
Copy link
Owner

@imranariffin imranariffin commented Jul 21, 2023

This way, coverage can collect data before process termination

Issue was coverage does not handle sigterm by default, so it couldn't get to collect data upon termination: nedbat/coveragepy#1307 (comment)

Need to explicitly tell coverage to handle sigterm: https://coverage.readthedocs.io/en/latest/changes.html#version-6-4-2022-05-22

@codecov-commenter
Copy link

codecov-commenter commented Jul 21, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +4.58 🎉

Comparison is base (5c368d7) 94.59% compared to head (f46bf4b) 99.18%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #63      +/-   ##
==========================================
+ Coverage   94.59%   99.18%   +4.58%     
==========================================
  Files          17       17              
  Lines         555      613      +58     
==========================================
+ Hits          525      608      +83     
+ Misses         30        5      -25     
Impacted Files Coverage Δ
src/aiotaskq/__main__.py 85.00% <ø> (ø)
src/aiotaskq/interfaces.py 100.00% <ø> (ø)
src/tests/test_cli.py 100.00% <ø> (ø)
src/aiotaskq/task.py 98.30% <100.00%> (ø)
src/aiotaskq/worker.py 100.00% <100.00%> (+17.51%) ⬆️
src/tests/apps/simple_app.py 100.00% <100.00%> (+5.00%) ⬆️
src/tests/conftest.py 100.00% <100.00%> (ø)
src/tests/test_concurrency.py 100.00% <100.00%> (ø)
src/tests/test_integration.py 100.00% <100.00%> (ø)

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

This way, coverage can collect data before process termination

Signed-off-by: Imran Ariffin <ariffin.imran@gmail.com>
@imranariffin imranariffin force-pushed the 28/fix-coverage-not-covering-sub-process branch from effeca7 to f46bf4b Compare July 22, 2023 01:40
@imranariffin imranariffin merged commit 10f264e into main Jul 22, 2023
@imranariffin imranariffin deleted the 28/fix-coverage-not-covering-sub-process branch July 22, 2023 02:15
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