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

Access the left and right of an edge as an interval #2531

Merged
merged 1 commit into from
Sep 24, 2024

Conversation

hyanwong
Copy link
Member

Is this useful at all, or just an extra maintenance burden?

@benjeffery
Copy link
Member

Don't think this is a bad idea - what code do you have where this is good and what is the alternative?

@codecov
Copy link

codecov bot commented Sep 29, 2022

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 89.72%. Comparing base (d6b2303) to head (cfd5df0).
Report is 1 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2531   +/-   ##
=======================================
  Coverage   89.72%   89.72%           
=======================================
  Files          29       29           
  Lines       31578    31581    +3     
  Branches     6117     6118    +1     
=======================================
+ Hits        28333    28336    +3     
  Misses       1853     1853           
  Partials     1392     1392           
Flag Coverage Δ
c-tests 86.55% <ø> (ø)
lwt-tests 80.78% <ø> (ø)
python-c-tests 88.98% <ø> (ø)
python-tests 99.01% <100.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
python/tskit/trees.py 98.78% <100.00%> (+<0.01%) ⬆️

@hyanwong
Copy link
Member Author

Don't think this is a bad idea - what code do you have where this is good and what is the alternative?

I needed to quickly check whether a tree covered a whole edge. tree.interval == edge.interval seems more comprehensible than tree.right == edge.right and tree.left == edge.left, but it's not exactly a priority!

@benjeffery
Copy link
Member

Oh! That's a nice example. Seems like a good addition.

@benjeffery
Copy link
Member

Converting this to a draft as it needs tests.

@benjeffery benjeffery marked this pull request as draft October 3, 2022 11:23
@hyanwong
Copy link
Member Author

hyanwong commented Oct 3, 2022

Yeah, meant to open as a draft, sorry.

@benjeffery
Copy link
Member

@hyanwong Is this still something you want to try and merge?

@hyanwong
Copy link
Member Author

I guess I might as well. The test will be trivial.

@benjeffery
Copy link
Member

Ok, planning to get 0.5.9 out soon will add this PR to that.

@benjeffery benjeffery added this to the Python 0.5.9 milestone Sep 20, 2024
@hyanwong hyanwong marked this pull request as ready for review September 23, 2024 18:27
@benjeffery benjeffery added the AUTOMERGE-REQUESTED Ask Mergify to merge this PR label Sep 24, 2024
@mergify mergify bot merged commit 8a958e9 into tskit-dev:main Sep 24, 2024
21 checks passed
@mergify mergify bot removed the AUTOMERGE-REQUESTED Ask Mergify to merge this PR label Sep 24, 2024
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