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

Consistency Issues with PDB & MMTF IO for structure 5EIL #426

Closed
t0mdavid-m opened this issue Sep 18, 2022 · 0 comments · Fixed by #427
Closed

Consistency Issues with PDB & MMTF IO for structure 5EIL #426

t0mdavid-m opened this issue Sep 18, 2022 · 0 comments · Fixed by #427

Comments

@t0mdavid-m
Copy link
Member

t0mdavid-m commented Sep 18, 2022

For the purpose of testing the added functionality in #425, I added the structure with the PDB ID 5EIL to the test data. While the tests for filter.py are passing as expected, the tests test_array_conversion() in test_pbd.py and test_mmtf.py are failing.

I am particularly worried about the test case in test_mmtf.py as the atom_name annotations seem to change when reading and writing a mmtf file (which is what is being tested):

Original AtomArray: ...'CE1', 'NE2', 'H', 'HA', 'HB2', 'HB3', 'HD1', 'HD2', 'HE1', 'N'...
After writing and reloading: ...'CE1', 'NE2', 'H', 'HA', 'HB2', 'HB3', 'HD2', 'HE1', 'HE2', 'N'...

The test in test_pdb.py fails because the following error is not raised:

if hybrid36 and (array1.res_id < 1).any():
            with pytest.raises(
                ValueError,
                match="Only positive integers can be converted "
                      "into hybrid-36 notation"
            ):
                pdb_file = pdb.PDBFile()
                pdb.set_structure(pdb_file, array1, hybrid36=hybrid36)

@t0mdavid-m t0mdavid-m changed the title Constistency Issues with PDB & MMTF IO for structure 5EIL Consistency Issues with PDB & MMTF IO for structure 5EIL Sep 18, 2022
padix-key added a commit to padix-key/biotite that referenced this issue Sep 18, 2022
@padix-key padix-key mentioned this issue Sep 18, 2022
padix-key added a commit that referenced this issue Sep 19, 2022
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 a pull request may close this issue.

1 participant