From linux at alteeve.com Tue May 6 05:53:13 2008 From: linux at alteeve.com (Madison Kelly) Date: Tue, 06 May 2008 08:53:13 -0400 Subject: [tpm] event loop Message-ID: <482054B9.1070104@alteeve.com> Hi all, I am looking for a good starting point to learn about event loops. I've written a simple server and client program, but it's not very smart or intelligent. I've since been learning about Net::DBus and I love how it's reactor loop works, and would like to create something similar for my program. Specifically, I want to have the server program have an event loop that triggers when a remote client connects, disconnects or sends data. Any tips on where I might start looking? Thanks, as always! Madi From rdice at pobox.com Tue May 6 06:37:39 2008 From: rdice at pobox.com (Richard Dice) Date: Tue, 6 May 2008 09:37:39 -0400 Subject: [tpm] event loop In-Reply-To: <482054B9.1070104@alteeve.com> References: <482054B9.1070104@alteeve.com> Message-ID: <5bef4baf0805060637j6218339drbcc67b961c23330a@mail.gmail.com> http://search.cpan.org/~rcaputo/POE-1.0001/lib/POE.pm This might be too all-singing, all-dancing for your tastes and/or needs, but man, does this ever look like fun. Cheers, - Richard On Tue, May 6, 2008 at 8:53 AM, Madison Kelly wrote: > Hi all, > > I am looking for a good starting point to learn about event loops. > I've written a simple server and client program, but it's not very smart > or intelligent. I've since been learning about Net::DBus and I love how > it's reactor loop works, and would like to create something similar for > my program. > > Specifically, I want to have the server program have an event loop > that triggers when a remote client connects, disconnects or sends data. > Any tips on where I might start looking? > > Thanks, as always! > > Madi > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080506/07b3b037/attachment.html From arocker at vex.net Tue May 6 07:43:03 2008 From: arocker at vex.net (arocker at vex.net) Date: Tue, 6 May 2008 10:43:03 -0400 (EDT) Subject: [tpm] event loop In-Reply-To: <5bef4baf0805060637j6218339drbcc67b961c23330a@mail.gmail.com> References: <482054B9.1070104@alteeve.com> <5bef4baf0805060637j6218339drbcc67b961c23330a@mail.gmail.com> Message-ID: <39918.199.43.183.133.1210084983.squirrel@webmail.vex.net> > http://search.cpan.org/~rcaputo/POE-1.0001/lib/POE.pm > > This might be too all-singing, all-dancing for your tastes and/or needs, > but man, does this ever look like fun. It had to happen. Somebody's written an OS in Perl. From carmenc1 at staffingsuccess.com Thu May 8 11:37:02 2008 From: carmenc1 at staffingsuccess.com (Carmen Cholette) Date: Thu, 8 May 2008 14:37:02 -0400 Subject: [tpm] Question from recruiter Message-ID: <006a01c8b13a$81ee8090$b000a8c0@owner81d846bef> We have a full time opportunity below. The salary range is 70-80K and it is downtown. Carmen TITLE - UNIX/PERL Developer > > ---------------------------------- > > Seeking a motivated candidate to maintain and support the most critical > aspects of our prime brokerage back end systems. The candidate should be > a fluid and quick problem solver and perform well with some levels of > pressure. > > > > The ideal candidate should also have experience supporting, maintaining > and developing daily batch jobs, data feeds and must have previously > worked with critical financial systems. > > > > Required Skills > > ----------------- > > *Expert Knowledge in Perl and Shell scripting > > *Expert Knowledge in working with Unix (HP and Solaris) environment > *Expert knowledge working with database including > > - Creating tables, indexes, triggers > > - Creating and debugging the stored procedures > > *Excellent problem solving skills and communication skills *Experience > handling external data feeds, batch processing, file uploads > > > > Nice to have Skills > > ------------------- > > *Prior experience in Java, J2EE > > *Prior experience in C++ > > *Prior experience in migrating system from one flavor of UNIX > environment to another *Prior experience working with third party > financial data providers *Prior experience working as support staff > *Solaris System Admin Certification, Linux Red Hat Certification or DBA > Certifications are preferred. > > > > > > Carmen Cholette Senior Recruiter Compu-Source Staffing Inc. 2200 Yonge St, Suite 1004 416-482-4009 ext 227 1-877-213-3301 ext 227 -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080508/f81c5c84/attachment.html From arocker at vex.net Fri May 9 07:51:50 2008 From: arocker at vex.net (arocker at vex.net) Date: Fri, 9 May 2008 10:51:50 -0400 (EDT) Subject: [tpm] Forthcoming attractions for the rest of the year Message-ID: <18049.199.43.183.133.1210344710.squirrel@webmail.vex.net> This month, (May), we have Adam Prime booked. Next month, (June), will somebody volunteer to debrief on YAPC, for we little piggies who have to stay home? September is traditionally "Lightning Talks". December is given over to Saturnalian revels. That leaves July, August, October, and November to fill. Any volunteers? From linux at alteeve.com Fri May 9 08:43:55 2008 From: linux at alteeve.com (Madison Kelly) Date: Fri, 09 May 2008 11:43:55 -0400 Subject: [tpm] Populating an unfixed number of hash elements Message-ID: <4824713B.5060202@alteeve.com> I am not sure that the subject makes a lot of sense, sorry. :) In a few places I take a string that can have an arbitrary number of elements in it that I use as hash keys. I split up this string and feed in a passed value to a hash reference using the given hash elements. So far, I've not found an effective way to do this, so I've resorted to a frighteningly dumb solution "that works". However, it's not at all flexible and frankly, I am ashamed of it. So please, TPM, help me regain some dignity! :) I need a way to /intelligently/ create a hash entry. I've tried 'eval'ing it into existence but that never seems to work for some reason... Thanks!! Madi -=-=-=-=-=-=-=- Here is an example of what I am trying to do: my %hash=(); $string1="some::string::of::elements"; $string2="some::string"; $string3="some::string::of::other::elements"; $string4="another::set::of::keys"; $self->_to_hash(\%hash, $string1, "a value"); $self->_to_hash(\%hash, $string2, 12); $self->_to_hash(\%hash, $string3, "a really long string that takes up pages"); $self->_to_hash(\%hash, $string4, "something else again."); sub _to_hash { my $self=shift; my $hashref=shift; my $keystring=shift; my $value=shift; my @key=split /::/, $hashref; # Here is where it gets... undignified... if (@key==5) { $$hashref{$key[0]}{$key[1]}{$key[2]}{$key[3]}{$key[4]}=$value; } elsif (@key==4) { $$hashref{$key[0]}{$key[1]}{$key[2]}{$key[3]}=$value; } elsif (@key==3) { $$hashref{$key[0]}{$key[1]}{$key[2]}=$value; } elsif (@key==2) { $$hashref{$key[0]}{$key[1]}=$value; } elsif (@key==1) { $$hashref{$key[0]}=$value; } else { croak "Unsupported number of kash keys.\n"; } return(); } From rdice at pobox.com Fri May 9 09:44:36 2008 From: rdice at pobox.com (Richard Dice) Date: Fri, 9 May 2008 12:44:36 -0400 Subject: [tpm] Populating an unfixed number of hash elements In-Reply-To: <4824713B.5060202@alteeve.com> References: <4824713B.5060202@alteeve.com> Message-ID: <5bef4baf0805090944i58d013baucd18a5ab0eb7a689@mail.gmail.com> Hi Madison, Could you re-iterate (in a cleaner fashion) what your input is and what your desired output is? As for the output, you can provide Data::Dumper dumps of the data structures you want. Could I consider your data to be: some::string::of::elements > some::string > some::string::of::other::elements > another::set::of::keys > ? (I will loop through this using a while (<>) loop in whatever programming I cook up.) Cheers, - Richard On Fri, May 9, 2008 at 11:43 AM, Madison Kelly wrote: > I am not sure that the subject makes a lot of sense, sorry. :) > > In a few places I take a string that can have an arbitrary number of > elements in it that I use as hash keys. I split up this string and feed > in a passed value to a hash reference using the given hash elements. > > So far, I've not found an effective way to do this, so I've resorted to > a frighteningly dumb solution "that works". However, it's not at all > flexible and frankly, I am ashamed of it. So please, TPM, help me regain > some dignity! :) > > I need a way to /intelligently/ create a hash entry. I've tried > 'eval'ing it into existence but that never seems to work for some reason... > > Thanks!! > > Madi > > -=-=-=-=-=-=-=- > Here is an example of what I am trying to do: > > my %hash=(); > > $string1="some::string::of::elements"; > $string2="some::string"; > $string3="some::string::of::other::elements"; > $string4="another::set::of::keys"; > > $self->_to_hash(\%hash, $string1, "a value"); > $self->_to_hash(\%hash, $string2, 12); > $self->_to_hash(\%hash, $string3, "a really long string that takes up > pages"); > $self->_to_hash(\%hash, $string4, "something else again."); > > sub _to_hash > { > my $self=shift; > my $hashref=shift; > my $keystring=shift; > my $value=shift; > > my @key=split /::/, $hashref; > > # Here is where it gets... undignified... > if (@key==5) > { > $$hashref{$key[0]}{$key[1]}{$key[2]}{$key[3]}{$key[4]}=$value; > } > elsif (@key==4) > { > $$hashref{$key[0]}{$key[1]}{$key[2]}{$key[3]}=$value; > } > elsif (@key==3) > { > $$hashref{$key[0]}{$key[1]}{$key[2]}=$value; > } > elsif (@key==2) > { > $$hashref{$key[0]}{$key[1]}=$value; > } > elsif (@key==1) > { > $$hashref{$key[0]}=$value; > } > else > { > croak "Unsupported number of kash keys.\n"; > } > > return(); > } > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm > -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080509/674b163b/attachment.html From sfryer at sourcery.ca Fri May 9 09:58:49 2008 From: sfryer at sourcery.ca (Shaun Fryer) Date: Fri, 9 May 2008 12:58:49 -0400 Subject: [tpm] Populating an unfixed number of hash elements In-Reply-To: <4824713B.5060202@alteeve.com> References: <4824713B.5060202@alteeve.com> Message-ID: <20080509165848.GB10094@sourcery.ca> Hey Madi, This works. I had to modify how the sub was called slightly, but hopefully it's still workable for you. ################################################################################ use strict; use warnings; use Data::Dumper; my $string1="some::string::of::elements"; my $string2="some::string"; my $string3="some::string::of::other::elements"; my $string4="another::set::of::keys"; my $href={}; $href = mk_href($string1, "a value"); print Dumper $href; $href = mk_href($string2, 12); print Dumper $href; $href = mk_href($string3, "a really long string that takes up pages"); print Dumper $href; $href = mk_href($string4, "something else again."); print Dumper $href; sub mk_href { my ($keystr, $value) = @_; my @keys = split /::/, $keystr; my $last_key = pop @keys; my $href = {}; $href->{$last_key} = $value; while (my $key = pop @keys) { my $elem = {}; $elem->{$key} = $href; $href = $elem; } return $href; } ################################################################################ Cheers, -- Shaun Fryer On Fri, May 09, 2008 at 11:43:55AM -0400, Madison Kelly wrote: > I am not sure that the subject makes a lot of sense, sorry. :) > > In a few places I take a string that can have an arbitrary number of > elements in it that I use as hash keys. I split up this string and feed > in a passed value to a hash reference using the given hash elements. > > So far, I've not found an effective way to do this, so I've resorted to > a frighteningly dumb solution "that works". However, it's not at all > flexible and frankly, I am ashamed of it. So please, TPM, help me regain > some dignity! :) > > I need a way to /intelligently/ create a hash entry. I've tried > 'eval'ing it into existence but that never seems to work for some reason... > > Thanks!! > > Madi > > -=-=-=-=-=-=-=- > Here is an example of what I am trying to do: > > my %hash=(); > > $string1="some::string::of::elements"; > $string2="some::string"; > $string3="some::string::of::other::elements"; > $string4="another::set::of::keys"; > > $self->_to_hash(\%hash, $string1, "a value"); > $self->_to_hash(\%hash, $string2, 12); > $self->_to_hash(\%hash, $string3, "a really long string that takes up > pages"); > $self->_to_hash(\%hash, $string4, "something else again."); > > sub _to_hash > { > my $self=shift; > my $hashref=shift; > my $keystring=shift; > my $value=shift; > > my @key=split /::/, $hashref; > > # Here is where it gets... undignified... > if (@key==5) > { > $$hashref{$key[0]}{$key[1]}{$key[2]}{$key[3]}{$key[4]}=$value; > } > elsif (@key==4) > { > $$hashref{$key[0]}{$key[1]}{$key[2]}{$key[3]}=$value; > } > elsif (@key==3) > { > $$hashref{$key[0]}{$key[1]}{$key[2]}=$value; > } > elsif (@key==2) > { > $$hashref{$key[0]}{$key[1]}=$value; > } > elsif (@key==1) > { > $$hashref{$key[0]}=$value; > } > else > { > croak "Unsupported number of kash keys.\n"; > } > > return(); > } > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm > From sfryer at sourcery.ca Fri May 9 10:08:19 2008 From: sfryer at sourcery.ca (Shaun Fryer) Date: Fri, 9 May 2008 13:08:19 -0400 Subject: [tpm] Populating an unfixed number of hash elements In-Reply-To: <20080509165848.GB10094@sourcery.ca> References: <4824713B.5060202@alteeve.com> <20080509165848.GB10094@sourcery.ca> Message-ID: <20080509170819.GC10094@sourcery.ca> Actually, this may be more what you intended. However, notice that the key/value may get over-ridden in case of collisions. For instance $string1 will produce { some => { string => { or => { elements => 'a value' } } } } But the value of the key "string" will get overwritten by $string2 to form the following. { some => { string => 12 } } Not sure how you'd work around this except to suggest that your proposed values are in fact keys with a value of 1. (ie. { some => { string => { 12 => 1 } } }). ################################################################################ use strict; use warnings; use Data::Dumper; my $string1="some::string::of::elements"; my $string2="some::string"; my $string3="some::string::of::other::elements"; my $string4="another::set::of::keys"; my %hash = (); mk_href(\%hash, $string1, "a value"); print Dumper \%hash; mk_href(\%hash, $string2, 12); print Dumper \%hash; mk_href(\%hash, $string3, "a really long string that takes up pages"); print Dumper \%hash; mk_href(\%hash, $string4, "something else again."); print Dumper \%hash; sub mk_href { my ($href, $keystr, $value) = @_; my @keys = split /::/, $keystr; my $last_key = pop @keys; my $_href = {}; $_href->{$last_key} = $value; while (my $key = pop @keys) { my $elem = {}; $elem->{$key} = $_href; $_href = $elem; } $href->{$_} = $_href->{$_} for keys %$_href; } ################################################################################ -- Shaun Fryer On Fri, May 09, 2008 at 12:58:49PM -0400, Shaun Fryer wrote: > ################################################################################ > use strict; > use warnings; > use Data::Dumper; > > my $string1="some::string::of::elements"; > my $string2="some::string"; > my $string3="some::string::of::other::elements"; > my $string4="another::set::of::keys"; > > my $href={}; > > $href = mk_href($string1, "a value"); > print Dumper $href; > > $href = mk_href($string2, 12); > print Dumper $href; > > $href = mk_href($string3, "a really long string that takes up pages"); > print Dumper $href; > > $href = mk_href($string4, "something else again."); > print Dumper $href; > > sub mk_href { > my ($keystr, $value) = @_; > my @keys = split /::/, $keystr; > my $last_key = pop @keys; > my $href = {}; > $href->{$last_key} = $value; > while (my $key = pop @keys) { > my $elem = {}; > $elem->{$key} = $href; > $href = $elem; > } > return $href; > } > ################################################################################ From vvp at cogeco.ca Fri May 9 11:00:39 2008 From: vvp at cogeco.ca (Viktor Pavlenko) Date: Fri, 9 May 2008 14:00:39 -0400 Subject: [tpm] Populating an unfixed number of hash elements In-Reply-To: <20080509170819.GC10094@sourcery.ca> References: <4824713B.5060202@alteeve.com> <20080509165848.GB10094@sourcery.ca> <20080509170819.GC10094@sourcery.ca> Message-ID: <18468.37191.279335.360264@hetman.ua> >>>>> "SF" == Shaun Fryer writes: SF> Actually, this may be more what you intended. However, notice SF> that the key/value may get over-ridden in case of SF> collisions. If she avoids global hash, there will be no problem ... SF> sub mk_href { SF> my ($href, $keystr, $value) = @_; SF> my @keys = split /::/, $keystr; SF> my $last_key = pop @keys; SF> my $_href = {}; SF> $_href->{$last_key} = $value; SF> while (my $key = pop @keys) { SF> my $elem = {}; SF> $elem->{$key} = $_href; SF> $_href = $elem; SF> } SF> $href->{$_} = $_href->{$_} for keys %$_href; SF> } ... and then this: -------------------------------------------------------------------->8 sub mk_href { my ($keystr, $value) = @_; my @keys = reverse split /::/, $keystr; helper($value, @keys); } sub helper { my ($val, @keys) = @_; my $k = pop @keys; my $hr = {}; $hr->{$k} = ($#keys == -1) ? $val : helper($val, @keys); return $hr; } -------------------------------------------------------------------->8 -- Viktor From sfryer at sourcery.ca Fri May 9 10:46:07 2008 From: sfryer at sourcery.ca (Shaun Fryer) Date: Fri, 9 May 2008 13:46:07 -0400 Subject: [tpm] Populating an unfixed number of hash elements In-Reply-To: <18468.37191.279335.360264@hetman.ua> References: <4824713B.5060202@alteeve.com> <20080509165848.GB10094@sourcery.ca> <20080509170819.GC10094@sourcery.ca> <18468.37191.279335.360264@hetman.ua> Message-ID: <20080509174607.GD10094@sourcery.ca> Nice and small. I like it. Here's the alternate solution I just came up with. Like yours, uses a recursive helper function, but also works with a global hash. ################################################################################ use strict; use warnings; use Data::Dumper; my $string1="some::string::of::elements"; my $string2="some::string"; my $string3="some::string::of::other::elements"; my $string4="another::set::of::keys"; my %hash = (); mk_href(\%hash, $string1, "a value"); mk_href(\%hash, $string2, 12); mk_href(\%hash, $string3, "a really long string that takes up pages"); mk_href(\%hash, $string4, "something else again."); print Dumper \%hash; sub mk_href { my ($href, $keystr, $value) = @_; my @keys = split /::/, $keystr; my $last_key = pop @keys; my $_href = {}; $_href->{$last_key} = { $value => 1 }; while (my $key = pop @keys) { my $elem = {}; $elem->{$key} = $_href; $_href = $elem; } add_href($href, $_href); } sub add_href { my ($href1, $href2) = @_; for my $key (keys %$href2) { if (ref $href1->{$key} eq 'HASH') { add_href( $href1->{$key}, $href2->{$key} ); } else { $href1->{$key} = $href2->{$key}; } } } ################################################################################ -- Shaun Fryer cl: 905-920-9209 On Fri, May 09, 2008 at 02:00:39PM -0400, Viktor Pavlenko wrote: > >>>>> "SF" == Shaun Fryer writes: > > SF> Actually, this may be more what you intended. However, notice > SF> that the key/value may get over-ridden in case of > SF> collisions. > > If she avoids global hash, there will be no problem ... > > SF> sub mk_href { > SF> my ($href, $keystr, $value) = @_; > SF> my @keys = split /::/, $keystr; > SF> my $last_key = pop @keys; > SF> my $_href = {}; > SF> $_href->{$last_key} = $value; > SF> while (my $key = pop @keys) { > SF> my $elem = {}; > SF> $elem->{$key} = $_href; > SF> $_href = $elem; > SF> } > SF> $href->{$_} = $_href->{$_} for keys %$_href; > SF> } > > ... and then this: > > -------------------------------------------------------------------->8 > sub mk_href > { > my ($keystr, $value) = @_; > my @keys = reverse split /::/, $keystr; > helper($value, @keys); > } > > sub helper > { > my ($val, @keys) = @_; > my $k = pop @keys; > my $hr = {}; > $hr->{$k} = ($#keys == -1) ? $val : helper($val, @keys); > return $hr; > } > -------------------------------------------------------------------->8 > > -- > Viktor > From magog at the-wire.com Sat May 10 17:39:05 2008 From: magog at the-wire.com (Michael Graham) Date: Sat, 10 May 2008 20:39:05 -0400 Subject: [tpm] Subject: May Meeting - Thu 29 May, 2008 - An interpretation of an introduction to mod_perl 2 Message-ID: <20080510203905.6fbff182@caliope> (These details are also on the TPM web site: http://to.pm.org/) The next meeting is this Thursday, 29 May. Date: Thursday 29 May 2008 Time: 6:45pm Where: 2 Bloor Street West (NW corner of Yonge/Bloor, skyscraper with the CIBC logo on top) Classroom TBA =================================================================== Description: Adam is going to go through Phillipe Chaisson's "From CGI to mod_perl 2.0, Fast!" slides, then follow that up with some of detail about mod_perl beyond the ResponseHandler phase touching on some useful, and powerful things that mod_perl can enable you to do. Note: The elevators in the building are "locked down" after 5:30pm to people without building access cards. Leading up to the meeting someone will come down to the main floor lobby every few minutes to ferry people upstairs. After 19:00, you can reach the access-card-carrying guy via a cell phone number that we'll leave with security in the front lobby. The room and floor numbers will be left with security too. -- Michael Graham From linux at alteeve.com Sat May 10 17:43:43 2008 From: linux at alteeve.com (Madison Kelly) Date: Sat, 10 May 2008 20:43:43 -0400 Subject: [tpm] Forthcoming attractions for the rest of the year In-Reply-To: <18049.199.43.183.133.1210344710.squirrel@webmail.vex.net> References: <18049.199.43.183.133.1210344710.squirrel@webmail.vex.net> Message-ID: <4826413F.6070801@alteeve.com> arocker at vex.net wrote: > This month, (May), we have Adam Prime booked. > Next month, (June), will somebody volunteer to debrief on YAPC, for we > little piggies who have to stay home? > September is traditionally "Lightning Talks". > December is given over to Saturnalian revels. > > That leaves July, August, October, and November to fill. Any volunteers? I am planning to give a talk on DBus to [GTA]TLUG in August... Though I am using the Perl Net::DBus bindings are my template for demos and such. I could do a more perl/Net::DBus oriented talk in August for TPM, if you would like. Madi From rdice at pobox.com Tue May 13 17:41:46 2008 From: rdice at pobox.com (Richard Dice) Date: Tue, 13 May 2008 20:41:46 -0400 Subject: [tpm] Damian Conway gives free public talk in Toronto, Wed July 16 Message-ID: <5bef4baf0805131741r530e3211re0637abeba609e60@mail.gmail.com> Hi everyone, Save the date! The evening of Wed 16 July 2008, Damian Conway, Perl Monger extraordinaire and long-time friend of Toronto.pm, will deliver -- free and to the public -- one of his signature tour-de-force completely insane talks that is 1/3 high-end IT, 1/3 showmanship and 1/3 peyote-fuelled hallucination. Its title is: "Temporally Quaquaversal Virtual Nanomachine Programming in > Multiple Topologically Connected Quantum-Relativistic > Parallel Timespaces... Made Easy" > This will be the world premiere of the talk. Precise location and time details to follow. As I've done the past 4 times Damian has come to give us talks I will take up a collection. This is to help defray expenses and to provide Damian with an honorarium for the talk. Donations are completely voluntary. If you feel motivated and/or in the right place financially to make a donation please get in touch with me. Toronto.pm has always been incredibly generous in supporting Damian whenever he has visited in the past and both he and I thank everyone for all the support he has received over the years. Cheers, - Richard -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080513/0c480361/attachment.html From jkeen at verizon.net Sat May 17 09:21:14 2008 From: jkeen at verizon.net (James E Keenan) Date: Sat, 17 May 2008 12:21:14 -0400 Subject: [tpm] Please help with the Perl Monger Group Census Message-ID: <619C0C84-4F71-4B4A-AF30-1B76DE71B407@verizon.net> Toronto.pm has apparently not completed the PM Group Census conducted biannually by Dave Cross (census at pm.org). http://mag-sol.com/census2008/missing.cgi Michael, are you still the contact person for this? jimk From michael.a.bolton at gmail.com Tue May 20 18:32:46 2008 From: michael.a.bolton at gmail.com (Michael Bolton) Date: Tue, 20 May 2008 21:32:46 -0400 Subject: [tpm] Please help with the Perl Monger Group Census In-Reply-To: <619C0C84-4F71-4B4A-AF30-1B76DE71B407@verizon.net> References: <619C0C84-4F71-4B4A-AF30-1B76DE71B407@verizon.net> Message-ID: <007501c8bae2$92fdf030$bea8a8c0@Koko> For the sake of all of us named "Michael", a last name is probably a good idea. Michael Graham. ---Michael B. -----Original Message----- From: toronto-pm-bounces+mb=michaelbolton.net at pm.org [mailto:toronto-pm-bounces+mb=michaelbolton.net at pm.org] On Behalf Of James E Keenan Sent: May 17, 2008 12:21 PM To: toronto-pm at pm.org Subject: [tpm] Please help with the Perl Monger Group Census Toronto.pm has apparently not completed the PM Group Census conducted biannually by Dave Cross (census at pm.org). http://mag-sol.com/census2008/missing.cgi Michael, are you still the contact person for this? jimk _______________________________________________ toronto-pm mailing list toronto-pm at pm.org http://mail.pm.org/mailman/listinfo/toronto-pm From michael.a.bolton at gmail.com Tue May 20 18:34:04 2008 From: michael.a.bolton at gmail.com (Michael Bolton) Date: Tue, 20 May 2008 21:34:04 -0400 Subject: [tpm] Conference for the Association for Software Testing Message-ID: <007601c8bae2$c1d1b360$bea8a8c0@Koko> Greetings... Some of you Toronto Perlites must be testers. If aren't a tester, you probably /know/ some testers. So please read and spread the word: A colleague recently pointed out that an important mission of our community--the community of skilled testers--is to remind people-and ourselves-that testing doesn't have to suck. Well, neither do testing conferences. CAST 2008 is the kind of conference that I've always wanted to attend. The theme is "Beyond the Boundaries: Interdisciplinary Approaches to Software Testing", and the program is incredibly eclectic and diverse. Start with the keynotes: - Jerry Weinberg on Lessons from the Past to Carry into the Future; - Cem Kaner on The Value of Checklists and the Danger of Scripts: What Legal Training Suggests for Testers; - Robert Sabourin (with Anne Sabourin) on Applied Testing Lessons from Delivery Room Labor Triage (there's a related article in this month's Better Software magazine); and - Brian Fisher on The New Science of Visual Analytics. Track sessions include talks relating testing - to improv theatre (Adam White), to music (yours truly and Jonathan Kohl), - to finance and accounting (Doug Hoffman), - to wargaming and Darwinian evolution (Bart Brokeman, author of /Testing Embedded Software/ and one of the co-authors of the /TMap Next/ book); - to civil engineering (Scott Barber); - to scientific software (Diane Kelly and Rebecca Sanders) - to magic (Jeremy Kominar), to file systems (Morven Gentleman) - and to data warehousing (Steve Richardson and Adam Geras) - and to data visualization (Martin Taylor); - AND to four-year-olds playing lacrosse (Adam Goucher). There will be lightning talks and a tester competition. Jerry Weinberg will be doing a one-day tutorial workshop, as will Hung Nguyen, Scott Barber, and Julian Harty. Yet another feature of the conference is that Jerry is launching his book on testing, /Perfect Software and Other Testing Myths/. I read an early version of it, and I'm waiting for it with bated breath. It's a book that we'll all want to read, and after we're done, we'll want to hand to people who are customers of testing. For some, we'll want to tie them to a chair and /read it to them/. For the out-of-towners (I know there are some Buffalo types out there), the conference hotel is inexpensive (you'll know where to find it; it's where YAPC was); the food in Toronto is great, the nightlife is wonderful, the music is excellent... More Information ================ You can find details on the program at http://www.cast2008.org/Program. You can find information on the venue and logistics at http://www.cast2008.org/Venue. Those from outside Canada should look at http://www.associationforsoftwaretesting.org/drupal/CAST2008/Venue#customs. You can get registration information at http://www.cast2008.org/Registration. Paying the Way ============== If you need help persuading your company to send you to the conference, check out this: http://www.ayeconference.com/Articles/Mycompanywontpay.html. And if all that fails, you can likely write off the cost of the conference against your taxes, even if you're an employee. (I am not a tax professional, but INC magazine reports that you can write off expenses to "maintain or improve skills required in your present employment". Americans should see IRS Publication 970 (http://www.irs.gov/publications/p970/ch12.html), Section 12, and ask your accountant!) Come Along and Spread The Word! =============================== So (if necessary) get your passports in order, take advantage of early bird registration (if you register in the next two weeks), and come join us. In addition (and I'm asking a favour here), please please /please/ tell your colleagues, both in your company and outside, about CAST. We want to share some great ideas on testing and other disciplines, and we want to make this the best CAST ever. And the event will only be improved by your presence. So again, please spread the word, and come if you can. Cheers, ---Michael B. From jkeen at verizon.net Tue May 20 19:04:28 2008 From: jkeen at verizon.net (James E Keenan) Date: Tue, 20 May 2008 22:04:28 -0400 Subject: [tpm] Please help with the Perl Monger Group Census In-Reply-To: <007501c8bae2$92fdf030$bea8a8c0@Koko> References: <619C0C84-4F71-4B4A-AF30-1B76DE71B407@verizon.net> <007501c8bae2$92fdf030$bea8a8c0@Koko> Message-ID: <7D81E018-17C7-45E2-88EC-E3C3CEA634FC@verizon.net> On May 20, 2008, at 9:32 PM, Michael Bolton wrote: > For the sake of all of us named "Michael", a last name is probably > a good > idea. Michael Graham. Agreed! From alexmac131 at hotmail.com Wed May 21 05:19:38 2008 From: alexmac131 at hotmail.com (Alex Mackinnon) Date: Wed, 21 May 2008 12:19:38 +0000 Subject: [tpm] Please help with the Perl Monger Group Census In-Reply-To: <7D81E018-17C7-45E2-88EC-E3C3CEA634FC@verizon.net> References: <619C0C84-4F71-4B4A-AF30-1B76DE71B407@verizon.net> <007501c8bae2$92fdf030$bea8a8c0@Koko> <7D81E018-17C7-45E2-88EC-E3C3CEA634FC@verizon.net> Message-ID: We could all do like in the army and just use last name, same confusion. Context works too. If I say, Tom how about rock climbing thrusday, he (they Tom - Tommer) would know and Tom Jones would not know me and not likely care. The attempt to modify social convetions of familar is to be cheered but like any good car reck not likely to work :) To make this a Perl related conversation, my work is looking for various developers (Java, Perl, systems people) and I oh yes don't work for Accenture anymore :) > Date: Tue, 20 May 2008 22:04:28 -0400> From: jkeen at verizon.net> To: mb at michaelbolton.net> CC: toronto-pm at pm.org> Subject: Re: [tpm] Please help with the Perl Monger Group Census> > > On May 20, 2008, at 9:32 PM, Michael Bolton wrote:> > For the sake of all of us named "Michael", a last name is probably > > a good> > idea. Michael Graham.> > Agreed!> _______________________________________________> toronto-pm mailing list> toronto-pm at pm.org> http://mail.pm.org/mailman/listinfo/toronto-pm _________________________________________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080521/9f66ab7c/attachment.html From arocker at vex.net Wed May 21 06:11:28 2008 From: arocker at vex.net (arocker at vex.net) Date: Wed, 21 May 2008 09:11:28 -0400 (EDT) Subject: [tpm] Please help with the Perl Monger Group Census In-Reply-To: References: <619C0C84-4F71-4B4A-AF30-1B76DE71B407@verizon.net> <007501c8bae2$92fdf030$bea8a8c0@Koko> <7D81E018-17C7-45E2-88EC-E3C3CEA634FC@verizon.net> Message-ID: <54999.199.43.183.133.1211375488.squirrel@webmail.vex.net> > > To make this a Perl related conversation, my work is looking for various > developers (Java, Perl, systems people) Who? Where? From linux at alteeve.com Wed May 21 06:47:17 2008 From: linux at alteeve.com (Madison Kelly) Date: Wed, 21 May 2008 09:47:17 -0400 Subject: [tpm] POD encoding question Message-ID: <483427E5.8040404@alteeve.com> Hi all, I'm having trouble with UTF-8 characters in my module's POD. I've got the entry (truncated for brevity): =item new =encoding UTF-8 #----- use TB::Get; # Get a handle on the TB::HumanReadable methods. my $hr=TB::Get->new; # You can set (...) as a hash reference. Ie: my $hr=TB::Get->new({ use_base_2 => 0, use_24h => 0, say_am => "??", say_pm => "??", date_seperator => "/", time_seperator => "." }); #----- This is the constructor method used to access this module's methods. =cut Now, when I try to read the POD using perldoc, I get: -=-=-=-=-=- new #----- use TB::Get; # Get a handle on the TB::HumanReadable methods. my $hr=TB::Get->new; # You can set (...) as a hash reference. Ie: my $hr=TB::Get->new({ use_base_2 => 0, use_24h => 0, say_am => "??", say_pm => "???", date_seperator => "/", time_seperator => "." }); -=-=-=-=-=- At the command line, I get: $ perldoc TB/Get ./TB/Get.pm:73: Unknown command paragraph "=encoding utf8" :222: warning: can't find numbered character 141 :222: warning: can't find numbered character 141 :223: warning: can't find numbered character 141 :223: warning: can't find numbered character 140 Now, the '=encoding utf8' string is taken directly from the 'perldoc perlpod' documentation... Any tips on what I am doing wrong? Thanks! Madi From sergio at salvi.ca Wed May 21 06:57:30 2008 From: sergio at salvi.ca (Sergio Salvi) Date: Wed, 21 May 2008 15:57:30 +0200 Subject: [tpm] POD encoding question In-Reply-To: <483427E5.8040404@alteeve.com> References: <483427E5.8040404@alteeve.com> Message-ID: <568473410805210657j26b850cfn5fb4cfba0d61c0dd@mail.gmail.com> Do you have "use utf8;" at the beginning of your file? On 5/21/08, Madison Kelly wrote: > Hi all, > > I'm having trouble with UTF-8 characters in my module's POD. I've got > the entry (truncated for brevity): > > =item new > > =encoding UTF-8 > > #----- > use TB::Get; > > # Get a handle on the TB::HumanReadable methods. > my $hr=TB::Get->new; > > # You can set (...) as a hash reference. Ie: > my $hr=TB::Get->new({ > use_base_2 => 0, > use_24h => 0, > say_am => "??", > say_pm => "??", > date_seperator => "/", > time_seperator => "." > }); > #----- > > This is the constructor method used to access this module's methods. > > =cut > > Now, when I try to read the POD using perldoc, I get: > > -=-=-=-=-=- > new > #----- > use TB::Get; > > # Get a handle on the TB::HumanReadable methods. > my $hr=TB::Get->new; > > # You can set (...) as a hash reference. Ie: > my $hr=TB::Get->new({ > use_base_2 => 0, > use_24h => 0, > say_am => "??", > say_pm => "???", > date_seperator => "/", > time_seperator => "." > }); > -=-=-=-=-=- > > At the command line, I get: > > $ perldoc TB/Get > ./TB/Get.pm:73: Unknown command paragraph "=encoding utf8" > :222: warning: can't find numbered character 141 > :222: warning: can't find numbered character 141 > :223: warning: can't find numbered character 141 > :223: warning: can't find numbered character 140 > > Now, the '=encoding utf8' string is taken directly from the 'perldoc > perlpod' documentation... > > Any tips on what I am doing wrong? > > Thanks! > > Madi > > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm > From linux at alteeve.com Wed May 21 07:14:31 2008 From: linux at alteeve.com (Madison Kelly) Date: Wed, 21 May 2008 10:14:31 -0400 Subject: [tpm] POD encoding question In-Reply-To: <568473410805210657j26b850cfn5fb4cfba0d61c0dd@mail.gmail.com> References: <483427E5.8040404@alteeve.com> <568473410805210657j26b850cfn5fb4cfba0d61c0dd@mail.gmail.com> Message-ID: <48342E47.7070708@alteeve.com> Sergio Salvi wrote: > Do you have "use utf8;" at the beginning of your file? I do: -=-=-=-=-=- package TB::Get; use 5.008; use Carp; use Symbol; use strict; use warnings; use locale; use IO::Handle; use utf8; # Setup for UTF-8 mode. binmode STDOUT, ":utf8:"; $ENV{'PERL_UNICODE'}=1; BEGIN { our $VERSION="0.3.051"; } =pod =encoding utf8 =head1 NAME TB::Get ... -=-=-=-=-=- If the internal encoding was an issue, would the error: -=-=-=-=-=- digimer at akane:~/projects/tle-bu.org/cgi-bin$ perldoc TB/Get.pm TB/Get.pm:23: Unknown command paragraph "=encoding utf8" :220: warning: can't find numbered character 141 :220: warning: can't find numbered character 141 :221: warning: can't find numbered character 141 :221: warning: can't find numbered character 140 -=-=-=-=-=- Still be printed? Madi From james.a.graham at gmail.com Wed May 21 11:29:25 2008 From: james.a.graham at gmail.com (Jim Graham) Date: Wed, 21 May 2008 14:29:25 -0400 Subject: [tpm] POD encoding question In-Reply-To: <483427E5.8040404@alteeve.com> References: <483427E5.8040404@alteeve.com> Message-ID: This is a bug in 5.8.x and should be fixed in 5.10 http://rt.perl.org/rt3/Public/Bug/Display.html?id=47271 It would appear you need version 1.4301 of Pod::Checker. I tested your code on 5.8.8 and 5.10 on Mac OS X 10.5.2 and I got the bug with 5.8.8 and it's fixed in 5.10 (ie. no "Unknown command paragraph "=encoding utf8" " error). However, the UTF characters weren't printed correctly when running the POD. I'm not sure if that's a Perl error or a shell error. regards, Jim Source ------ # You can set (...) as a hash reference. Ie: my $hr=TB::Get->new({ use_base_2 => 0, use_24h => 0, say_am => "??", say_pm => "??", date_seperator => "/", time_seperator => "." }); Terminal ------- #????? use TB::Get; # Get a handle on the TB::HumanReadable methods. my $hr=TB::Get?>new; # You can set (...) as a hash reference. Ie: my $hr=TB::Get?>new({ use_base_2 => 0, use_24h => 0, say_am => "XX", say_pm => "XX", date_seperator => "/", time_seperator => "." }); On 21-May-08, at 9:47 AM, Madison Kelly wrote: > Hi all, > > I'm having trouble with UTF-8 characters in my module's POD. I've > got > the entry (truncated for brevity): > > =item new > > =encoding UTF-8 > > #----- > use TB::Get; > > # Get a handle on the TB::HumanReadable methods. > my $hr=TB::Get->new; > > # You can set (...) as a hash reference. Ie: > my $hr=TB::Get->new({ > use_base_2 => 0, > use_24h => 0, > say_am => "??", > say_pm => "??", > date_seperator => "/", > time_seperator => "." > }); > #----- > > This is the constructor method used to access this module's methods. > > =cut > > Now, when I try to read the POD using perldoc, I get: > > -=-=-=-=-=- > new > #----- > use TB::Get; > > # Get a handle on the TB::HumanReadable methods. > my $hr=TB::Get->new; > > # You can set (...) as a hash reference. Ie: > my $hr=TB::Get->new({ > use_base_2 => 0, > use_24h => 0, > say_am => "??", > say_pm => "???", > date_seperator => "/", > time_seperator => "." > }); > -=-=-=-=-=- > > At the command line, I get: > > $ perldoc TB/Get > ./TB/Get.pm:73: Unknown command paragraph "=encoding utf8" > :222: warning: can't find numbered character 141 > :222: warning: can't find numbered character 141 > :223: warning: can't find numbered character 141 > :223: warning: can't find numbered character 140 > > Now, the '=encoding utf8' string is taken directly from the 'perldoc > perlpod' documentation... > > Any tips on what I am doing wrong? > > Thanks! > > Madi > > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm From lanas at securenet.net Wed May 21 17:27:56 2008 From: lanas at securenet.net (lanas) Date: Wed, 21 May 2008 20:27:56 -0400 Subject: [tpm] Attending the next meeting Message-ID: <20080521202756.007d738e@mistral.stie> Hello, I would like to attend the next meeting on the 29th of May. Is there any fee ? I've been doing some Perl programming (but not only that) since about three years now. I like quite a lot POE and have done a couple of applications using it. I've also been doing C++ and ACE/TAO CORBA stuff, as well as different C assignements, Linux system builds, and various utilities in Perl and bash. When I have some time and inclination to do so I like to explore in Smalltalk (Visual Works and Squeak) although I haven't done that lately. Looking forward to attend the meeting. Cheers, Al From adam.prime at utoronto.ca Fri May 23 08:22:54 2008 From: adam.prime at utoronto.ca (adam.prime at utoronto.ca) Date: Fri, 23 May 2008 11:22:54 -0400 Subject: [tpm] Attending the next meeting In-Reply-To: <20080521202756.007d738e@mistral.stie> References: <20080521202756.007d738e@mistral.stie> Message-ID: <20080523112254.orowts99pck4w4kg@webmail.utoronto.ca> Quoting lanas : > Hello, > > I would like to attend the next meeting on the 29th of May. Is there > any fee ? > There is no cost to attend. Adam From linux at alteeve.com Mon May 26 12:45:45 2008 From: linux at alteeve.com (Madison Kelly) Date: Mon, 26 May 2008 15:45:45 -0400 Subject: [tpm] IO::Handle not catching errors Message-ID: <483B1369.5010803@alteeve.com> Hi all, I use IO::Handle for shell calls, and then check 'error' to see if there was an error. However, this isn't catching errors... Can someone clue me in? sub do_shell_call { my ($shell_call)=@_; my $sc=IO::Handle->new(); print " Shell call: [$shell_call]\n"; open ($sc, $shell_call) or die "Shell call: [$shell_call] failed with error: $!"; my $output=0; while (<$sc>) { if (!$output) { print "/----\n"; $output=1; } print "| $_"; } if ($output) { print "\\----\n"; } if ($sc->error) { die "Shell call: [$shell_call] returned an error: $!"; } $sc->close; return 0; } Madi From jkeen at verizon.net Mon May 26 16:43:49 2008 From: jkeen at verizon.net (James E Keenan) Date: Mon, 26 May 2008 19:43:49 -0400 Subject: [tpm] IO::Handle not catching errors In-Reply-To: <483B1369.5010803@alteeve.com> References: <483B1369.5010803@alteeve.com> Message-ID: On May 26, 2008, at 3:45 PM, Madison Kelly wrote: > > I use IO::Handle for shell calls, Why? When I call 'perldoc IO::Handle', among the first things I read is: "It is not intended that objects of "IO::Handle" would be created directly, but instead "IO::Handle" is inherited from by several other classes in the IO hierarchy." Your example does not suggest that you are inheriting from IO::Handle. Above and beyond that, you do not appear to be calling it in an object-oriented way. You create the IO::Handle object: > > print " Shell call: [$shell_call]\n"; ... and then proceed to use it as the second argument to a Perl built- in 'open' function, where one would normally expect something like '<': > open ($sc, $shell_call) or die "Shell call: [$shell_call] failed with > error: $!"; On what basis do you expect the preceding statement to do something useful? You don't appear to call a method on your IO::Handle object until here: > if ($sc->error) > { > die "Shell call: [$shell_call] returned an error: $!"; > } > $sc->close; > I'm unclear as to what you're intending to do, but I suspect IO::Handle is not the way to do it. Can you clarify? Thank you very much. Jim Keenan From jkeen at verizon.net Mon May 26 19:50:03 2008 From: jkeen at verizon.net (James E Keenan) Date: Mon, 26 May 2008 22:50:03 -0400 Subject: [tpm] IO::Handle not catching errors In-Reply-To: References: <483B1369.5010803@alteeve.com> Message-ID: On May 26, 2008, at 7:59 PM, Cees Hek wrote: >> >> do something >> useful? > > Actually, you can pass IO::Handle based objects as the first parameter > of open. I stand corrected, or, rather, I sit corrected. But I still wonder why a system call would not suffice. From indy at indigostar.com Mon May 26 20:42:27 2008 From: indy at indigostar.com (Indy Singh) Date: Mon, 26 May 2008 23:42:27 -0400 Subject: [tpm] IO::Handle not catching errors References: <483B1369.5010803@alteeve.com> Message-ID: <00a801c8bfab$af082ac0$6600a8c0@roadhog> If the shell process exits with a non-zero status, the return value will be found in $?. You might need to call close first before you check $?. A non-zero return code will not be an an IO error. IO errors are not very likely and I'm not sure if it is useful to worry about them. An error in starting the shell process will be caught by the open call. Indy Singh IndigoSTAR Software -- www.indigostar.com ----- Original Message ----- From: "Madison Kelly" To: "Toronto Perl Mongers" Sent: Monday, May 26, 2008 3:45 PM Subject: [tpm] IO::Handle not catching errors > Hi all, > > I use IO::Handle for shell calls, and then check 'error' to see if > there was an error. However, this isn't catching errors... Can someone > clue me in? > > sub do_shell_call > { > my ($shell_call)=@_; > > my $sc=IO::Handle->new(); > print " Shell call: [$shell_call]\n"; > open ($sc, $shell_call) or die "Shell call: [$shell_call] failed with > error: $!"; > my $output=0; > while (<$sc>) > { > if (!$output) { print "/----\n"; $output=1; } > print "| $_"; > } > if ($output) { print "\\----\n"; } > if ($sc->error) > { > die "Shell call: [$shell_call] returned an error: $!"; > } > $sc->close; > > return 0; > } > > Madi > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm > From linux at alteeve.com Tue May 27 05:38:43 2008 From: linux at alteeve.com (Madison Kelly) Date: Tue, 27 May 2008 08:38:43 -0400 Subject: [tpm] IO::Handle not catching errors In-Reply-To: References: <483B1369.5010803@alteeve.com> Message-ID: <483C00D3.4050301@alteeve.com> Thanks for replying! I'll address your questions in-line. :) James E Keenan wrote: > On May 26, 2008, at 3:45 PM, Madison Kelly wrote: >> I use IO::Handle for shell calls, > > Why? A couple years ago I was having trouble with some IPC stuff clobbering "traditional" filehandles. I found that the 'Filehandle' module off CPAN solved those problems. However, 'Filehandle' is not a core module, and so expecting a user to have it could cause dependency problems. So I did some looking and, perhaps incorrectly, realized that IO::Handle looked to do the same thing and was a core module, so using it seemed to solved the clobbering problem and not have the dependency problem. Since then, I've made a habit of using it everywhere. > When I call 'perldoc IO::Handle', among the first things I read is: > > "It is not intended that objects of "IO::Handle" would be created > directly, but instead "IO::Handle" is inherited from by several other > classes in the IO hierarchy." > > Your example does not suggest that you are inheriting from IO::Handle. > > Above and beyond that, you do not appear to be calling it in an > object-oriented way. You create the IO::Handle object: > >> print " Shell call: [$shell_call]\n"; > > ... and then proceed to use it as the second argument to a Perl built- > in 'open' function, where one would normally expect something like '<': > >> open ($sc, $shell_call) or die "Shell call: [$shell_call] failed with >> error: $!"; > > On what basis do you expect the preceding statement to do something > useful? This catch works... Say for example if the '$shell_call' had a bad path to an executable, or if it lacked permissions, it would trigger 'die' and properly exit. > You don't appear to call a method on your IO::Handle object until here: > > >> if ($sc->error) >> { >> die "Shell call: [$shell_call] returned an error: $!"; >> } >> $sc->close; >> > > I'm unclear as to what you're intending to do, but I suspect > IO::Handle is not the way to do it. Can you clarify? > > Thank you very much. > Jim Keenan As I (probably incorrectly) understood the docs, the '$sc->error' should be set if the called shell program ran properly but returned a non-zero exit code (because something it was supposed to do didn't work). In my current program, for example, I am calling 'rpm' to install a package. The call the the 'rpm' binary works, so the first 'die' doesn't trigger, but the 'rpm' binary itself exits with a non-zero code because the RPM I was trying to install failed due to dependency issues. That is was I want to trap. Madi From linux at alteeve.com Tue May 27 05:42:42 2008 From: linux at alteeve.com (Madison Kelly) Date: Tue, 27 May 2008 08:42:42 -0400 Subject: [tpm] IO::Handle not catching errors In-Reply-To: References: <483B1369.5010803@alteeve.com> Message-ID: <483C01C2.9030809@alteeve.com> Cees Hek wrote: > On Tue, May 27, 2008 at 5:45 AM, Madison Kelly wrote: >> Hi all, >> >> I use IO::Handle for shell calls, and then check 'error' to see if >> there was an error. However, this isn't catching errors... Can someone >> clue me in? >> >> sub do_shell_call >> { >> my ($shell_call)=@_; >> >> my $sc=IO::Handle->new(); >> print " Shell call: [$shell_call]\n"; >> open ($sc, $shell_call) or die "Shell call: [$shell_call] failed with >> error: $!"; >> my $output=0; >> while (<$sc>) >> { >> if (!$output) { print "/----\n"; $output=1; } >> print "| $_"; >> } >> if ($output) { print "\\----\n"; } >> if ($sc->error) >> { >> die "Shell call: [$shell_call] returned an error: $!"; >> } >> $sc->close; >> >> return 0; >> } > > Which errors are you trying to catch? An error with IO::Handle, or > errors with the script or program you are launching? I think > IO::Handle will only return errors regarding things like 'unable to > open file', or 'could not write to file' (those are paraphrased > errors). If you want to catch errors in the script you are running, > you will have to look at the return value of the script to see if it > exitted cleanly. > > When running external programs, you might be better off using > something like IPC::Run which is better at error handling, or possibly > IPC::Open2 or IPC::Open3. > > Cheers, > > Cees Thanks for the reply! I love this list, so many helpful people. :) Please see my reply to James sent *just* before this. I went into better detail what I am trying to do. In short though; I wanted to use 'IO::Handle' to avoid dependency issues as it's a "core" module. I am trying to trap non-zero exit status' from the called shell command. The first '... or die ...' catches problems will calling the shell call itself (bad permissions, etc), and the second '$sc->error' check I want to trap shell calls that succeeded but exited with non-zero codes. Madi From linux at alteeve.com Tue May 27 05:46:56 2008 From: linux at alteeve.com (Madison Kelly) Date: Tue, 27 May 2008 08:46:56 -0400 Subject: [tpm] IO::Handle not catching errors In-Reply-To: <00a801c8bfab$af082ac0$6600a8c0@roadhog> References: <483B1369.5010803@alteeve.com> <00a801c8bfab$af082ac0$6600a8c0@roadhog> Message-ID: <483C02C0.9090601@alteeve.com> Indy Singh wrote: > If the shell process exits with a non-zero status, the return value will > be found in $?. You might need to call close first before you check $?. > > A non-zero return code will not be an an IO error. IO errors are not > very likely and I'm not sure if it is useful to worry about them. > > An error in starting the shell process will be caught by the open call. > > Indy Singh Doh! I went at this looking for too complex a solution. I will check that as soon as I get into the office in a couple hours and report back to the list "for the record". Thanks! Madi From michael.a.bolton at gmail.com Wed May 28 08:30:29 2008 From: michael.a.bolton at gmail.com (Michael Bolton) Date: Wed, 28 May 2008 11:30:29 -0400 Subject: [tpm] CAST 2008: Last week for Early Bird Registration PLUS An Interview with Jerry Weinberg Message-ID: <000501c8c0d7$cb524fd0$0c02a8c0@Koko> Hi, all... This is Michael Bolton, the Conference Chair for the Conference for the Association for Software Testing 2008. It's the last week to register at the Early Bird Rate for the CAST conference! The Conference will be held here in Toronto, July 14-16 2008, at the University of Toronto's 89 Chestnut Street hotel and conference facility--right in the heart of downtown. If you've already registered, scroll below for an interview with Jerry Weinberg, who'll be presenting a tutorial and a keynote address at the conference. If you haven't already registered, keep reading to find out why you'll want to. Start with the keynotes: * Jerry Weinberg on Lessons from the Past to Carry into the Future; * Cem Kaner on The Value of Checklists and the Danger of Scripts: What Legal Training Suggests for Testers * Robert Sabourin (with Anne Sabourin) on Applied Testing Lessons from Delivery Room Labor Triage (there's a related article in this month's Better Software magazine) * Brian Fisher on The New Science of Visual Analytics. There are four one-day tutorials-- The Tester's Communication Clinic, from Jerry Weinberg Testing Mobile Applications, from Julian Harty Performance Testing Software Systems: Analyzing Performance Test Data, with Scott Barber From Craftsmanship to Leadership, with Hung Nguyen Track sessions include talks relating testing to - improv theatre (Adam White), to music (Michael Bolton and Jonathan Kohl) - finance and accounting (Doug Hoffman) - wargaming and Darwinian evolution (Bart Brokeman, author of /Testing Embedded Software/ and one of the co-authors of the /TMap Next/ book) - civil engineering (Scott Barber) - scientific software (Diane Kelly and Rebecca Sanders), - magic (Jeremy Kominar), - file systems (Morven Gentleman), - data warehousing (Steve Richardson and Adam Geras), and - data visualization (Martin Taylor), AND - four-year-olds playing lacrosse (Adam Goucher). There will also be lightning talks and a tester competition. Yet another feature of the conference is that Jerry is launching his book on testing, /Perfect Software and Other Testing Myths/. I read an early version of it, and I'm waiting for it with bated breath. It's a book that we'll all want to read, and after we're done, we'll want to hand to people who are customers of testing. For some, we'll want to tie them to a chair and /read it to them/. The conference hotel is inexpensive, the food in Toronto is great, the nightlife is wonderful, the music is excellent... More Information ================ You can find details on the program at http://www.cast2008.org/Program. You can find information on the venue and logistics at http://www.cast2008.org/Venue. Those from outside Canada should look at http://www.associationforsoftwaretesting.org/drupal/CAST2008/Venue#cus toms. You can get registration information at http://www.cast2008.org/Registration. An Interview with Gerald M. (Jerry) Weinberg ============================================ Being a conference chair has its advantages. Recently I was privileged to chat with Jerry Weinberg on why he's favouring CAST with his only conference appearance of the year, other than the Amplifying Your Effectiveness conference, of which he's a co-founder and host. Michael: You've been involved with computers for 50 years, and with giving people advice for almost that long. What do you suggest my first question should be, and how would you answer it? Jerry: Ask me why I chose this conference as my one of the year. And other things. Michael: Sounds good. So: why did you choose this conference as your one of the year? Jerry: Errors have been the principal issue in computing right from the beginning, as John von Neumann pointed out even before I got into the field (and that's really a long time ago). I wrote about testing as the opening topic in my first book, "Computer Programming Fundamentals" way back in 1960--and way back then, I already took flack from some reviewers who didn't think errors was a suitable topic for politically correct people. You'd think I had written about human excrement. And you'd also think that as our field matured, we would have outgrown that prudish attitude about error--but we haven't. Back then, we had no professional testers. Testing was every developer's job (though they weren't called "developers" back then, or even "programmers"). We fought hard to have testing recognized as a profession of its own, and though we have people called "testers" today, we still have the prudes. In many organizations, testers are, sadly, considered lower-class citizens. Testing holds a special place in my vision of the future of the computing profession as a whole. Why? Because testing is the first place where we generally get an independent and realistic view of what we are doing right and what we are doing wrong when we build new systems. We do get this view from Support (another area that's considered low-class), but by the time information arrives from Support, the people who put the errors in a product are often long gone and immune to learning from their mistakes. Quite simply, if we don't learn to learn from our mistakes, we won't improve as a profession. And if we don't improve, we limit whatever good this amazing new (still) technology offers to humanity. That's why I've made the status of testing and testers my first priority for some years, and why I'm debuting my book on testing fallacies and myths at CAST, the one conference that I feel is a creation of testers, by testers, and for testers. Michael: Recently you launched a new Web site, and your banner is "Helping smart people to be happy." Why did you choose that? Jerry: Most of the people in the computing professions are pretty smart, at least as measured by tests and the kind of technical work they accomplish. But so many of them haven't learned how to use their smarts on themselves. They can create wonderful systems, but when they use their brains to think about themselves, they often think themselves into depression. I was like that, for a long time, until I began to figure out what I was doing to myself. I set myself the task of learning how to be happy, and as I began to succeed, I realized that one of the things that makes me happy is working with other happy people. So, selfishly, I decided I would devote myself to helping my colleagues and students learn to share my happiness. Like most things I do, it's completely selfish--but has side effects that others may enjoy. Michael: Why not "Helping happy people be smart?" Jerry: If you're happy, you don't need to be smart. Smart isn't the only road to happiness. It's not that I mind helping people be smart, or smarter, but it's just not my primary goal. Nevertheless, I guess there are thousands of people out there who would say I've helped them grow smarter in some way. I think that's true of you, Michael, at least from what you tell me. I hope I've helped you be happier, too. Michael: Happier for sure, and smarter I hope. I've learned about both from conversations that I've had with you and other smart people. I remember once that Joshua Kerievsky asked you about why and how you tested in the old days--and I remember you telling Josh that you were compelled to test because the equipment was so unreliable. Computers don't break down as they used to, so what's the motivation for unit testing and test-first programming today? Jerry: We didn't call those things by those names back then, but if you look at my first book, and many others since, you'll see that was always the way we thought was the only logical way to do things. I learned it from Bernie Dimsdale, who learned it from von Neumann. When I started in computing, I had nobody to teach me programming, so I read the manuals and taught myself. I thought I was pretty good, then I ran into Bernie (in 1957), who showed me how the really smart people did things. My ego was a bit shocked at first, but then I figured out that if von Neumann did things this way, I should. John von Neumann was a lot smarter than I'll ever be, or than most people will ever be, but all that means is that we should learn from him. And that's why I go to a select number of conferences, like CAST and AYE, because there are lots of smart people there to learn from. I recommend my tactic to any smart person who wants to be happy. =================================================== Paying the Way ============== If you need help persuading your company to send you to the conference, check out this: http://www.ayeconference.com/Articles/Mycompanywontpay.html. And if all that fails, you can likely write off the cost of the conference against your taxes, even if you're an employee. (I am not a tax professional, but INC magazine reports that you can write off expenses to "maintain or improve skills required in your present employment". Americans should see IRS Publication 970 ( http://www.irs.gov/publications/p970/ch12.html), Section 12, and ask your accountant!) Come Along and Spread The Word! =============================== So (if necessary) get your passports in order, take advantage of early bird registration (if you register this week), and come join us. In addition (and I'm asking a favour here), please please /please/ tell your colleagues, both in your company and outside, about CAST. We want to share some great ideas on testing and other disciplines, and we want to make this the best CAST ever. And the event will only be improved by your presence. So again, please spread the word, and come if you can. ---Michael B. From magog at the-wire.com Wed May 28 19:37:25 2008 From: magog at the-wire.com (Michael Graham) Date: Wed, 28 May 2008 22:37:25 -0400 Subject: [tpm] May Meeting Tomorrow - Thu 29 May, 2008 - An interpretation of an introduction to mod_perl 2 Message-ID: <20080528223725.52cf0422@caliope> (These details are also on the TPM web site: http://to.pm.org/) The next meeting is this Thursday, 29 May (Tomorrow). Date: Thursday 29 May 2008 Time: 6:45pm Cost: Free! Where: 2 Bloor Street West (NW corner of Yonge/Bloor, skyscraper with the CIBC logo on top) Classroom 11 on the 8th floor =================================================================== Description: Adam is going to go through Phillipe Chaisson's "From CGI to mod_perl 2.0, Fast!" slides, then follow that up with some of detail about mod_perl beyond the ResponseHandler phase touching on some useful, and powerful things that mod_perl can enable you to do. Note: The elevators in the building are "locked down" after 5:30pm to people without building access cards. Leading up to the meeting someone will come down to the main floor lobby every few minutes to ferry people upstairs. After 19:00, you can reach the access-card-carrying guy via a cell phone number that we'll leave with security in the front lobby. The room and floor numbers will be left with security too. -- Michael Graham From kevork at quantum-qtr.com Wed May 28 13:20:58 2008 From: kevork at quantum-qtr.com (Salmastlian, Kevork) Date: Wed, 28 May 2008 16:20:58 -0400 Subject: [tpm] Contract Job Opportunity - Toronto, Canada Message-ID: <5463364E9EFE0342B2518D47A74519CC03B099ED@QGMTB1X.quantum-group.net> Good Afternoon. Just wanted to share an incredible contract opportunity with your group. The details are listed below: 6 Month Contract -Financial Organization - downtown Toronto -Sr. Developer -PERL, C, Java experience -UNIX/Solaris is preferred -Must have: Financial/Brokerage experience -Able to start within 2 weeks Thank you for your time and consideration. Sincerely, Kevork Kevork Salmastlian Group Manager Email: kevork at quantum-qtr.com Tel: 416-366-3660 www.Quantum-qtr.com The content of this e-mail is intended solely for the use of the Individual or entity to whom it is addressed. If you have received this communication in error, be aware that forwarding it, copying it, or in any way disclosing its content to any other person, is strictly prohibited. If you have received this communication in error, please notify the author by replying to this e-mail. ________________________________ -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080528/523b0814/attachment.html -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: image/gif Size: 3774 bytes Desc: image001.gif Url : http://mail.pm.org/pipermail/toronto-pm/attachments/20080528/523b0814/attachment.gif From kwalton at keenconsulting.ca Fri May 30 06:44:26 2008 From: kwalton at keenconsulting.ca (Kim Walton) Date: Fri, 30 May 2008 09:44:26 -0400 Subject: [tpm] PERL Developers and Leads NEEDED Message-ID: <20080530134427.99BF717037D@mail.korax.net> Hi, My name is Kim Walton and I am a technical recruiter for Keen Consulting in Toronto. After exhausting my normal avenues of recruiting, I came across your website of Toronto Perl Mongers. The client I am working with is in need of 2-3 PERL developers and a Technical Lead. I was hoping that there might be professionals within your group either looking for work, or perhaps know of others who are. This industry is all about networking - so if you know anyone who is looking for work please don't hesitate to let me know. We offer a referral bonus here at Keen Consulting, so please feel free to pass on any names of colleagues you think would be interested. The client I am working with is an ecommerce solutions company based in downtown Toronto. These are permanent positions with a salary range of $50-60k for Junior Developers and $70-80k (or above this due to scarcity in the market) for Senior Developers and Leads. I will attach the job description below for your convenience. Please let me know if you are interested. Thanks, Kim JOB DESCRIPTION Position: Perl Web Developer Department: eRetail Services Reporting to: Team Lead, eRetail Services POSITION SUMMARY Novator Systems Ltd. Is looking for an outstanding Perl Web Developer who will play a major role in the development, maintenance, and deployment of the Company's many exciting web-based solutions in a Perl/Apache/Sybase environment. DUTIES AND RESPONSIBILITIES: Feature Specification and Design: * Understand the overall design of Novator's software tools. * Able to read a feature specification and understand how to implement it. * Able to read a software requirement document and produce a technical specification. Planning, Estimating and tracking * Provide reliable time estimates for all development activities. * Provide frequent updates on the status of development activities. * Accurately track time per task Code Implementation * Code to company quality and programming standards * Proactively communicate when aware of potential quality issues. * Build testability into code (i.e. unit tests). * Make proper use of source code control, tickets, and other project tools. * Complete work according to provided software requirements or specification. * Document code both inline and hard copy. Communication and Teamwork * Open communication - seek guidance or advice when needed from senior team members. MINIMUM AND ESSENTIAL SKILLS AND QUALIFICATIONS Education: Bachelor's degree in Computer Science or Computer Engineering, or equivalent. Qualifications: * 3 or more years developing client-server web applications with Perl in a high volume enterprise environment. * Strong proficiency in object oriented Perl and mod_perl is required. * Demonstrable knowledge and experience with the Apache web server and Apache modules. * Excellent knowledge of standard web technologies - HTML, JavaScript, XML, XSLT, AJAX, etc. * Knowledge of database design concepts (Sybase preferred). * Proven experience with Debian or another Linux distribution. * Experience with version control and code sharing systems. * Able to work on several projects simultaneously * Able to work effectively as a member of a team * Excellent communication skills are essential Required Technical Skills: * Perl, mod_perl * Apache * RDBMS (Sybase preferred) * Linux (Debian preferred) * XML, XSLT * Git, CVS * Previous experience working with an Internet ecommerce company an asset Kimberly Walton Technical Recruiter Keen Technology Consulting Inc. 99 Atlantic Avenue, Suite 218 Toronto, ON M6K 3J8 Phone: 416.536.5336 ext. 228 Fax: 416.536.5366 Cell: 905.741.5549 www.keenconsulting.ca -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/toronto-pm/attachments/20080530/ca7f6d68/attachment-0001.html -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: image/jpeg Size: 22392 bytes Desc: not available Url : http://mail.pm.org/pipermail/toronto-pm/attachments/20080530/ca7f6d68/attachment-0001.jpe From adam.prime at utoronto.ca Fri May 30 12:37:46 2008 From: adam.prime at utoronto.ca (adam.prime at utoronto.ca) Date: Fri, 30 May 2008 15:37:46 -0400 Subject: [tpm] May Meeting Tomorrow - Thu 29 May, 2008 - An interpretation of an introduction to mod_perl 2 In-Reply-To: <20080528223725.52cf0422@caliope> References: <20080528223725.52cf0422@caliope> Message-ID: <20080530153746.ki53jt9vvjwc8wsw@webmail.utoronto.ca> Phillipe's slides can be found here: http://gozer.ectoplasm.org/Talks/talks.html Adam Quoting Michael Graham : > > > (These details are also on the TPM web site: http://to.pm.org/) > > The next meeting is this Thursday, 29 May (Tomorrow). > > > Date: Thursday 29 May 2008 > > Time: 6:45pm > > Cost: Free! > > Where: 2 Bloor Street West (NW corner of Yonge/Bloor, skyscraper > with the CIBC logo on top) Classroom 11 on the 8th floor > =================================================================== > > Description: > > Adam is going to go through Phillipe Chaisson's "From CGI to > mod_perl 2.0, Fast!" slides, then follow that up with some of detail > about mod_perl beyond the ResponseHandler phase touching on some > useful, and powerful things that mod_perl can enable you to do. > > > Note: > > The elevators in the building are "locked down" after 5:30pm > to people without building access cards. Leading up to the > meeting someone will come down to the main floor lobby every > few minutes to ferry people upstairs. > > After 19:00, you can reach the access-card-carrying guy via > a cell phone number that we'll leave with security in the > front lobby. The room and floor numbers will be left with > security too. > > > > > -- > Michael Graham > _______________________________________________ > toronto-pm mailing list > toronto-pm at pm.org > http://mail.pm.org/mailman/listinfo/toronto-pm >