[Bioperl-l] undef SeqFeature tag values
Nathan S. Haigh
n.haigh at sheffield.ac.uk
Sat Aug 25 07:50:29 UTC 2007
This sort of highlights a comment I made previously about how do you
test for a stable API?
It seems to me that unless you have intricate knowledge about the
changes that took place, you will find it difficult to know when an API
change has occurred. Is it possible to run the 1.4 test suite against
existing code to ensure tests pass? What if the 1.4 tests contained
bugs? This approach would need good code coverage by the tests to ensure
things work the same i.e. test code in HEAD against the test suite from
the previous stable release's branch - would/should this work
conceptually?**
Nath
Hilmar Lapp wrote:
> You're supposed to call has_tag() first before you can assume that
> you can call get_tag_values() w/o an exception. That was the original
> API.
>
> -hilmar
>
> On Aug 24, 2007, at 6:36 PM, Chris Fields wrote:
>
>
>> One thing I am noticing with the rollback to tag as strings is that
>> tags with an undefined value are not set; I'm assuming when tags were
>> Bio::AnnotationI they were instantiated regardless with an undef
>> value. When attempting to call an undef tag with get_tag_values() I
>> get:
>>
>> ------------- EXCEPTION: Bio::Root::Exception -------------
>> MSG: asking for tag value that does not exist signalPeptideLength
>> STACK: Error::throw
>> STACK: Bio::Root::Root::throw /Users/cjfields/src/featann_rollback/
>> bioperl-live/blib/lib/Bio/Root/Root.pm:357
>> STACK: Bio::SeqFeature::Generic::get_tag_values /Users/cjfields/src/
>> featann_rollback/bioperl-live/blib/lib/Bio/SeqFeature/Generic.pm:499
>> STACK: t/targetp.t:189
>> -----------------------------------------------------------
>>
>> I personally think of this as a feature (why set a tag at all if it
>> is undef?). However, are there any circumstances where we might want
>> this behavior? Do we want to simply return w/o a value if a tag name
>> isn't found (i.e. remove the exception)?
>>
>> chris
>>
>> _______________________________________________
>> Bioperl-l mailing list
>> Bioperl-l at lists.open-bio.org
>> http://lists.open-bio.org/mailman/listinfo/bioperl-l
>>
>
>
More information about the Bioperl-l
mailing list