[Biopython-dev] Fwd: [biopython] PDBParser fails with error "AttributeError: 'NoneType' object has no attribute 'get_fullname'" (#441)

Peter Cock p.j.a.cock at googlemail.com
Thu Dec 11 14:31:05 UTC 2014


Hello to all our PDB experts,

If you didn't get this email from GitHub, could you take a look at
this bug report which has a nice clear reproducible test case?
https://github.com/biopython/biopython/issues/441

Thanks,

Peter

---------- Forwarded message ----------
From: Alexey Strokach <notifications at github.com>
Date: Wed, Dec 10, 2014 at 7:57 PM
Subject: [biopython] PDBParser fails with error "AttributeError: 'NoneType'
object has no attribute 'get_fullname'" (#441)
To: biopython/biopython <biopython at noreply.github.com>


When I try to use PDBParesr to read the pdb for 3nh3 I get an error:

AttributeError: 'NoneType' object has no attribute 'get_fullname'".

To reproduce the error:
1) download "3NH3.pdb" from
http://www.rcsb.org/pdb/explore/explore.do?structureId=3NH3
2) run the following code

from Bio.PDB import PDBParser
parser = PDBParser()
structure = parser.get_structure('3nh3', open('3NH3.pdb', 'r'))

Here is the full traceback:
Traceback (most recent call last):

  File "<ipython-input-64-c2358d7c6b4e>", line 1, in <module>
    structure = parser.get_structure('3nh3', open('3NH3.pdb', 'r'))

  File "/home/xx/anaconda/lib/python2.7/site-packages/Bio/PDB/PDBParser.py",
line 86, in get_structure
    self._parse(handle.readlines())

  File "/home/xx/anaconda/lib/python2.7/site-packages/Bio/PDB/PDBParser.py",
line 109, in _parse
    self.trailer = self._parse_coordinates(coords_trailer)

  File "/home/xx/anaconda/lib/python2.7/site-packages/Bio/PDB/PDBParser.py",
line 225, in _parse_coordinates
    fullname, serial_number, element)

  File "/home/xx/anaconda/lib/python2.7/site-packages/Bio/PDB/StructureBuilder.py",
line 187, in init_atom
    duplicate_fullname=duplicate_atom.get_fullname()

  File "/home/xx/anaconda/lib/python2.7/site-packages/Bio/PDB/Entity.py",
line 210, in __getattr__
    return getattr(self.selected_child, method)

AttributeError: 'NoneType' object has no attribute 'get_fullname'

—
Reply to this email directly or view it on GitHub
<https://github.com/biopython/biopython/issues/441>.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.open-bio.org/pipermail/biopython-dev/attachments/20141211/eb7a77bd/attachment.html>


More information about the Biopython-dev mailing list