Implement 'find_feature' Utility Function in SBOL Tutorial#237
Open
vinayakjeet wants to merge 2 commits intoSynBioDex:developfrom
Open
Implement 'find_feature' Utility Function in SBOL Tutorial#237vinayakjeet wants to merge 2 commits intoSynBioDex:developfrom
vinayakjeet wants to merge 2 commits intoSynBioDex:developfrom
Conversation
Contributor
|
Tests are failing, but currently only the two caused by #231, so the testing is sufficient to proceed to a full review. |
jakebeal
requested changes
Apr 7, 2024
Contributor
jakebeal
left a comment
There was a problem hiding this comment.
This function looks reasonable, but needs to have a test added to demonstrate that it is, in fact, behaving as expected.
| :return: true if circular | ||
| """ | ||
| return any(n==sbol3.SO_CIRCULAR for n in obj.types) No newline at end of file | ||
| return any(n==sbol3.SO_CIRCULAR for n in obj.types) |
Contributor
There was a problem hiding this comment.
Per standard Python style, there should be two blank lines before the new function.
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
find_featurefunction to enhance feature search within SBOL documents, addressing issue find_feature #185.find_feature(doc: sbol3.Document, matching: Callable[[sbol3.Feature], bool]) -> Optional[sbol3.Feature]sbol3.Componentobjects in the givensbol3.Document.matchingcallable to eachsbol3.Featureto determine if it meets the specified condition.sbol3.Feature, orNoneif no match is found.closes #185