[BioPython] Problems building biopython-based script with py2exe

Andrew Nunberg anunberg at oriongenomics.com
Wed Feb 4 18:50:48 EST 2004


Please commit the changes ASAP,
I just updated my biopython and tried to install and got an error at line 54
in the Bio.__init__.py

Andy
-- 
Andrew Nunberg
Bioinformagician
Orion Genomics
(314)-615-6989
www.oriongenomics.com


> From: Leighton Pritchard <lpritc at scri.sari.ac.uk>
> Date: Tue, 03 Feb 2004 10:12:22 +0000
> To: Brad Chapman <chapmanb at uga.edu>, biopython at biopython.org
> Subject: Re: [BioPython] Problems building biopython-based script with py2exe
> 
> Hi Brad,
> 
> At 00:26 03/02/2004, Brad Chapman wrote:
>> Thanks for looking into this problem -- I know nothing at all about
>> py2exe and very little about the registry import magic going on
>> there. I checked your changes into Bio/__init__.py
> 
> Many thanks - my first contribution.  I'm quite chuffed with that.
> 
>> Could you please verify that I did everything right and didn't mess
>> anything up on typing it up? Ugh, all those list comprehensions and
>> import hacks and my head is a bit tired right now; so hopefully I
>> did a decent job.
> 
> Just off by a couple of typos:
> 
> line 54:
>    config_imports = __import__("Bio.config", {}, {}, ["Bio"]).__file__)
> should be (don't need __file__ attribute)
>    config_imports = __import__("Bio.config", {}, {}, ["Bio"])
> 
> line 57:
>    if hasattr(config_imports, '__loader__':
> should be (missing parenthesis):
>    if hasattr(config_imports, '__loader__'):
> 
> line 66:
>        x = os.listdir(config_imports.__file__))
> should be (os.path.dirname call):
>        x = os.listdir(os.path.dirname(config_imports.__file__))
> 
> But I can't guarantee having caught everything ;)
> 
>> Thanks again for looking into this!
>> Brad
> 
> No problem - a rationale for what's there is at the py2exe wiki:
> http://starship.python.net/crew/theller/moin.cgi/FrontPage
> 
> Cheers,
> 
> 
> Dr Leighton Pritchard AMRSC
> D104, PPI, Scottish Crop Research Institute
> Invergowrie, Dundee, DD2 5DA, Scotland, UK
> E: lpritc at scri.sari.ac.uk
> T: +44 (0)1382 568579           F: +44 (0)1382 568578
> PGP key FEFC205C: http://www.keyserver.net http://pgp.mit.edu
> 
> 
> _______________________________________________
> BioPython mailing list  -  BioPython at biopython.org
> http://biopython.org/mailman/listinfo/biopython
> 



More information about the BioPython mailing list