[Biopython-dev] [Bug 2833] Features insertion on previous bioentry_id

Hilmar Lapp hlapp at gmx.net
Tue Jun 9 22:23:53 UTC 2009


I actually don't think it mimics BioPerl. The recommended practice  
should be that if you don't have a value for an optional attribute,  
leave it undefined ...

On Jun 3, 2009, at 10:52 AM, Cymon Cox wrote:

> 2009/6/3 Peter <biopython at maubp.freeserve.co.uk>
>
>> On Tue, Jun 2, 2009 at 9:29 PM, Cymon Cox <cy at cymon.org> wrote:
>>>
>>> Whoa, I see now that in Loader._load_bioentry_table that if the
>>> rec.annotations["gi"] is missing, it gets filled with the
>> accession.version:
>>>
>>>       if "gi" in record.annotations :
>>>           identifier = record.annotations["gi"]
>>>       else :
>>>           identifier = record.id
>>>
>>> So biopythons BioSQL identifiers are not equivalent to GenBank
>> identifiers.
>>> I wonder why this is done and identifier is not just left NULL,  
>>> and the
>>> unique constraint maintained by accession/version...
>>>
>>
>> Remember, it isn't just GenBank files that get imported into BioSQL.
>> While the record.id is the accession.version when loading a GenBank
>> file, this is not the case in general.
>>
>> Consulting the CVS log, this was changed BioSQL/Loader/py revision
>> 1.33 to cope with loading a FASTA file into a BioSQL database (Bug
>> 2425). Presumably I was trying to mimic the BioPerl loading of FASTA
>> files. Before this change, the bioentry.identifier was taken as the  
>> GI
>> number if available.
>>
>> i.e. This change wasn't anything directly to do with the uniqueness  
>> rules.
>
>
> Thanks Peter.
>
> Yes, it seems to have been done to mimic BioPerl - but I'm still  
> curious as
> to why it is done at all...
>
> Anyway, I seem to be chasing my tail here:
> http://bugzilla.open-bio.org/show_bug.cgi?id=2681#c5
>
> Cheers, C.
> --
> _______________________________________________
> Biopython-dev mailing list
> Biopython-dev at lists.open-bio.org
> http://lists.open-bio.org/mailman/listinfo/biopython-dev

-- 
===========================================================
: Hilmar Lapp  -:-  Durham, NC  -:-  hlapp at gmx dot net :
===========================================================






More information about the Biopython-dev mailing list