Fix render_labels silently accepting fill_alpha=0 and outline_alpha=0#644
Merged
Fix render_labels silently accepting fill_alpha=0 and outline_alpha=0#644
Conversation
…=0 and outline_alpha=0 (#630) The dispatch chain's first branch matched `fill_alpha == outline_alpha`, routing the (0, 0) case to the fill-only path with alpha=0 and leaving the existing ValueError as dead code. Add an explicit guard so the error is actually raised.
69b83f5 to
65281f6
Compare
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #644 +/- ##
==========================================
- Coverage 76.39% 76.35% -0.05%
==========================================
Files 11 11
Lines 3237 3239 +2
Branches 761 762 +1
==========================================
Hits 2473 2473
- Misses 466 467 +1
- Partials 298 299 +1
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
render_labels(fill_alpha=0, outline_alpha=0)produced an empty plot (alpha=0 overlay) instead of erroring.fill_alpha == outline_alpha, routing(0, 0)to the fill-only path and leaving the existingelse: raise ValueError(...)unreachable.