60 PerlMonks - Newest Nodes New nodes appearing on PerlMonks http://perlmonks.org/index.pl?node_id=30175 http://blogs.law.harvard.edu/tech/rss PerlMonks Newest Nodes XML Generator 961 PerlMonks 2014-07-29 22:24:10 rss,clean Tue Jul 29 12:24:10 2014 30 20140729122410 Tue Jul 29 12:24:10 2014 http://perlmonks.org/ Anonymous Monk Including modules and pragmas in caller's scope via use wanna_code_perl http://perlmonks.org/index.pl?node_id=1095522 Hello monks, I already have several Local::... modules that do things too specific for general public consumption. Now I have a "smaller" problem: Like many programmers, ... perlquestion Tue, 29 Jul 2014 20:49:58 +0000 http://perlmonks.org/index.pl?node_id=1095522 1095522 688543 2014-07-29 16:49:58 wanna_code_perl LWP::UserAgent error Unexpected keys - LocalHost Anonymous Monk http://perlmonks.org/index.pl?node_id=1095520 Hi All I tried to grab a page using this code on my Mint10 PC. For some reason it chokes. I tried the same on another Mint17 PC connected through the same network and it worked. But I don't unde... perlquestion Tue, 29 Jul 2014 20:22:38 +0000 http://perlmonks.org/index.pl?node_id=1095520 1095520 961 2014-07-29 16:22:38 Anonymous Monk using the feature 'switch' in loops martell http://perlmonks.org/index.pl?node_id=1095514 Hi Monks I was wondering for thoughts from you about the new 'switch' feature in combination with loop control statements like 'last' and 'next'. When I first used the 'switch' ... perlquestion Tue, 29 Jul 2014 19:13:22 +0000 http://perlmonks.org/index.pl?node_id=1095514 1095514 314918 2014-07-29 15:13:22 martell Naming a module that handles SIP2 gmcharlt http://perlmonks.org/index.pl?node_id=1095504 I'm one of the folks who hacks on a set if modules that handles a protocol used by libraries called SIP2 (not to be confused with the telephony protocol). The modules uses Net::Server. Curre... perlquestion Tue, 29 Jul 2014 16:39:32 +0000 http://perlmonks.org/index.pl?node_id=1095504 1095504 686619 2014-07-29 12:39:32 gmcharlt Re^2: LWP::UserAgent error Unexpected keys - LocalHost trendle http://perlmonks.org/index.pl?node_id=1095526 Hi, sorry to say, but Mechanize uses LWP::UserAgent under the bonnet as far as I can gather. So the net result remains the same. use WWW::Mechanize; my $mech = WWW::Mechanize->new( a... note Tue, 29 Jul 2014 22:18:25 +0000 http://perlmonks.org/index.pl?node_id=1095526 1095526 910291 2014-07-29 18:18:25 trendle Re: Including modules and pragmas in caller's scope via use Anonymous Monk http://perlmonks.org/index.pl?node_id=1095525 Import::Into seems to do what you want.... note Tue, 29 Jul 2014 22:15:02 +0000 http://perlmonks.org/index.pl?node_id=1095525 1095525 961 2014-07-29 18:15:02 Anonymous Monk Re: LWP::UserAgent error Unexpected keys - LocalHost Anonymous Monk http://perlmonks.org/index.pl?node_id=1095521 Just say not to typing effort <a href="http://www.perlmeme.org/tutorials/lwp.html">http://www.perlmeme.org/tutorials/lwp.html</a> use <a href="https://metacpan.org/module/WWW%3A%3AMechanize">WWW::Mechanize</a>, its everything you wanted LWP to be Same program with less typing ... note Tue, 29 Jul 2014 20:34:27 +0000 http://perlmonks.org/index.pl?node_id=1095521 1095521 961 2014-07-29 16:34:27 Anonymous Monk Re^2: Naming a module that handles SIP2 (library protocol stopwords) Anonymous Monk http://perlmonks.org/index.pl?node_id=1095519 Perhaps Library::Protocol::SIP2 or Protocol::SIP2 would be appropriate? Um, no, Library and Protocol are stopwords :) esp for top level namespaces, see &#91;href://http://pause.perl.org/p... note Tue, 29 Jul 2014 19:48:40 +0000 http://perlmonks.org/index.pl?node_id=1095519 1095519 961 2014-07-29 15:48:40 Anonymous Monk Re^3: IO::Socket::SSL & Net::Websocket::Server Question noxxi http://perlmonks.org/index.pl?node_id=1095518 Symbol::gensym() which is used here just uses a global counter to make sure to never create the same symbol twice. So even if the previous symbols are no longer valid it will not reset the counter. No... note Tue, 29 Jul 2014 19:45:59 +0000 http://perlmonks.org/index.pl?node_id=1095518 1095518 1069398 2014-07-29 15:45:59 noxxi Re: using the feature 'switch' in loops Anonymous Monk http://perlmonks.org/index.pl?node_id=1095517 In your example, the last breaks out of the inner for ($a), like it's supposed to. If you use <a href="http://perldoc.perl.org/functions/given.html">given</a> (which is actually the "switch" statement, not <a href="http://perldoc.perl.org/for.html">for</a>, even tho... note Tue, 29 Jul 2014 19:37:14 +0000 http://perlmonks.org/index.pl?node_id=1095517 1095517 961 2014-07-29 15:37:14 Anonymous Monk Re: using the feature 'switch' in loops Anonymous Monk http://perlmonks.org/index.pl?node_id=1095516 But did you expected this behaviour when you used this feature for the first time? Long time ago, when switch was first introduced, I decided never to bother with it :) I don't have exp... note Tue, 29 Jul 2014 19:34:53 +0000 http://perlmonks.org/index.pl?node_id=1095516 1095516 961 2014-07-29 15:34:53 Anonymous Monk Re^2: Naming a module that handles SIP2 jhourcle http://perlmonks.org/index.pl?node_id=1095515 The library community has been a habit of putting modules in <a href="http://search.cpan.org/search?mode=module&amp;query=Biblio">Biblio</a> rather than 'Library', to deal with the ambiguity of that term. The ... note Tue, 29 Jul 2014 19:17:22 +0000 http://perlmonks.org/index.pl?node_id=1095515 1095515 373533 2014-07-29 15:17:22 jhourcle Re^2: Would you work at a porn company? Anonymous Monk http://perlmonks.org/index.pl?node_id=1095513 yes i would take job ... note Tue, 29 Jul 2014 18:32:50 +0000 http://perlmonks.org/index.pl?node_id=1095513 1095513 961 2014-07-29 14:32:50 Anonymous Monk Re^2: IO::Socket::SSL & Net::Websocket::Server Question huchister http://perlmonks.org/index.pl?node_id=1095512 Thanks. I was bit worried whether my script takes up unnecessary variable or eat up any memory cause of this. ... note Tue, 29 Jul 2014 18:19:53 +0000 http://perlmonks.org/index.pl?node_id=1095512 1095512 994332 2014-07-29 14:19:53 huchister Re^2: IO::Socket::SSL & Net::Websocket::Server Question Anonymous Monk http://perlmonks.org/index.pl?node_id=1095511 But the globs numbers still wont be reset to 0, as you saw :) ... note Tue, 29 Jul 2014 17:50:45 +0000 http://perlmonks.org/index.pl?node_id=1095511 1095511 961 2014-07-29 13:50:45 Anonymous Monk Re: IO::Socket::SSL & Net::Websocket::Server Question zentara http://perlmonks.org/index.pl?node_id=1095510 I'm not sure it will work in your case, but have you tried to clean out the IO::Socket::SSL object? From "perldoc -q clear": Specifically look at the Symbol::delete_package() function . ... note Tue, 29 Jul 2014 17:47:15 +0000 http://perlmonks.org/index.pl?node_id=1095510 1095510 131741 2014-07-29 13:47:15 zentara Re: IO::Socket::SSL & Net::Websocket::Server Question Anonymous Monk http://perlmonks.org/index.pl?node_id=1095509 I don't think it's a problem. perl -MSymbol -MData::Dumper -wE ' {my $x=gensym; print Dumper $x}; {my $y=gensym; print Dumper $y}; my $z=gensym; print Dumper $z; print $x, $y' O... note Tue, 29 Jul 2014 17:29:16 +0000 http://perlmonks.org/index.pl?node_id=1095509 1095509 961 2014-07-29 13:29:16 Anonymous Monk Re: Naming a module that handles SIP2 RonW http://perlmonks.org/index.pl?node_id=1095508 Since this SIP2 has nothing to do with the more commonly known SIP, maybe Net::Protocol::SIP2_3M::Server Note that all parts of a package name must be valid Perl identifiers. 3MSI... note Tue, 29 Jul 2014 17:01:05 +0000 http://perlmonks.org/index.pl?node_id=1095508 1095508 1080444 2014-07-29 13:01:05 RonW Re^2: Question about a perl script AppleFritter http://perlmonks.org/index.pl?node_id=1095507 Howdy Aspec, here's some links that might be useful for getting started with Perl: Introductions, first steps and general information: The <a href="http://perldoc.perl.org/perlintro.html">perlintro</a> manpage ... note Tue, 29 Jul 2014 16:58:36 +0000 http://perlmonks.org/index.pl?node_id=1095507 1095507 1084031 2014-07-29 12:58:36 AppleFritter Re: Naming a module that handles SIP2 AppleFritter http://perlmonks.org/index.pl?node_id=1095506 Keep in mind that this is just my opinion and that I've got literally zero experience with naming CPAN modules... First of all, I'd advise "Net::3MSIP2::Server". It doesn't roll of the ... note Tue, 29 Jul 2014 16:51:09 +0000 http://perlmonks.org/index.pl?node_id=1095506 1095506 1084031 2014-07-29 12:51:09 AppleFritter Re: Naming a module that handles SIP2 MidLifeXis http://perlmonks.org/index.pl?node_id=1095505 Perhaps LibraryBiblio::Protocol::SIP2 or Protocol::SIP2 would be appropriate? You may also want to ask on <a href="http://prepan.org">PrePAN</a>. Update: s/Librar... note Tue, 29 Jul 2014 16:43:38 +0000 http://perlmonks.org/index.pl?node_id=1095505 1095505 272364 2014-07-29 12:43:38 MidLifeXis Re: My favorite superfluous repetitious redundant duplicative phrase is: chacham http://perlmonks.org/index.pl?node_id=1095503 Wow, just caught myself trying to type <a href="http://en.wikipedia.org/wiki/Special:Search?search=Multiple_document_interface">MDI</a> interface.... note Tue, 29 Jul 2014 16:28:51 +0000 http://perlmonks.org/index.pl?node_id=1095503 1095503 934209 2014-07-29 12:28:51 chacham q5p4k0 q5p4k0 http://perlmonks.org/index.pl?node_id=1095523 user Tue, 29 Jul 2014 21:18:37 +0000 http://perlmonks.org/index.pl?node_id=1095523 1095523 1095523 2014-07-29 17:18:37 q5p4k0