Skip to content

Fix Cube Fit component initialization #3727

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

rosteen
Copy link
Collaborator

@rosteen rosteen commented Aug 13, 2025

Fixes initializing a model component when a spectral subset is selected and Cube Fit is toggled on (specifically with a cube with spectral axis index of 0). I also took the opportunity to avoid sending data through the glue-astronomy translators just to get a subset mask and instead use the Glue to_mask method on the data object itself.

I'll try to add some coverage before merging, opening as draft to see if the tests pass here before I mark ready for review.

@rosteen rosteen added this to the 4.3.1 milestone Aug 13, 2025
@rosteen rosteen added bug Something isn't working cubeviz plugin Label for plugins common to multiple configurations labels Aug 13, 2025
@rosteen rosteen force-pushed the fix-cube-component-initialization branch from 1ec3cc1 to 5c8a415 Compare August 13, 2025 18:57
Copy link

codecov bot commented Aug 13, 2025

Codecov Report

❌ Patch coverage is 85.71429% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 86.28%. Comparing base (34725b6) to head (dd1af11).

Files with missing lines Patch % Lines
jdaviz/core/helpers.py 0.00% 1 Missing ⚠️
jdaviz/core/template_mixin.py 92.30% 1 Missing ⚠️

❌ Your patch check has failed because the patch coverage (85.71%) is below the target coverage (90.00%). You can increase the patch coverage or adjust the target coverage.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3727   +/-   ##
=======================================
  Coverage   86.28%   86.28%           
=======================================
  Files         177      177           
  Lines       23922    23928    +6     
=======================================
+ Hits        20640    20647    +7     
+ Misses       3282     3281    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@rosteen rosteen marked this pull request as ready for review August 13, 2025 19:31
@rosteen
Copy link
Collaborator Author

rosteen commented Aug 13, 2025

The coverage missing in template_mixin.py is getting flagged because I changed a string there, I'm not going to worry about covering that code for now.

Copy link
Contributor

@MatthewPortman MatthewPortman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working cubeviz plugin Label for plugins common to multiple configurations
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants