Skip to content

Conversation

@gloriayma
Copy link
Collaborator

Previously the check to see if a node is a leaf was degree(node) == 1, but this can mistakenly flag the root of the tree (which may have in degree 0, out degree 1, for a total degree of 1).

@codecov
Copy link

codecov bot commented Dec 4, 2025

Codecov Report

❌ Patch coverage is 78.29181% with 61 lines in your changes missing coverage. Please review.
✅ Project coverage is 85.39%. Comparing base (8b36987) to head (7e5df4e).
⚠️ Report is 16 commits behind head on master.

Files with missing lines Patch % Lines
src/cassiopeia/critique/compare.py 54.02% 40 Missing ⚠️
src/cassiopeia/data/CassiopeiaTree.py 92.15% 8 Missing ⚠️
src/cassiopeia/critique/critique_utilities.py 22.22% 7 Missing ⚠️
src/cassiopeia/plotting/deprecated.py 54.54% 5 Missing ⚠️
src/cassiopeia/data/utilities.py 97.05% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           master     #283       +/-   ##
===========================================
+ Coverage   74.91%   85.39%   +10.47%     
===========================================
  Files          94       76       -18     
  Lines        8454     5914     -2540     
===========================================
- Hits         6333     5050     -1283     
+ Misses       2121      864     -1257     
Files with missing lines Coverage Δ
src/cassiopeia/__init__.py 87.50% <100.00%> (ø)
src/cassiopeia/critique/__init__.py 100.00% <ø> (ø)
src/cassiopeia/data/Layers.py 83.78% <100.00%> (ø)
src/cassiopeia/data/__init__.py 100.00% <ø> (ø)
src/cassiopeia/mixins/__init__.py 100.00% <100.00%> (ø)
src/cassiopeia/mixins/errors.py 100.00% <ø> (ø)
src/cassiopeia/mixins/logging.py 100.00% <ø> (ø)
src/cassiopeia/mixins/utilities.py 100.00% <100.00%> (ø)
src/cassiopeia/mixins/warnings.py 100.00% <100.00%> (ø)
src/cassiopeia/plotting/__init__.py 100.00% <100.00%> (ø)
... and 66 more
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@gloriayma gloriayma changed the base branch from master to 3.0.0 December 4, 2025 17:16
…alculate_parsimony in tree_metrics"

This reverts commit d1a0aed.

Revert accidental commits
@colganwi
Copy link
Collaborator

colganwi commented Dec 4, 2025

Thanks for flagging this @gloriayma! I encountered the bug a few weeks ago and patched with #282. Just merge the 3.0.0 branch into your branch to get the patch.

@colganwi colganwi closed this Dec 4, 2025
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.

3 participants