trim21 / transmission-rpc

https://transmission-rpc.readthedocs.io/en/stable/
MIT License
139 stars 34 forks source link

fix(log): Expensive DEBUG log always run (#470) #471

Closed rpatterson closed 3 weeks ago

rpatterson commented 3 weeks ago

Don't run expensive JSON serialization for DEBUG logging unless that level would be printed/emitted.

Fixes #470

rpatterson commented 3 weeks ago

I don't see how this change could have caused the docs failure?

trim21 commented 3 weeks ago

I don't see how this change could have caused the docs failure?

not your fault

codecov[bot] commented 3 weeks ago

Codecov Report

Attention: Patch coverage is 50.00000% with 1 line in your changes missing coverage. Please review.

Project coverage is 77.62%. Comparing base (a6b7722) to head (b4eb97b). Report is 1 commits behind head on master.

Files Patch % Lines
transmission_rpc/client.py 50.00% 1 Missing :warning:
Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #471 +/- ## ========================================== - Coverage 77.67% 77.62% -0.06% ========================================== Files 14 14 Lines 1505 1506 +1 ========================================== Hits 1169 1169 - Misses 336 337 +1 ``` | [Flag](https://app.codecov.io/gh/trim21/transmission-rpc/pull/471/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21) | Coverage Δ | | |---|---|---| | [3.10](https://app.codecov.io/gh/trim21/transmission-rpc/pull/471/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21) | `77.62% <50.00%> (-0.06%)` | :arrow_down: | | [3.11](https://app.codecov.io/gh/trim21/transmission-rpc/pull/471/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21) | `77.62% <50.00%> (-0.06%)` | :arrow_down: | | [3.12](https://app.codecov.io/gh/trim21/transmission-rpc/pull/471/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21) | `77.62% <50.00%> (-0.06%)` | :arrow_down: | | [3.8](https://app.codecov.io/gh/trim21/transmission-rpc/pull/471/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21) | `77.42% <50.00%> (-0.06%)` | :arrow_down: | | [3.9](https://app.codecov.io/gh/trim21/transmission-rpc/pull/471/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21) | `77.42% <50.00%> (-0.06%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Trim21#carryforward-flags-in-the-pull-request-comment) to find out more.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.