[Biopython-dev] [Biopython (old issues only) - Bug #2949] (Resolved) _parse_pdb_header_list: REVDAT is for oldest entry.

redmine at redmine.open-bio.org redmine at redmine.open-bio.org
Sat Nov 12 22:08:30 UTC 2016


Issue #2949 has been updated by Lenna Peterson.

Description updated
Status changed from New to Resolved
% Done changed from 0 to 100

Migrated to github: https://github.com/biopython/biopython/issues/994

----------------------------------------
Bug #2949: _parse_pdb_header_list: REVDAT is for oldest entry.
https://redmine.open-bio.org/issues/2949#change-15374

* Author: Anonymous
* Status: Resolved
* Priority: Normal
* Assignee: Biopython Dev Mailing List
* Category: Main Distribution
* Target version: 1.52
* URL: 
----------------------------------------
Hi,

I don't know if this is considered a bug or a feature, but currently _parse_pdb_header_list in parse_pdb_header.py is grabbing the least recent date when I believe it should be grabbing the MOST current date.

Here is the current code:
        elif key=="REVDAT":
            rr=re.search("\d\d-\w\w\w-\d\d",tail)
            if rr!=None:
                dict['release_date']=_format_date(_nice_case(rr.group()))

And here is the fix, with additional REVDAT components added (can't hurt! :-) ):
        elif key=="REVDAT":
            #Modified by Paul T. Bathen to get most recent date instead of oldest date.
            #Also added additional dict entries
            if dict['release_date'] == "1909-01-08": #set in init
                rr=re.search("\d\d-\w\w\w-\d\d",tail)
                if rr!=None:
                    dict['release_date']=_format_date(_nice_case(rr.group()))

                dict['mod_number'] = hh[7:10].strip()
                dict['mod_id'] = hh[23:28].strip()
                dict['mod_type'] = hh[31:32].strip()

Paul



-- 
You have received this notification because you have either subscribed to it, or are involved in it.
To change your notification preferences, please click here and login: http://redmine.open-bio.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.open-bio.org/pipermail/biopython-dev/attachments/20161112/c3f00cd4/attachment.html>


More information about the Biopython-dev mailing list