Skip to content

Fix alpha handling for negpos bar plots - #866

Merged
cvanelteren merged 2 commits into
mainfrom
fix/865-negpos-bar-alpha
Dec 3, 2026
Merged

cvanelteren merged 2 commits into
mainfrom
fix/865-negpos-bar-alpha

Conversation

@cvanelteren

Copy link
Copy Markdown
Collaborator

Fixes #865.

_call_negpos returns a silent_list of two BarContainer objects, whereas _apply_bar previously assumed a single container when applying per-column alpha. Iterate through both sign containers for negpos=True, preserving the existing return structure and regular bar behavior.

Regression tests cover bar and barh, scalar alpha (0, 0.5, 1), per-column alpha, and drawing the figure.

Validation: 12 isolated Matplotlib cases passed locally, including reproducing the original exception. The full UltraPlot suite and new integration tests were not run locally because the execution environment cannot clone the repository or install UltraPlot; CI validation is pending.

@codecov

codecov Bot commented Dec 3, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@cvanelteren
cvanelteren merged commit c3ae687 into main Dec 3, 2026
22 checks passed
@cvanelteren
cvanelteren deleted the fix/865-negpos-bar-alpha branch December 3, 2026 13:21
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.

bar(negpos=True, alpha=...) raises AttributeError

1 participant