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 #60: "strand sometimes no conserved when AvoidPattern is localized" #61

Merged
merged 5 commits into from
Sep 6, 2021

Conversation

Zulko
Copy link
Member

@Zulko Zulko commented Jul 21, 2021

This fixes #60 (@veghp @deto). Changes:

  • The fix: In overlap_region(self), the final location always gets the strand of self.
  • Cosmetic: I renamed variable names (to left_location and right_location) in overlap_region because 5-year-ago me wrote this method in a very confusing way.
  • Added a new test based on @deto's example in Issue with AvoidPattern (and potentially other builtin_specifications) #60. The test fails before this MR, succeeds after.
  • Formatting: The commit is a bit polluted by a couple of auto-edits from running black to format the files (sorry for that), but didn't want to undo the changes as they go in the right direction.

I didn't version-bump because I'm not 100% sure what the workflow is there @veghp

@Zulko Zulko requested a review from veghp July 21, 2021 19:51
@Zulko Zulko changed the title Fix #60: "strand sometimes no conserved if AvoidPattern is localized" Fix #60: "strand sometimes no conserved when AvoidPattern is localized" Jul 21, 2021
@Zulko Zulko changed the base branch from master to dev July 21, 2021 20:48
return None

start = right_location.start
end = min(left_location.end, right_location.end)
strand = self.strand
Copy link
Member

Choose a reason for hiding this comment

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

This is a duplicate line -- see line 43 -- just double checking if you had something else in mind.

@Zulko
Copy link
Member Author

Zulko commented Sep 4, 2021

@veghp I belive this can be merged and released, closing #60 .

@veghp veghp merged commit 8a2b0d2 into dev Sep 6, 2021
@veghp
Copy link
Member

veghp commented Sep 6, 2021

Thanks, I merged with dev -- Travis seems to be down, so I'll release it once it's okay. Also addressed #53 to be released with it.

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.

Issue with AvoidPattern (and potentially other builtin_specifications)
2 participants