Electrostatics / pdb2pqr

PDB2PQR - determining titration states, adding missing atoms, and assigning charges/radii to biomolecules.
http://www.poissonboltzmann.org/
Other
117 stars 34 forks source link

format problems #331

Open pineappleXmen opened 1 year ago

pineappleXmen commented 1 year ago

Hello dear user when I use --keep-chain option it will add chain id to the final pqr file and if the chain id is bigger than 1000,there is no space between the chain id and the Residue_number so when I invoke the pdb2pqr.io.read_pqr() function it raise a ValueError hope to solve this problem

pineappleXmen commented 1 year ago

I check the source code that caused by the atom class from_pqr_line(cls, line) function try: atom.res_seq = int(token) except ValueError: atom.chain_id = token atom.res_seq = int(words.pop(0))

this should check the [words] list length before pop up if the length is 6 the chain_id should be the pop up one [0] and residue number should be the res else the length is 7 do as normal