[Bioperl-l] StandAloneBlast.pm,
bl2seq() and tempfiles on Win32/cygwin
Aaron J. Mackey
amackey at pcbi.upenn.edu
Tue Feb 24 11:19:34 EST 2004
It's not StandALoneBlast's fault: it's using Bio::Root::IO::tempfile()
which uses some convoluted logic that I can't follow (and, if I
remember right, is a copy of an older File::Temp incarnation).
So, folks, how can we best inform BioPerl where we want it to make
temporary files?
-Aaron
On Feb 24, 2004, at 11:11 AM, Brian Osborne wrote:
> Aaron,
>
> That could work. Unfortunately that would mess up the path for those
> applications that DO use Unix-style paths.
>
> Well, hold on, let me try....
>
> No, neither worked:
>
> MSG: Could not open /tmp/Av0MhgqzIJ: No such file or directory
>
> StandAloneBlast seems not to care about either env's. That's not nice.
>
>
> Brian O.
>
> -----Original Message-----
> From: Aaron J. Mackey [mailto:amackey at pcbi.upenn.edu]
> Sent: Tuesday, February 24, 2004 10:58 AM
> To: Brian Osborne
> Subject: Re: [Bioperl-l] StandAloneBlast.pm, bl2seq() and tempfiles on
> Win32/cygwin
>
> Ahh, right; perhaps the $TEMPDIR (or $TEMP?) environment variable would
> do the trick?
>
> -Aaron
>
> On Feb 24, 2004, at 10:46 AM, Brian Osborne wrote:
>
>> Aaron,
>>
>> Or ask the author for a way to set the tempdir, in my case it would be
>> "e:/cygwin/tmp". I couldn't see such a thing in the documentation,
>> perhaps I
>> missed it though.
>>
>> BIO
>>
>> -----Original Message-----
>> From: Aaron J. Mackey [mailto:amackey at pcbi.upenn.edu]
>> Sent: Tuesday, February 24, 2004 10:32 AM
>> To: Brian Osborne
>> Subject: Re: [Bioperl-l] StandAloneBlast.pm, bl2seq() and tempfiles on
>> Win32/cygwin
>>
>> Ooo, that's probably it; what's the solution?
>>
>> -Aaron
>>
>> On Feb 24, 2004, at 10:22 AM, Brian Osborne wrote:
>>
>>> Aaron,
>>>
>>> Because he's using the BLAST Win binaries which don't understand
>>> Cygwin
>>> paths?
>>>
>>> Meaning these work:
>>>
>>> blastall -i test.fa -d testdb.fa -p blastn
>>>
>>> blastall -i e:/cygwin/home/bosborne/test.fa -d test.fa -p blastn
>>>
>>>
>>> But this doesn't:
>>>
>>> blastall -i /home/bosborne/test.fa -d test.fa -p blastn
>>>
>>> ?
>>>
>>>
>>> Brian O.
>>>
>>> -----Original Message-----
>>> From: bioperl-l-bounces at portal.open-bio.org
>>> [mailto:bioperl-l-bounces at portal.open-bio.org]On Behalf Of Aaron J.
>>> Mackey
>>> Sent: Monday, February 23, 2004 4:11 PM
>>> To: Bioperl list
>>> Cc: Sushma Parankush Das
>>> Subject: [Bioperl-l] StandAloneBlast.pm,bl2seq() and tempfiles on
>>> Win32/cygwin
>>>
>>>
>>> A colleague of mine is frustrated by attempting to use
>>> Bio::Tools::Run::StandAloneBlast to run bl2seq (Perl 5.8.2, bioperl
>>> 1.4, windows XP, CygWin, etc.):
>>>
>>> # synopsis:
>>> $seq1 = $seqio->next_seq;
>>> $seq2 = $seqio->next_seq;
>>> $factory->bl2seq($seq1, $seq2);
>>>
>>> StandAloneBlast successfully writes two temp files in /tmp, which
>>> have
>>> the sequence data and can be read by "less" or "cat" in another open
>>> window (with the main program suspended in debugger); however, if
>>> either the program code or I at the command line attempt to run
>>> bl2seq,
>>> it dies with "Cannot open file /tmp/7aasd78asd". If I "cp" the temp
>>> files into new files, it runs fine. Or, if I call
>>> $factory->bl2seq($file1, $file2) with filenames instead of seq
>>> objects,
>>> it also works fine. I have tried various incarnations of closing the
>>> filehandles and Bio::SeqIO objects that StandAloneBlast.pm is using
>>> to
>>> generate these temp files, but to no avail (and of course, the
>>> tempfiles disappear upon program completion).
>>>
>>> This is not the "failed to open tempfile; too many files open" error
>>> seen previously, and I also expect a fair number of "works for me"
>>> responses - please save your breath.
>>>
>>> Thanks for any input,
>>>
>>> -Aaron
>>>
>>> _______________________________________________
>>> Bioperl-l mailing list
>>> Bioperl-l at portal.open-bio.org
>>> http://portal.open-bio.org/mailman/listinfo/bioperl-l
>>>
>>>
>>> _______________________________________________
>>> Bioperl-l mailing list
>>> Bioperl-l at portal.open-bio.org
>>> http://portal.open-bio.org/mailman/listinfo/bioperl-l
>>>
>>
>
More information about the Bioperl-l
mailing list