-
Notifications
You must be signed in to change notification settings - Fork 172
a more generalized solution for cif parsing #2165
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
base: main
Are you sure you want to change the base?
Conversation
jamesmkrieger
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good and I've tested pieces and it seems to work as expected.
It would be good to have a unit test for this too
AnthonyBogetti
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's come up with a unit test for this before merging.
|
test_ciffile.py |
Why do we need a modified version? Surely it’s better to have an additional one and keep checking that old ones work too? |
The test_ciffile.py file itself is modified, but all existing tests should have been left untouched. The new test to cover the changes in this PR was added to the end of the file. Sorry, I should have been more clear. |
Fix _getBiomoltrans to robustly parse mmCIF oper_expression: accept alphanumeric op IDs (X0, P), expand ranges anywhere (incl. inside lists), and handle products of groups like (X0)(1-5).