[BioPython] BioEutils

Peter Wilkinson pwilkinson at videotron.ca
Wed Aug 4 13:35:26 EDT 2004


This apparently did not get to the list, I did not reply-all.

Hi Brad,

I really appreciate your efforts. And by the way I can never be 
disappointed with biopython modules that have problems, especially the ones 
you write, you are always supporting them well.  I will load the module 
from the public CVS and try again. If I come across how to escape the ":" I 
will let you know.

I have looked through the code and it looks like a massive work. I would 
like to know your approach to planning a module like this and what is the 
way in which you cycle through coding and testing?

I try to plan with  one or two diagrams (and I mean a few, as one can get 
wrapped up in making pretty pictures), then try to use more of an extreme 
programming approach (not strictly as some might want), except I am coding 
as 1. I am interesting in knowing how you plan your project before coding.

Peter


At 06:26 PM 8/3/2004, you wrote:
>Hi Peter;
>
>[Using EUtils]
> > I dont seem to be getting any of the EUtils to work.
>[...]
> > NCBI changing things around so the EUtils packages breaks?
>
>Yes, that looks to be the case. Thanks for providing the examples of
>things that weren't working. I went through and updated EUtils with
>some testing code, and think I have all your problems fixed. If you
>could update EUtils from CVS and test that would be very helpful.
>The major changes are in Bio/EUtils/ThinClient.py and
>Bio/EUtils/parse.py.
>
> > I would like to look up records for image clones like:
> >
> > clone = client.search("IMAGE:624360",db="nucleotide")
> >
> > This would be the way I look for a clone in the nucleotide set using the
> > search field on the root of the ncbi homepage.  I know that this clone is
> > in nucleotide, but this query does not work here, I get a result of length
> > = 0.
>
>The problem here is that you can't use colons within queries,
>because Entrez treats them as a range operation. There might be a
>way to escape them, but I don't know of it. The easiest way, which
>seems to work fine, is to leave out the colon in your search:
>
> >>> from Bio.EUtils import HistoryClient
> >>> client = HistoryClient.HistoryClient()
> >>> clone = client.search("IMAGE 624360",db="nucleotide")
> >>> len(clone)
>2
>
> > clone = client.search("AA759046",db="nucleotide")
> >
> > however I get the following error
> >
> > Traceback (most recent call last):
> >     raise IndexError, "no item matches"
> > IndexError: no item matches.
>
>This search is fine, but this was an internal error which is now
>fixed in the changes in CVS.
>
> > >>> result = client.search("dalke", retmax = 100)
> >
> > Traceback (most recent call last):
> >     raise TypeError("Unknown OP code: %r" % (s,))
> > TypeError: Unknown OP code: u'GROUP'
>
>This was a change in what NCBI was returning. It should now handle
>this just fine.
>
>I also fixed a few other bugs I came across in the process. Sorry
>about the problems. I appreciate you testing this, and hope the new
>code works better for you.
>
>Brad
>_______________________________________________
>BioPython mailing list  -  BioPython at biopython.org
>http://biopython.org/mailman/listinfo/biopython



More information about the BioPython mailing list