Skip to content
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

Fix Traceback from compound models when removing items #2490

Merged
merged 1 commit into from
Jan 16, 2024

Conversation

soininen
Copy link
Contributor

@soininen soininen commented Jan 16, 2024

CompoundModelBase.handle_items_removed() now drops single models that become empty. This prevents those models from trying to access deleted entity classes.

Fixes #2483

Checklist before merging

  • Documentation is up-to-date
  • Release notes have been updated
  • Unit tests have been added/updated accordingly
  • Code has been formatted by black
  • Unit tests pass

CompoundModelBase.handle_items_removed() now drops single models
that become empty due to removing of items. This prevents those models
from trying to access deleted entity classes.

Re #2483
@codecov-commenter
Copy link

codecov-commenter commented Jan 16, 2024

Codecov Report

Attention: 3 lines in your changes are missing coverage. Please review.

Comparison is base (624ec8e) 63.66% compared to head (466470c) 63.72%.

Files Patch % Lines
...olbox/spine_db_editor/mvcmodels/compound_models.py 84.21% 1 Missing and 2 partials ⚠️

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@             Coverage Diff             @@
##           0.8-dev    #2490      +/-   ##
===========================================
+ Coverage    63.66%   63.72%   +0.05%     
===========================================
  Files          195      195              
  Lines        35487    35564      +77     
  Branches      4996     6039    +1043     
===========================================
+ Hits         22593    22663      +70     
+ Misses       11714    11708       -6     
- Partials      1180     1193      +13     

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

@soininen soininen merged commit 6dcfd4f into 0.8-dev Jan 16, 2024
16 checks passed
@soininen soininen deleted the 2483_fix_compound_models branch January 16, 2024 09:55
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.

2 participants