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: Fix bug when loading already created project causing hide of ROI layer #787

Merged
merged 28 commits into from
Nov 13, 2022

Conversation

Czaki
Copy link
Collaborator

@Czaki Czaki commented Nov 9, 2022

No description provided.

@sourcery-ai
Copy link
Contributor

sourcery-ai bot commented Nov 9, 2022

Sourcery Code Quality Report

✅  Merging this PR will increase code quality in the affected files by 0.07%.

Quality metrics Before After Change
Complexity 2.07 ⭐ 2.08 ⭐ 0.01 👎
Method Length 107.35 🙂 106.50 🙂 -0.85 👍
Working memory 6.72 🙂 6.73 🙂 0.01 👎
Quality 69.81% 🙂 69.88% 🙂 0.07% 👍
Other metrics Before After Change
Lines 3621 3643 22
Changed files Quality Before Quality After Quality Change
package/PartSeg/common_gui/napari_image_view.py 64.80% 🙂 64.56% 🙂 -0.24% 👎
package/tests/test_PartSeg/conftest.py 85.21% ⭐ 86.29% ⭐ 1.08% 👍
package/tests/test_PartSeg/test_napari_image_view.py 71.55% 🙂 72.07% 🙂 0.52% 👍
package/tests/test_PartSegCore/test_measurements.py 71.40% 🙂 71.40% 🙂 0.00%

Here are some functions in these files that still need a tune-up:

File Function Complexity Length Working Memory Quality Recommendation
package/PartSeg/common_gui/napari_image_view.py ImageView._add_image 19 😞 326 ⛔ 8 🙂 39.54% 😞 Refactor to reduce nesting. Try splitting into smaller methods
package/PartSeg/common_gui/napari_image_view.py ImageView.__init__ 3 ⭐ 757 ⛔ 14 😞 40.17% 😞 Try splitting into smaller methods. Extract out complex expressions
package/PartSeg/common_gui/napari_image_view.py ImageView.print_info 19 😞 178 😞 11 😞 41.13% 😞 Refactor to reduce nesting. Try splitting into smaller methods. Extract out complex expressions
package/PartSeg/common_gui/napari_image_view.py ImageView.component_mark 14 🙂 262 ⛔ 10 😞 41.47% 😞 Try splitting into smaller methods. Extract out complex expressions
package/PartSeg/common_gui/napari_image_view.py ImageView._mark_layer 8 ⭐ 259 ⛔ 45.88% 😞 Try splitting into smaller methods

Legend and Explanation

The emojis denote the absolute quality of the code:

  • ⭐ excellent
  • 🙂 good
  • 😞 poor
  • ⛔ very poor

The 👍 and 👎 indicate whether the quality has improved or gotten worse with this pull request.


Please see our documentation here for details on how these metrics are calculated.

We are actively working on this report - lots more documentation and extra metrics to come!

Help us improve this quality report!

@Czaki Czaki changed the title fix: fix bug when loading already created project causing hide of ROI layer fix: Fix bug when loading already created project causing hide of ROI layer Nov 9, 2022
@deprecated-napari-hub-preview-bot
Copy link

deprecated-napari-hub-preview-bot bot commented Nov 9, 2022

Preview page for your plugin is ready here:
https://preview.napari-hub.org/4DNucleome/PartSeg/787
Updated: 2022-11-13T13:58:15.812045

@codecov
Copy link

codecov bot commented Nov 9, 2022

Codecov Report

Base: 89.79% // Head: 89.83% // Increases project coverage by +0.04% 🎉

Coverage data is based on head (bd3e844) compared to base (7510307).
Patch coverage: 96.72% of modified lines in pull request are covered.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop     #787      +/-   ##
===========================================
+ Coverage    89.79%   89.83%   +0.04%     
===========================================
  Files          192      195       +3     
  Lines        29811    30043     +232     
===========================================
+ Hits         26768    26989     +221     
- Misses        3043     3054      +11     
Impacted Files Coverage Δ
package/PartSeg/common_gui/napari_image_view.py 87.82% <92.85%> (+0.44%) ⬆️
package/tests/test_PartSeg/conftest.py 96.06% <100.00%> (+6.54%) ⬆️
...ckage/tests/test_PartSeg/test_napari_image_view.py 100.00% <100.00%> (ø)
...ackage/tests/test_PartSegCore/test_measurements.py 100.00% <100.00%> (ø)
package/PartSeg/common_gui/equal_column_layout.py 88.70% <0.00%> (-1.46%) ⬇️
package/PartSegCore/mask/io_functions.py 87.62% <0.00%> (-1.04%) ⬇️
...tSeg/plugins/napari_widgets/search_label_widget.py 92.30% <0.00%> (-0.77%) ⬇️
package/tests/test_PartSeg/test_main_windows.py 100.00% <0.00%> (ø)
package/tests/conftest.py 92.45% <0.00%> (ø)
...ests/test_PartSeg/roi_analysis/test_main_window.py 100.00% <0.00%> (ø)
... and 5 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@Czaki Czaki added this to the v0.14.6 milestone Nov 10, 2022
changelog.md Outdated Show resolved Hide resolved
tox.ini Outdated Show resolved Hide resolved
tox.ini Outdated Show resolved Hide resolved
@Czaki Czaki merged commit 994088d into develop Nov 13, 2022
@Czaki Czaki deleted the bugfix/layer_proper_order branch November 13, 2022 14:36
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.

1 participant