[BioPython] blastall produces a black console screen with biopython 1.49 and up‏

Stefanie Lück lueck at ipk-gatersleben.de
Mon Apr 20 11:07:20 UTC 2009


Hi!

How does your py2exe setup.py file looks?

from distutils.core import setup
import py2exe

#python setup.py py2exe

setup(
    windows = [
        {
            "script": "nb_psst.py",                    ### Main Python 
script
            "icon_resources": [(0, "Icon.ico")]     ### Icon to embed into 
the PE file.
        }
    ],
)

If you use console instead of windows in setup() will the black screen 
dissapear?

Kind regards
Stefanie


----- Original Message ----- 
From: "Peter" <biopython at maubp.freeserve.co.uk>
To: "Joaquin Abian Monux" <gatoygata at hotmail.com>; "BioPython Mailing List" 
<biopython at lists.open-bio.org>
Sent: Friday, April 17, 2009 5:38 PM
Subject: Re: [BioPython]blastall produces a black console screen with 
biopython 1.49 and up‏


On Fri, Apr 17, 2009 at 4:24 PM, Joaquin Abian Monux
<gatoygata at hotmail.com> wrote:
> Dear Peter,
>
> Thanks, I fixed it. I'm not sure how.
>
> In:
>
> blast_process = subprocess.Popen(cmd_string,
> stdout=subprocess.PIPE,
> stderr=subprocess.PIPE,
> stdin=subprocess.PIPE,
> shell= (sys.platform!="win32"))
>
> (sys.platform!="win32") is False for my winXP computer. But if I set the
> parameter shell=True, then the problem disappears, either in the py2exe
> executables and in the scripts. Everything works perfect as usual.
>
> if shell=True in windows the shell used is the one set in COMSPEC. In my
> case it is the normal windows shell (cmd.exe). If shell=False I am not 
> sure
> what happens in windows. Obviously no cmd shell should be 
> expected...still,
> blast.exe opens his.
> ...
> Done! (Although it would be nice someone could explain why the 'shell'
> parameter must be 'True' for the program to behave properly)...

>From memory, with subprocess using the shell argument in this way was
deliberate on to get things to work cross platform.  I looks like when
running from the command line you need the *opposite* shell setting to
running from py2exe.

Could you put together a trivial python GUI application that calls
BLAST that we could use for testing?

Peter

_______________________________________________
Biopython mailing list  -  Biopython at lists.open-bio.org
http://lists.open-bio.org/mailman/listinfo/biopython




More information about the Biopython mailing list