[32636] in Perl-Users-Digest
Perl-Users Digest, Issue: 3912 Volume: 11
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sun Mar 31 03:09:25 2013
Date: Sun, 31 Mar 2013 00:09:05 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Sun, 31 Mar 2013 Volume: 11 Number: 3912
Today's topics:
Re: "if" as modifier causes incorrect tainted messages? bwooster47@gmail.com
[OT] reporting bugs <oneingray@gmail.com>
How do i resolve this error message Please! I need help <marion.adebiyi@covenantuniversity.edu.ng>
Re: How do i resolve this error message Please! I need <news@lawshouse.org>
Re: Text::BibTeX -- bibgrep-like script? <nospam@lisse.NA>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 29 Mar 2013 18:02:16 -0700 (PDT)
From: bwooster47@gmail.com
Subject: Re: "if" as modifier causes incorrect tainted messages?
Message-Id: <2f3d59c4-8f38-4642-9834-b67398115039@googlegroups.com>
On Thursday, 28 March 2013 18:37:17 UTC-4, Ben Morrow wrote:
> whole expression is considered tainted (to avoid having to make taint
> checks for every operator) so the eval (in my case) is disallowed. See
> https://rt.perl.org/rt3/Public/Bug/Display.html?id=3D17867 .
> Ben
Thanks, in case anyone from http://perldoc.perl.org/perlsec.html is reading=
, would be nice if that page explicitly had this particular example.
I should show that if modifier maintains untainted-ness, while an if-statem=
ent is fine.
That doc does mention that the phrase you mention above, but it also says t=
hat ternary operation ?: works differently: "Since code with a ternary cond=
itional... is essentially an if-statement". From that, some people might ma=
ke the incorrect jump that and if-modifier is also essentially an if-statem=
ent so that should be fine too! But it isn't...
------------------------------
Date: Sat, 30 Mar 2013 11:02:41 +0000
From: Ivan Shmakov <oneingray@gmail.com>
Subject: [OT] reporting bugs
Message-Id: <87d2uh40by.fsf_-_@violet.siamics.net>
>>>>> Ben Morrow <ben@morrow.me.uk> writes:
>>>>> Quoth Ivan Shmakov <oneingray@gmail.com>:
>>>>> Ben Morrow <ben@morrow.me.uk> writes:
(Thanks for the comments regarding ZBar, BTW. I'm yet to check
its sources myself, but I've also discovered that it behaves
strangely not only for the octets having the most significant
bit set, but for the "plain old" \x0D = \r just as well.)
[...]
>>> There is a Perl decoder based on zbar (Barcode::ZBar), though
>>> presumably it would behave the same as zbarimg.
>> ... Indeed it does, which made me file Debian Bug#703234 [1].
> <pet peeve> The correct place to file a bug in a Perl module is in
> its CPAN bug tracker, or, in this case, in the zbar Sourceforce
> tracker.
BTW, there's a longstanding bug filed at the CPAN RT [2] (along
with a patch.) However, it appears to be filed against
libwww-perl, while it actually belongs to Net-HTTP.
The question is: how do I reassign it?
[2] https://rt.cpan.org/Public/Bug/Display.html?id=29468
> Filing a bug with some random distro is Not Helpful, since such
> reports frequently don't find their way upstream.
Yes. As long as an ideal world is considered, that is.
There're a few things to note, however. The general problems
with upstream may include:
* there's effectively no upstream;
* the code in the distribution may be extensively modified, or
improperly built, or be alleged to be; the upstream then may
discourage the users of "non-authorized" builds to report bugs
directly to them; consider, e. g.:
--cut: http://foo2zjs.rkkda.com/ --
*** DON'T USE the foo2zjs package from:
Ubuntu, SUSE, Mandrake/Manrivia, Debian, RedHat, Fedora, Gentoo,
Xandros, EEE PC, Linpus, MacOSX, or BSD!
*** Download it here and follow the directions below.
--cut: http://foo2zjs.rkkda.com/ --
(or the Joerg Schilling, albeit sufficiently different, case);
* the issue may indeed be specific to the distribution's build;
(naturally, building from the upstream sources for every bug
being I report just to check that it wasn't introduced by the
packagers is hardly an option.)
Personally, I tend to prefer either the Debian BTS, or the
CPAN RT, for these make it possible to file bugs via email,
/and/ are better compatible with Lynx (which happens to be my
primary browser) than most of the other BTS currently in use.
(I'm particularly fond of RT, although the version installed at
CPAN has certain surprising issue when it comes to the
compatibility with non-ECMAScript-enabled browsers.)
Alas, even for the Perl modules, the CPAN RT is not always the
preferred but tracker. Consider, e. g.:
--cut: https://rt.cpan.org/Public/Bug/Display.html?id=79999 --
Please report issues via github at
https://github.com/gbarr/perl-Convert-ASN1/issues
--cut: https://rt.cpan.org/Public/Bug/Display.html?id=79999 --
Lastly, given the developer- and user-base of Debian (especially
if the derivatives are included), I'd not call it "random."
That being said, I tend to agree that when the D-M in charge
fails to forward the request to the upstream, the reporter
generally should try to do it him- or herself.
(OTOH, even if D-M forwards the request, it may not have the
desired effect. Consider, e. g., Debian Bug#691221 [3].)
[3] http://bugs.debian.org/691221
[...]
--
FSF associate member #7257 http://hfday.org/
------------------------------
Date: Sat, 30 Mar 2013 00:33:06 -0700 (PDT)
From: Adebiyi Marion <marion.adebiyi@covenantuniversity.edu.ng>
Subject: How do i resolve this error message Please! I need help
Message-Id: <bcc53886-2b5f-4cd7-88d6-6708de9b8ceb@googlegroups.com>
the error message is;
Can't modify concatenation (.) or string in scalar assignment at theScript.pl line 67, near ");"
theScript is as below;
use strict;
my $file = shift @ARGV;
open(FILE, "$file") or die "Cannot open file: $!";
while(<FILE>)
{
chomp;
my $gene = $_;
system("wget -O " . $gene . ".fasta
\"http://www.uniprot.org/uniprot/?query=gene%3a" . $gene .
"&format=fasta\"");
open(FASTA, $gene . ".fasta") or die "Cannot open FASTA file
$gene: $!";
my $sequence;
while(<FASTA>)
{
chomp;
$sequence .= $_ unless /^>/;
}
close FASTA;
system("wget -O " . $gene . ".out
\"http://web.expasy.org/cgi-bin/blast/blast.pl?sequence=\"" . $sequence
. "\"&action=PlainText&protdb_section=HUMAN&showsc=3&showal=0\"");
open(BLAST, $gene . ".out") or die "Cannot open BLAST file
$gene: $!";
my $idMapping;
while(<BLAST>)
{
if (/^(sp|tr)\!([A-Z\d]+)/)
{
$idMapping .= $2 . " ";
}
}
close BLAST;
if ($idMapping)
{
open(OUT, ">$gene.up2ensembl") or die "Cannot open OUT
for writing: $!";
print OUT &getIdMappingResult($idMapping);
}
}
close FILE;
sub getIdMappingResult
{
my ($list) = (@_);
my $base = 'http://www.uniprot.org';
my $tool = 'mapping';
my $params = {
from => 'ACC',
to => 'ENSEMBL_ID',
format => 'tab',
query => $list
};
my $contact = 'onlimarion@yahoo.com'; # Please set your email address here to help
us debug in case of problems.
my $agent = LWP::UserAgent->new(agent => "libwww-perl $contact");
push @{$agent->requests_redirectable}, 'POST';
my $response = $agent->post("$base/$tool/", $params);
while (my $wait = $response->header('Retry-After')) {
print STDERR "Waiting ($wait) ; Query: $base/$tool/ ;
Parameters: ...\n";
sleep $wait;
$response = $agent->get($response->base);
}
$response->is_success ?
return $response->content :
die 'Failed, got ' . $response->status_line . ' for ' .
$response->request->uri . "\n";
}
My list can be attached asap if need be.
Marion
------------------------------
Date: Sat, 30 Mar 2013 10:09:33 +0000
From: Henry Law <news@lawshouse.org>
Subject: Re: How do i resolve this error message Please! I need help
Message-Id: <94adnaUp-tZAJMvMnZ2dnUVZ7oudnZ2d@giganews.com>
On 30/03/13 07:33, Adebiyi Marion wrote:
> the error message is;
> Can't modify concatenation (.) or string in scalar assignment at theScript.pl line 67, near ");"
Line 67 in that program doesn't contain a concatenation; nor does any
line close by. (I copied it into an editor and displayed line 67).
Try commenting out big sections of the program (hint: use =pod and =cut,
rather than converting to comments) and re-running it until the error
goes away; then the last bit you commented out contains the problem.
Then if you can't fix the problem yourself, post *just* the little bit
that gives the error message _as a program anyone can run_ and we'll try
to help.
--
Henry Law Manchester, England
------------------------------
Date: Sat, 30 Mar 2013 15:34:57 +0200
From: Dr Eberhard Lisse <nospam@lisse.NA>
Subject: Re: Text::BibTeX -- bibgrep-like script?
Message-Id: <5156EA01.70704@lisse.NA>
Rainer,
thank you so much for your enlightening comment.
I use BibDesk on the Mac and thus have not much experience with
JabRef itself but http://jabref.sourceforge.net/help/SQLExport.php
shows you what I mean.
el
On 2013-03-29 15:58 , Rainer Weikusat wrote:
> Dr Eberhard Lisse <nospam@lisse.NA> writes:
>> Can't you load them into SQL with jabRef and then look them up
>> quickly?
>
> FYI/ JFTR: 'SQL' is a query language used by so-called 'relational database
> management systems' (depending on whom you ask, it either means
> 'structured query language' or is an abbreviation of the original
> [IBM] name sequel).
>
--
if you want to reply, replace nospam with my initials
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>
Administrivia:
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
Back issues are available via anonymous ftp from
ftp://cil-www.oce.orst.edu/pub/perl/old-digests.
#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V11 Issue 3912
***************************************