Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #65 +/- ##
==========================================
+ Coverage 88.38% 88.41% +0.03%
==========================================
Files 62 62
Lines 3064 3074 +10
==========================================
+ Hits 2708 2718 +10
Misses 356 356 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
There was a problem hiding this comment.
Pull request overview
Adds point symbol support to the pygfx backend by translating scenex.model.SymbolName values into pygfx.PointsMarkerMaterial.marker values, with warnings for unsupported symbols.
Changes:
- Implement
_snx_set_symbolfor the pygfxPointsadaptor, including a few alias translations and a warning path for unsupported symbols. - Add a new parametrized test covering all
SymbolNamevalues, including alias handling and expected warnings for unsupported markers.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
src/scenex/adaptors/_pygfx/_points.py |
Implements pygfx marker selection logic for Points.symbol, with aliases and warnings for unsupported symbols. |
tests/adaptors/_pygfx/test_points.py |
Adds coverage for symbol updates across all SymbolName options, including unsupported-symbol warning behavior. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
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.
Somehow point symbols were overlooked to this point for pygfx. This PR adds them in.
@tlambert03, since you wrote
scenex.model.SymbolName: there are many symbol types that pertain only to pygfx that aren't in that list, and conversely some symbols that the pygfx backend can't (without a custom marker type, which is some additional effort) handle. We should probably come up with a strategy to address that for each backend (maybe just makeSymbolNamethe union of all supported markers, and only support some in each backend?) - but we can address this in another PR, for sure