From jobs-noreply at seattleperl.org Mon Aug 4 16:14:42 2008 From: jobs-noreply at seattleperl.org (SPUG Jobs) Date: Mon, 4 Aug 2008 16:14:42 -0700 (PDT) Subject: SPUG: JOB: Perl / MySQL Dev, Anti-fraud, Tacoma (2 positions) Message-ID: We currently have two new positions open for Perl/MySQL developers. Our office is located in Tacoma. Perl + MySQL Anti-Fraud development opportunity ----------------------------------------------- Internet Identity is experiencing explosive growth. Perl / MySQL Superstars required to help build upon the world's leading anti-phishing system. This is an excellent opportunity for experienced developers to design and build the next generation of industry leading Anti-Fraud software. Candidates must be able to learn new systems quickly and hit the ground running. Demonstration of sound software design practices and ability work on multiple projects with limited supervision are required. Duties will include: -------------------- * concurrent development using both Perl and PHP, interfacing with MySQL and PostgreSQL database engines. * website development using PHP, MySQL, JavaScript, AJAX * data processing using Perl, MySQL * generating ad hoc reports * development of application specifications integrating input from customers and other departments Requirements: ------------- * Degree in computer science, engineering or equivalent experience * 3+ years work experience with Perl on UNIX/Linux * 2+ years work experience with MySQL on UNIX/Linux * 1+ years work experience with PHP on UNIX/Linux * Solid understanding of HTML/CSS Bonus Experience: ----------------- * Familiarity with the 'Agile Development' philosophy * PostgreSQL * IP Networking * DNS/BIND * AJAX * Ruby * Java Pay, Benefits & Work Schedule: ------------------------------ This is a full time position with competitive compensation and benefits, located in Tacoma's financial district. Flexible work schedule for the right candidates. Company Information: -------------------- Internet Identity is focused on helping financial services, e-commerce and internet services companies protect their users against phishing and other forms of online fraud. We provide low cost, high value phishing readiness and response services that enable all companies -- from the smallest community banks to the largest ISPs -- to protect their customers. How to Apply: ------------- Send resume and cover letter to: careers at internetidentity.com Place 'Software Developer' in the title. From choward at indicium.us Sat Aug 9 18:45:20 2008 From: choward at indicium.us (Christopher Howard) Date: Sat, 09 Aug 2008 17:45:20 -0800 Subject: SPUG: Independent project Message-ID: <489E4830.2050706@indicium.us> An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: choward.vcf Type: text/x-vcard Size: 160 bytes Desc: not available URL: From jwkrahn at shaw.ca Sat Aug 9 23:41:50 2008 From: jwkrahn at shaw.ca (John W. Krahn) Date: Sat, 09 Aug 2008 23:41:50 -0700 Subject: SPUG: Independent project In-Reply-To: <489E4830.2050706@indicium.us> References: <489E4830.2050706@indicium.us> Message-ID: <489E8DAE.9030701@shaw.ca> Christopher Howard wrote: > Hello. Hello, > I was wondering if a few of you would be willing to do me a favor. I'm > creating this personal website as part of an independent project toward my > Associates degree: > > www.indicium.us > > The basic idea of the project is for me to learn Perl by coding an entire > personal website out of Perl scripts (my own work, mostly). The site is meant > to have a variety of content to interest the web visitor, including interactive > programs and downloads. The site is not very impressive yet (we all have to > start somewhere!) but I'm slowly working to make it more attractive, > interesting, and useful. > > There is a site blog (accessible from the front page) that details my > experiences in coding the site. If you want to help out, all you have to do is > subscribe to the blog's RSS feed, watch the posts, and drop in a comment when > ever you feel like it. > > Thanks in advance. On your "Links" page you have a link to "Rex Swain's HTMLified Perl 5 Reference". This site has so many errors in it that I couldn't get past the "Operators" section. Why don't you just link to the actual Perl documentation at http://perldoc.perl.org/? As to your "hrefined" code, most of it looks OK except for "modules/database.pm": 67 my $currentlink = @{$links}[$currentvalue]; 168 my $file = @_[1]; 214 my $currentcategory = @{$categories}[$currentvalue]; You are using a slice to access a scalar value. Those lines should be: 67 my $currentlink = $links->[$currentvalue]; 168 my $file = $_[1]; 214 my $currentcategory = $categories->[$currentvalue]; If you had enabled warnings then perl would have informed you of this. Also in "modules/interface.pm" you have "use strict" twelve times. "use" happens at compile time and after the first strict pragma is compiled in the next eleven ones are ignored. While there are a few other quirks or inconsistencies that I would change if it were my code, that's enough for now. :-) John -- Perl isn't a toolbox, but a small machine shop where you can special-order certain sorts of tools at low cost and in short order. -- Larry Wall From choward at indicium.us Sun Aug 10 17:20:00 2008 From: choward at indicium.us (Christopher Howard) Date: Sun, 10 Aug 2008 16:20:00 -0800 Subject: SPUG: Independent project In-Reply-To: <489E8DAE.9030701@shaw.ca> References: <489E4830.2050706@indicium.us> <489E8DAE.9030701@shaw.ca> Message-ID: <489F85B0.1060106@indicium.us> An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: choward.vcf Type: text/x-vcard Size: 140 bytes Desc: not available URL: From ryanc at greengrey.org Mon Aug 11 11:45:24 2008 From: ryanc at greengrey.org (Ryan Corder) Date: Mon, 11 Aug 2008 11:45:24 -0700 Subject: SPUG: Independent project In-Reply-To: <489F85B0.1060106@indicium.us> References: <489E4830.2050706@indicium.us> <489E8DAE.9030701@shaw.ca> <489F85B0.1060106@indicium.us> Message-ID: <20080811184524.GA23478@greengrey.org> First off, sorry for the top post. I think it is obvious based on the content below. Secondly, can you please not send HTML email to the list? thanks. ryanc On Sun, Aug 10, 2008 at 04:20:00PM -0800, Christopher Howard wrote: | | | | | | | | John W. Krahn wrote: |
Christopher | Howard wrote: |
|
Hello. |
|
|
| Hello, |
|
|
I was wondering if a few of you would be | willing to do me a favor.  I'm creating this personal website as part | of an independent project toward my Associates degree: |
|
| www.indicium.us <http://www.indicium.us> |
|
| The basic idea of the project is for me to learn Perl by coding an | entire personal website out of Perl scripts (my own work, mostly).  The | site is meant to have a variety of content to interest the web visitor, | including interactive programs and downloads.  The site is not very | impressive yet (we all have to start somewhere!) but I'm slowly working | to make it more attractive, interesting, and useful. |
|
| There is a site blog (accessible from the front page) that details my | experiences in coding the site.  If you want to help out, all you have | to do is subscribe to the blog's RSS feed, watch the posts, and drop in | a comment when ever you feel like it. |
|
| Thanks in advance. |
|
|
| On your "Links" page you have a link to "Rex Swain's HTMLified Perl 5 | Reference".  This site has so many errors in it that I couldn't get | past the "Operators" section.  Why don't you just link to the actual | Perl documentation at http://perldoc.perl.org/? |
|
| As to your "hrefined" code, most of it looks OK except for | "modules/database.pm": |
|
|      67     my $currentlink = @{$links}[$currentvalue]; |
|
|     168     my $file = @_[1]; |
|
|     214     my $currentcategory = @{$categories}[$currentvalue]; |
|
| You are using a slice to access a scalar value.  Those lines should be: |
|
|      67     my $currentlink = $links->[$currentvalue]; |
|
|     168     my $file = $_[1]; |
|
|     214     my $currentcategory = $categories->[$currentvalue]; |
|
| If you had enabled warnings then perl would have informed you of this. |
|
| Also in "modules/interface.pm" you have "use strict" twelve times. | "use" happens at compile time and after the first strict pragma is | compiled in the next eleven ones are ignored. |
|
| While there are a few other quirks or inconsistencies that I would | change if it were my code, that's enough for now.  :-) |
|
|
|
| John |
|
|

Thank you.  Feel free to point out any other quirks or | inconsistencies that you notice, even if it makes me look like a real | newbie.  Pretty much everything I know about Perl is from a few | tutorials here and there, so I could use all the peer review I can get.

|

If you ever want to suggest better programming practices, good | tutorials, and that sort of thing, feel free to drop me a note anytime, | especially as a comment on my blog (it's | sort of a journal for the project).

| | | begin:vcard | fn:Christopher Howard | n:Howard;Christopher | email;internet:choward at indicium.us | url:http://www.indicium.us | version:2.1 | end:vcard | | _____________________________________________________________ | Seattle Perl Users Group Mailing List | POST TO: spug-list at pm.org | SUBSCRIPTION: http://mail.pm.org/mailman/listinfo/spug-list | MEETINGS: 3rd Tuesdays | WEB PAGE: http://seattleperl.org/ From andrew at sweger.net Mon Aug 11 15:53:59 2008 From: andrew at sweger.net (Andrew Sweger) Date: Mon, 11 Aug 2008 15:53:59 -0700 (PDT) Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: <20080811184524.GA23478@greengrey.org> Message-ID: There is an option in this list server to have it convert text/html to plain text. There are also options to remove various attachments (many options). Is there general interest from the members to employ these features? Any questions? Debate? On Mon, 11 Aug 2008, Ryan Corder wrote: > Secondly, can you please not send HTML email to the list? -- Andrew B. Sweger -- The great thing about multitasking is that several things can go wrong at once. From ann at domaintje.com Mon Aug 11 16:25:53 2008 From: ann at domaintje.com (Ann Barcomb) Date: Mon, 11 Aug 2008 16:25:53 -0700 (PDT) Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: References: Message-ID: > There is an option in this list server to have it convert text/html to > plain text. There are also options to remove various attachments (many > options). > > Is there general interest from the members to employ these features? Any > questions? Debate? I just delete mail with HTML in it, provided my spam filter doesn't get it (it's set to stun, not kill, HTML, but it only takes a few poorly chosen words to slide over the line). So I'm indifferent as to whether the list server makes the conversion. - Ann From bill at celestial.com Mon Aug 11 17:10:14 2008 From: bill at celestial.com (Bill Campbell) Date: Mon, 11 Aug 2008 17:10:14 -0700 Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: References: <20080811184524.GA23478@greengrey.org> Message-ID: <20080812001014.GA6067@ayn.mi.celestial.com> On Mon, Aug 11, 2008, Andrew Sweger wrote: >There is an option in this list server to have it convert text/html to >plain text. There are also options to remove various attachments (many >options). > >Is there general interest from the members to employ these features? Any >questions? Debate? While I much prefer plain-text, I don't enforce that on any of the mailing lists we host as it can cause problems with some folk's mailers. A genealogy list I'm on on rootsweb strips all html, and there's at least one person on the list running a version of AOL's software so old it can only send html-only. We use Spamassassin with Mailman, and messages with html content consistently get high scores with html-only messages almost certain to be forwarded to the moderator(s) for approval. People posting html to the list should be advised that their messages may be held for approval, and that can take a while depending on how busy the moderator is. FWIW, while Mailman has an option to send a message to the sender when messages are held for moderation (off by default), I would not enable this feature as it can either give spammers useful information or result in blowback to forged From: or Sender: addresses. Bill -- INTERNET: bill at celestial.com Bill Campbell; Celestial Software LLC URL: http://www.celestial.com/ PO Box 820; 6641 E. Mercer Way Voice: (206) 236-1676 Mercer Island, WA 98040-0820 Fax: (206) 232-9186 A tax-supported, compulsory educational system is the complete model of the totalitarian state. -- Isabel Paterson, God of the Machine From jobs-noreply at seattleperl.org Mon Aug 11 17:30:19 2008 From: jobs-noreply at seattleperl.org (SPUG Jobs) Date: Mon, 11 Aug 2008 17:30:19 -0700 (PDT) Subject: SPUG: Perl/Bash/LabView - 8 wk contract - Redmond Message-ID: Skill Set Requirements: - Intermediate to expert Perl or Bash Programmer - Intermediate to expert LabView Programmer - Experience with software build processes - Experience with automation for manufacturing tests - Experience with telnet and other standard communication interfaces * Contract, 6-8 weeks, $40-$50/hr, via recruiter * 1099, no restrictions * Located in Redmond * telecommuting possible? Possibly :-) * company's product or service: Wireless Communication Description of Services The vendor will undertake the development of Perl/Bash based scripts and LabView programming in support of the Client's test project. Specific modules will be assigned by the project lead. The basic task descriptions and responsibilities are as follows. Task Description 1 Develop and debug Perl/Bash scripts to create an ISO image. 2 Develop and debug a Server Boot CD using Perl/Bash. . Boot SuSE OS on the server . Configure the server for network access . Downloads the proper ISO Image to the server . Perform the necessary configuration steps on the server. . Communicates to the Test Computer status and progress. 3 Develop and debug LabView modules that monitor the Server progress. 4 Participate in integration of the test suite. 5 Participate in meetings to discuss development work. 6 Document development work. Please get in touch with me if you are interested or have questions. It is desirable that the project start date be as soon as possible. Crescent Luhman From andrew at sweger.net Mon Aug 11 17:51:42 2008 From: andrew at sweger.net (Andrew Sweger) Date: Mon, 11 Aug 2008 17:51:42 -0700 (PDT) Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: <20080812001014.GA6067@ayn.mi.celestial.com> Message-ID: On Mon, 11 Aug 2008, Bill Campbell wrote: > We use Spamassassin with Mailman, and messages with html content > consistently get high scores with html-only messages almost > certain to be forwarded to the moderator(s) for approval. People > posting html to the list should be advised that their messages > may be held for approval, and that can take a while depending on > how busy the moderator is. FWIW, while Mailman has an option to > send a message to the sender when messages are held for > moderation (off by default), I would not enable this feature as > it can either give spammers useful information or result in > blowback to forged From: or Sender: addresses. This list rejects senders who are not subscribed. And newly subscribed senders are moderated. I don't think senders are notified when a message is held for moderation. All in all, spam almost never makes it to this list and I've never seen a spammer subscribe to the list. Once in a while I'll get uncaught (unparseable) bounce notifications forwarded to me, but they have all been spam that managed to slip through Ask's gauntlet. Turning on the HTML conversion option shouldn't cause any client trouble for receivers as it would all be converted to text. The biggest problem I think might be how the HTML will get mangled into text that might not read very well. I would say I'm in favor of having the list automatically convert HTML attachments to text (assuming it does so with acceptable results). Disclaimer: I'm one of those old farts that still does ALL of his email on a 80x25 terminal. I'm naturally biased. -- Andrew B. Sweger -- The great thing about multitasking is that several things can go wrong at once. From mail.spammagnet at gmail.com Mon Aug 11 21:39:26 2008 From: mail.spammagnet at gmail.com (BenRifkah Bergsten-Buret) Date: Mon, 11 Aug 2008 21:39:26 -0700 Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: References: <20080811184524.GA23478@greengrey.org> Message-ID: On Mon, Aug 11, 2008 at 3:53 PM, Andrew Sweger wrote: > > Is there general interest from the members to employ these features? Any > questions? Debate? > It sounds like it's probably an unpopular opinion, but I find judicious use of HTML email extremely useful. This mostly comes in handy for my co-workers and users I support. HTMLified lists of instructions/action items, bold face for peoples names, and hiding lengthy URL noise behind a couple of linked words have all been extremely helpful. I've also found it helpful on technical lists for formatting command lines and code snippets in fixed width fonts, and especially for highlighting subtle differences when helping people with bugs. Aside from obvious (for this list) misuses that hinder readability - such as fancy tiled backgrounds and cutesy fonts - my only peeve is not with HTML email but with the mail clients. Many clients mangle HTML when displaying, replying and forwarding. This can render can affect any HTML email, even messages that use it sparingly. But in my mind the solution is not to ban HTML because the clients don't handle it well. This would be like banning guns because a lot of people misuse them, or banning Perl because many of its users write line noise. References: <20080811184524.GA23478@greengrey.org> Message-ID: <20080812051301.GS32693@ifokr.org> At almost 2008-08-11 21:39 -0700, BenRifkah Bergsten-Buret voiced: > I've also found it helpful on technical lists for formatting command > lines and code snippets in fixed width fonts, and especially for > highlighting subtle differences when helping people with bugs. My ASCII mailer always does fixed width fonts. Sounds like this HTML thing is a real step backwards. ;-) > If we're going to ban HTML because it's easier for clients to parse > then we might as well change the list focus to Python because it's > easier for minds to parse. If there are no curlies on which I can bounce with my % key in vi, it isn't a real language. -- Brian Hatch "You don't get 'sysadmin day', you have Systems and your own holiday, network boy!" Security Engineer "What, the "Kick my ass because http://www.ifokr.org/bri/ I'm your bitch" day? --Jason and Casey Every message PGP signed -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 189 bytes Desc: Digital signature URL: From bill at celestial.com Mon Aug 11 22:23:56 2008 From: bill at celestial.com (Bill Campbell) Date: Mon, 11 Aug 2008 22:23:56 -0700 Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: <20080812051301.GS32693@ifokr.org> References: <20080811184524.GA23478@greengrey.org> <20080812051301.GS32693@ifokr.org> Message-ID: <20080812052356.GA1822@ayn.mi.celestial.com> On Mon, Aug 11, 2008, Brian Hatch wrote: >At almost 2008-08-11 21:39 -0700, BenRifkah Bergsten-Buret voiced: > >> I've also found it helpful on technical lists for formatting command >> lines and code snippets in fixed width fonts, and especially for >> highlighting subtle differences when helping people with bugs. > >My ASCII mailer always does fixed width fonts. Sounds like this >HTML thing is a real step backwards. Agreed. >;-) > >> If we're going to ban HTML because it's easier for clients to parse >> then we might as well change the list focus to Python because it's >> easier for minds to parse. > >If there are no curlies on which I can bounce with my % key in vi, >it isn't a real language. The way I write python (and bash) is to comment curly braces if condition: #{{ # do something here #} elif something else: #{ # more stuff #} else: #{ # finally something else #}} Yes, it would make a pythonista puke :-). Bill -- INTERNET: bill at celestial.com Bill Campbell; Celestial Software LLC URL: http://www.celestial.com/ PO Box 820; 6641 E. Mercer Way Voice: (206) 236-1676 Mercer Island, WA 98040-0820 Fax: (206) 232-9186 Blessed are the young, for they shall inherit the national debt. -- Herbert Hoover From ryanc at greengrey.org Mon Aug 11 23:11:33 2008 From: ryanc at greengrey.org (Ryan Corder) Date: Mon, 11 Aug 2008 23:11:33 -0700 Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: References: <20080812001014.GA6067@ayn.mi.celestial.com> Message-ID: <20080812061133.GA3988@greengrey.org> On Mon, Aug 11, 2008 at 05:51:42PM -0700, Andrew Sweger wrote: | Disclaimer: I'm one of those old farts that still does ALL of his email on | a 80x25 terminal. I'm naturally biased. Same here and equally as biased, hence the original complaint :) From choward at indicium.us Wed Aug 13 09:06:29 2008 From: choward at indicium.us (Christopher Howard) Date: Wed, 13 Aug 2008 12:06:29 -0400 Subject: SPUG: dealing with HTML on list In-Reply-To: References: Message-ID: <48A30685.6070109@indicium.us> Andrew Sweger wrote: > There is an option in this list server to have it convert text/html to > plain text. There are also options to remove various attachments (many > options). > > Is there general interest from the members to employ these features? Any > questions? Debate? > > On Mon, 11 Aug 2008, Ryan Corder wrote: > > >> Secondly, can you please not send HTML email to the list? >> > > Hmm, it looks like I inadvertently opened a can of worms. I love HTML e-mail, and I use it all the time. I love the ordered lists, unordered lists, tables, and styles. However, if that many of you hate HTML e-mail, then I would vote in favor of the tool that automatically converts HTML to text. That would save me (and future new members) the bother of having to remember that we shouldn't send HTML to this list. I'm not sure how your conversion program works, but the converting tools I've seen on other lists seem to do a fairly good job of representing the authors intentions. Note: If possible, could you configure the tool to allow attachments? It is rather annoying how attachments get stripped out on other lists. From cos at indeterminate.net Wed Aug 13 13:38:08 2008 From: cos at indeterminate.net (John Costello) Date: Wed, 13 Aug 2008 13:38:08 -0700 (PDT) Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: Message-ID: On Mon, 11 Aug 2008, Andrew Sweger wrote: > There is an option in this list server to have it convert text/html to > plain text. There are also options to remove various attachments (many > options). > > Is there general interest from the members to employ these features? Any > questions? Debate? Pine handles HTML emails pretty well from my terminal shell, so I fall into the "I don't care either way" camp as far as format conversion. I can see a few good reasons for blocking attachments. I think it was on this list that someone accidentally sent a copy of a binary that they didn't want released, and it would trim the (apparently already small) possibility of viruses spreading through the list. Since this is a perl list, I'd assume people can paste perl scripts into thei text emails. No strong feeling on this, however. From cos at indeterminate.net Wed Aug 13 13:39:48 2008 From: cos at indeterminate.net (John Costello) Date: Wed, 13 Aug 2008 13:39:48 -0700 (PDT) Subject: SPUG: dealing with HTML on list (was: Independent project) In-Reply-To: Message-ID: On Mon, 11 Aug 2008, Andrew Sweger wrote: > Disclaimer: I'm one of those old farts that still does ALL of his email on > a 80x25 terminal. I'm naturally biased. I think you meant "naturally blessed." That's how I originally read your sentence. (Also on 80x25.) ---- Today is a good day to turn off the computer and read a book. From bill at celestial.com Wed Aug 13 14:38:52 2008 From: bill at celestial.com (Bill Campbell) Date: Wed, 13 Aug 2008 14:38:52 -0700 Subject: SPUG: dealing with HTML on list In-Reply-To: <48A30685.6070109@indicium.us> References: <48A30685.6070109@indicium.us> Message-ID: <20080813213852.GA21879@ayn.mi.celestial.com> On Wed, Aug 13, 2008, Christopher Howard wrote: > Andrew Sweger wrote: >> There is an option in this list server to have it convert text/html to >> plain text. There are also options to remove various attachments (many >> options). >> >> Is there general interest from the members to employ these features? Any >> questions? Debate? >> >> On Mon, 11 Aug 2008, Ryan Corder wrote: >> >>> Secondly, can you please not send HTML email to the list? >> > Hmm, it looks like I inadvertently opened a can of worms. > > I love HTML e-mail, and I use it all the time. I love the ordered > lists, unordered lists, tables, and styles. I do lists and tables with mutt by writing the e-mail in vim with groff markup, then filtering that to convert to plain text. I find this much faster than dealing with GUI editors. > However, if that many of you hate HTML e-mail, then I would vote in > favor of the tool that automatically converts HTML to text. That would > save me (and future new members) the bother of having to remember that > we shouldn't send HTML to this list. > > I'm not sure how your conversion program works, but the converting tools > I've seen on other lists seem to do a fairly good job of representing > the authors intentions. > > Note: If possible, could you configure the tool to allow attachments? > It is rather annoying how attachments get stripped out on other lists. I don't filter attachments from the lists we host, but do have a strict 40k message size limit. I can understand why one would want to strip attachments since it's impossible to keep people from using the Microsoft Virus, Windows which is susceptible to all sorts of nastiness in attachments. I *REALLY* like the way the IMP webmail client allows one to handle attachments as URLs in the message, and automatically copies the attachments to the web server. This keeps the e-mail messages small, and the user has only to click on the URL to get the attachment. Bill -- INTERNET: bill at celestial.com Bill Campbell; Celestial Software LLC URL: http://www.celestial.com/ PO Box 820; 6641 E. Mercer Way Voice: (206) 236-1676 Mercer Island, WA 98040-0820 Fax: (206) 232-9186 Property must be secured, or liberty cannot exist. -- John Adams From cmeyer at helvella.org Fri Aug 15 07:54:44 2008 From: cmeyer at helvella.org (Colin Meyer) Date: Fri, 15 Aug 2008 07:54:44 -0700 Subject: SPUG: Meeting Announcement -- 19 August 2008 Message-ID: <20080815145444.GD1219@infula.helvella.org> August 2008 Seattle Perl Users Group (SPUG) Meeting ==================================================== Topic: Beginning Perl, Practical Steps Speaker: Colin Meyer Meeting Date: Tuesday, 19 August 2008 Meeting Time: 6:30 - 8:30 p.m. Location: Marchex - 4th & Pine Cost: Admission is free and open to the public Info: http://seattleperl.org/ ==================================================== Tuesday, August 19th, is the next meeting of the THE SEATTLE PERL USERS GROUP. This month Colin Meyer will give an entry level Perl talk, about using File::Find, and making a practical little program. He will lead through the thoughts and organization of developing a utility to find mp3 files that are the same song. Colin has been using Perl since 1994 and has been a SPUG member since the second meeting. He is a Co-Founder at MarketOutsider.com, a financial news analysis service. Pre-Meeting ================ If you are so inclined, please come to the pre-meeting at the Elephant & Castle pub on 5th & Union. We'll be there from 5-6:19PM. Meeting Location ================ Pizza and Beer will be provided at the meeting. Marchex 413 Pine St, Suite 500 Seattle, WA 98101 Contact: Jackie Wolfstone - 206-491-8072 The building is just south of Westlake Center. Enter on 4th Avenue, near Pine street. The entry is near the Dog In The Park hotdog stand. http://www.baylis.org/static/marchex.png Due to all of the shopping around us there is plenty of parking available in garages, but it can be hard to find street parking in the evening. See you there! From jarich at perltraining.com.au Mon Aug 18 05:29:44 2008 From: jarich at perltraining.com.au (Jacinta Richardson) Date: Mon, 18 Aug 2008 22:29:44 +1000 Subject: SPUG: dealing with HTML on list In-Reply-To: References: <20080811184524.GA23478@greengrey.org> Message-ID: <48A96B38.60907@perltraining.com.au> BenRifkah Bergsten-Buret wrote: > it well. This would be like banning guns because a lot of people > misuse them Off-topic I know, but I'm all for banning guns exactly because "a lot of people misuse them". ;) J -- ("`-''-/").___..--''"`-._ | Jacinta Richardson | `6_ 6 ) `-. ( ).`-.__.`) | Perl Training Australia | (_Y_.)' ._ ) `._ `. ``-..-' | +61 3 9354 6001 | _..`--'_..-_/ /--'_.' ,' | contact at perltraining.com.au | (il),-'' (li),' ((!.-' | www.perltraining.com.au | From cmeyer at helvella.org Mon Aug 18 16:38:36 2008 From: cmeyer at helvella.org (Colin Meyer) Date: Mon, 18 Aug 2008 16:38:36 -0700 Subject: SPUG: Meeting Announcement -- 19 August 2008 In-Reply-To: <20080815145444.GD1219@infula.helvella.org> References: <20080815145444.GD1219@infula.helvella.org> Message-ID: <20080818233836.GB25474@infula.helvella.org> Reminder, our next monthly SPUG meeting is tomorrow, Tuesday, 8/19. -Colin. On Fri, Aug 15, 2008 at 07:54:44AM -0700, Colin Meyer wrote: > August 2008 Seattle Perl Users Group (SPUG) Meeting > ==================================================== > > Topic: Beginning Perl, Practical Steps > Speaker: Colin Meyer > Meeting Date: Tuesday, 19 August 2008 > Meeting Time: 6:30 - 8:30 p.m. > Location: Marchex - 4th & Pine > > Cost: Admission is free and open to the public > Info: http://seattleperl.org/ > > ==================================================== > > Tuesday, August 19th, is the next meeting of the THE SEATTLE PERL > USERS GROUP. > > This month Colin Meyer will give an entry level Perl talk, about using > File::Find, and making a practical little program. He will lead through > the thoughts and organization of developing a utility to find mp3 files > that are the same song. > > Colin has been using Perl since 1994 and has been a SPUG member since > the second meeting. He is a Co-Founder at MarketOutsider.com, a > financial news analysis service. > > Pre-Meeting > ================ > > If you are so inclined, please come to the pre-meeting at the Elephant & > Castle pub on 5th & Union. We'll be there from 5-6:19PM. From choward at indicium.us Mon Aug 25 12:36:21 2008 From: choward at indicium.us (Christopher Howard) Date: Mon, 25 Aug 2008 11:36:21 -0800 Subject: SPUG: Question -- use vs require Message-ID: <48B309B5.30605@indicium.us> Hi. I was hoping someone could clarify some small points for me. I read some on-line material, but I want to make sure I'm understanding things correctly. 1. What is the difference between 'use' and 'require'? 2. What is the advantage to using 'require' (if there is one)? 3. What are the implications for object-oriented programming? Thanks for your time. From trey+spug at lopsa.org Mon Aug 25 12:47:45 2008 From: trey+spug at lopsa.org (Trey Harris) Date: Mon, 25 Aug 2008 15:47:45 -0400 (EDT) Subject: SPUG: Question -- use vs require In-Reply-To: <48B309B5.30605@indicium.us> References: <48B309B5.30605@indicium.us> Message-ID: In a message dated Mon, 25 Aug 2008, Christopher Howard writes: > Hi. I was hoping someone could clarify some small points for me. I read > some on-line material, but I want to make sure I'm understanding things > correctly. > 1. What is the difference between 'use' and 'require'? % perldoc -f use [...] It is exactly equivalent to BEGIN { require Module; import Module LIST; } except that Module must be a bareword. > 2. What is the advantage to using 'require' (if there is one)? "The advantage" makes it sound like you should be preferring it; you shouldn't. 99%+ of the time, you want C. You can use C in a string eval so the load happens at runtime rather than compile time (that's what the C block is doing up there). You can also use C to prevent the C method from being called (though ordinarily this isn't something you want to do, you should do a C instead to call C with no arguments). > 3. What are the implications for object-oriented programming? That's a very broad question, but I don't think there are any implications of use vs. require for OOP versus any other type of programming. -- Trey Harris http://www.lopsa.org/ President, LOPSA -- The League of Professional System Administrators Opinions expressed above are not necessarily those of LOPSA. From tyemq at cpan.org Mon Aug 25 20:55:31 2008 From: tyemq at cpan.org (Tye McQueen) Date: Mon, 25 Aug 2008 20:55:31 -0700 Subject: SPUG: Fwd: Question -- use vs require In-Reply-To: References: <48B309B5.30605@indicium.us> Message-ID: gmail hiding "reply to all" often leads to me forgetting that I need to use that... ---------- Forwarded message ---------- From: Tye McQueen Date: Mon, Aug 25, 2008 at 8:53 PM Subject: Re: SPUG: Question -- use vs require To: Trey Harris > On Mon, Aug 25, 2008 at 12:47 PM, Trey Harris > wrote: > "The advantage" makes it sound like you should be preferring it; you > shouldn't. 99%+ of the time, you want C. > Well, I think the "99%+" figure is overstated. 'require' is perfectly appropriate in quite a few situations and is preferred in quite a few more-advanced situations. But, yes, if you are unsure which to use, 'use' is the way to go. It is rarely the case that replacing 'require' with 'use' will cause you problems (it can cause problems, but it /usually/ doesn't, especially for basic uses) and the reverse is not true (if you have code using 'use', it will often be because 'use' is required and switching to 'require' is likely to break things). > You can use C in a string eval so the load happens at runtime > rather than compile time No. Simply using 'require' is enough to make the loading happen at run-time. You can also use 'use' in a /string/ eval in order to get the loading and importing to happen at run-time but that also opens up lots of potential problems so it is a technique that should not be used lightly. > You can also use C to prevent the C method from being > called (though ordinarily this isn't something you want to do, you should do > a C instead to call C with no arguments). Actually, qw() like that prevents import() from being called at all. To call import() with no arguments, write simply 'use Module;'. And rather than just stating that 'require' should be avoided, I'll provide reasons why one might or might not want to avoid it. :) > 3. What are the implications for object-oriented programming? >> > > That's a very broad question, but I don't think there are any implications > of use vs. require for OOP versus any other type of programming. I would say that it is unusual for an OO module to export things so it is rare to have an OO module where 'require' is not sufficient. So, for a /typical/ OO module, there is very little difference between 'use'ing it vs. 'require'ing it. Even loading at compile-time vs. run-time makes little difference in a typical case with an OO module because the 'require' is usually unconditionally executed near the very top of the requiring script/module. "perl -c" is one of the rare cases where you would see a difference ("perl -c" will check the syntax of any modules you 'use', but not of any modules you 'require'). If you have compile-time code below that makes use of the module, than you should certainly 'use' the module. Oh, let's not forget the "obvious" case: If you import symbols/behaviors from the module, then you need to 'use' the module. There are certainly plenty of advanced situations where 'require' is a better choice than 'use'. For the basic situations, the main reason I would use 'require' is to make it clear that none of the syntax that follows is dependent on the module. One only slightly advanced situations where 'require' can be beneficial is when you have rarely-used part(s) of your code that are the only places where some heavy-weight module is needed. In those situations, it may be worth using 'require' inside of the routine(s) that need the module so that the many runs that don't exercise those features won't need to waste time even loading the unutilized module. Tye -------------- next part -------------- An HTML attachment was scrubbed... URL: From choward at indicium.us Tue Aug 26 02:34:06 2008 From: choward at indicium.us (Christopher Howard) Date: Tue, 26 Aug 2008 01:34:06 -0800 Subject: SPUG: Incorrect subtraction result Message-ID: <48B3CE0E.9000303@indicium.us> Hello. I was hoping someone might help me figure what is wrong with some code I wrote. I wrote this class, and I gave it a member function that is designed to act as a change calculator. That is, I pass it the total value of the purchase and the amount of money the (virtual) customer gave me, and it calculates how much of each kind of change to give (dollars, quarters, dimes, etc.) However, when I test it with the values 5.87 and 20.63 (meaning 14.76 of change is needed), I get a strange math error. Here is some debugging results: Starting amount: 14.76 Value of currency unit: 10 Amount remaining after subtraction: 4.76 Value of currency unit: 1 Amount remaining after subtraction: 3.76 Value of currency unit: 1 Amount remaining after subtraction: 2.76 Value of currency unit: 1 Amount remaining after subtraction: 1.76 Value of currency unit: 1 Amount remaining after subtraction: 0.759999999999998 Value of currency unit: 0.25 Amount remaining after subtraction: 0.509999999999998 Value of currency unit: 0.25 Amount remaining after subtraction: 0.259999999999998 Value of currency unit: 0.25 Amount remaining after subtraction: 0.00999999999999801 As you can see, after 1 is subtracted from 1.76, the result is 0.759999999999998 (not good for my program). I ran this on another Linux system, and the results were the same. Here is the class itself (released under GPLv3): package ChangeCalculator; sub new { $self = { UNITS=>[ 20, 10, 5, 1, 0.25, 0.1, 0.05, 0.01 ] }; bless $self, 'ChangeCalculator'; return $self; } #array calculate(scalar, scalar) sub calculate { my $self = shift; my $amtOwed = $_[1] - $_[0]; print "Starting amount: ", $amtOwed, "\n"; #for debugging my @results; foreach(@{$self->{UNITS}}) { my $unitValue = $_; my $timesUsed = 0; until($amtOwed<$unitValue) { print "Value of currency unit: ", $unitValue, "\n"; #for debugging $timesUsed++; $amtOwed = $amtOwed - $unitValue; print "Amount remaining after subtraction: ", $amtOwed, "\n"; #for debugging } push @results, [$unitValue, $timesUsed]; } return @results; } 1; And here is the script used to test it: #!/usr/bin/env perl use strict; use warnings; use ChangeCalculator; my $cc = new ChangeCalculator; my @test = $cc->calculate(5.87, 20.63); Thank you for any time you would be willing to give looking this over. I can't seem to figure out what I have done wrong. Does this have something to do with the way Perl handles data types? From schuh at farmdale.com Tue Aug 26 02:50:43 2008 From: schuh at farmdale.com (Mike Schuh) Date: Tue, 26 Aug 2008 02:50:43 -0700 (PDT) Subject: SPUG: Incorrect subtraction result In-Reply-To: <48B3CE0E.9000303@indicium.us> References: <48B3CE0E.9000303@indicium.us> Message-ID: On Tue, 26 Aug 2008, Christopher Howard wrote: >I was hoping someone might help me figure what is wrong with >some code I wrote. The quick and simple answer is "don't use floating point numbers to represent money". Currency transactions need to track pennies as though they were integers, not 0.01. Why not use floating point values? What is the binary representation of 0.01? Well, it can't be exactly described in binary, so there will always be some sort of round off error when adding and subtracting pennies. Solutions: Use integer pennies, dividing by 100 when displaying the values as dollars (and use the integer pragma). There are also binary coded decimal techniques. Good luck! -- Mike Schuh - Seattle, Washington USA http://www.farmdale.com From ben at reser.org Tue Aug 26 03:09:29 2008 From: ben at reser.org (Ben Reser) Date: Tue, 26 Aug 2008 03:09:29 -0700 Subject: SPUG: Incorrect subtraction result In-Reply-To: <48B3CE0E.9000303@indicium.us> References: <48B3CE0E.9000303@indicium.us> Message-ID: On Tue, Aug 26, 2008 at 2:34 AM, Christopher Howard wrote: > Hello. I was hoping someone might help me figure what is wrong with some code I wrote. I wrote this class, and I gave it a member function that is designed to act as a change calculator. That is, I pass it the total value of the purchase and the amount of money the (virtual) customer gave me, and it calculates how much of each kind of change to give (dollars, quarters, dimes, etc.) > > However, when I test it with the values 5.87 and 20.63 (meaning 14.76 of change is needed), I get a strange math error. > > Here is some debugging results: > Starting amount: 14.76 > Value of currency unit: 10 > Amount remaining after subtraction: 4.76 > Value of currency unit: 1 > Amount remaining after subtraction: 3.76 > Value of currency unit: 1 > Amount remaining after subtraction: 2.76 > Value of currency unit: 1 > Amount remaining after subtraction: 1.76 > Value of currency unit: 1 > Amount remaining after subtraction: 0.759999999999998 > Value of currency unit: 0.25 > Amount remaining after subtraction: 0.509999999999998 > Value of currency unit: 0.25 > Amount remaining after subtraction: 0.259999999999998 > Value of currency unit: 0.25 > Amount remaining after subtraction: 0.00999999999999801 > > As you can see, after 1 is subtracted from 1.76, the result is 0.759999999999998 (not good for my program). I ran this on another Linux system, and the results were the same. Strongly recommend reading: http://perldoc.perl.org/perlnumber.html#Numeric-operators-and-numeric-conversions However, the problem is you're using print and giving it a floating point value when it's expecting a string. So perl implicitly converts the floating point to a string. However, this causes a loss in precision that you don't desire. So the problem isn't in the calculation but your output. The following diff will fix the problem: --- ChangeCalculator.pm~ 2008-08-26 03:06:59.000000000 -0700 +++ ChangeCalculator.pm 2008-08-26 03:00:41.000000000 -0700 @@ -13,10 +13,10 @@ my $unitValue = $_; my $timesUsed = 0; until($amtOwed<$unitValue) { - print "Value of currency unit: ", $unitValue, "\n"; #for debugging + printf "Value of currency unit: %.2f\n", $unitValue; #for debugging $timesUsed++; $amtOwed = $amtOwed - $unitValue; - print "Amount remaining after subtraction: ", $amtOwed, "\n"; #for debugging + printf "Amount remaining after subtraction: %.2f\n", $amtOwed; #for debugging } push @results, [$unitValue, $timesUsed]; } From haircut at gmail.com Tue Aug 26 06:31:54 2008 From: haircut at gmail.com (Adam Monsen) Date: Tue, 26 Aug 2008 08:31:54 -0500 Subject: SPUG: Incorrect subtraction result In-Reply-To: References: <48B3CE0E.9000303@indicium.us> Message-ID: <9ebd65110808260631i5b1c887co48e4e0b70866b41b@mail.gmail.com> On Tue, Aug 26, 2008 at 4:50 AM, Mike Schuh wrote: > Solutions: Use integer pennies, dividing by 100 when displaying the values > as dollars (and use the integer pragma). Agreed. At a substantial performance penalty you can also try using /more/ floating point precision. There are some CPAN modules worth examining like Math::Currency and Math::BigFloat. For example; before: #!/usr/bin/perl -w use strict; my $a = 1.0; # one dollar my $b = $a - 0.9; # minus 90 cents $b = $b - 0.1; # minus 10 cents print "$b\n"; # prints -2.77555756156289e-17 after: #!/usr/bin/perl -w use strict; use Math::BigFloat; my $a = Math::BigFloat->new(1.0); # one dollar my $b = $a - 0.9; # minus 90 cents $b = $b - 0.1; # minus 10 cents print "$b\n"; # prints 0 Even if you can't use CPAN modules (since this is for a class) reading their code might be helpful in trying to roll your own money-ish type. Floating point math is one of the tricky, interesting parts of binary arithmetic that programmers must learn in order to become engineers. You'll encounter this in any programming language you use. quick answer from perlfaq4: http://tinyurl.com/5hecdh more on floating point: http://tinyurl.com/6k4emc read this too! (mentioned by Ben Reser in this thread): http://tinyurl.com/6fzwrc Nice work on the code. Some tips: * "use strict;" in your module * don't hardcode class name in new() method, one of the arguments to new() is the class name * generally you wouldn't print stuff from within your module... try to separate the core logic of your module from the presentation to the user -- Adam Monsen From tallpeak at hotmail.com Tue Aug 26 07:51:49 2008 From: tallpeak at hotmail.com (Aaron West) Date: Tue, 26 Aug 2008 07:51:49 -0700 Subject: SPUG: Incorrect subtraction result In-Reply-To: <9ebd65110808260631i5b1c887co48e4e0b70866b41b@mail.gmail.com> References: <48B3CE0E.9000303@indicium.us> <9ebd65110808260631i5b1c887co48e4e0b70866b41b@mail.gmail.com> Message-ID: I'd like to add that if it seems strange that some fractions (such as 1/5 or 1/10) cannot be represented accurately in binary, consider the fact that 1/3 and 1/7 (for example) cannot be accurately represented in base 10 (decimal). The reason is the same. From jobs-noreply at seattleperl.org Tue Aug 26 14:47:24 2008 From: jobs-noreply at seattleperl.org (SPUG Jobs) Date: Tue, 26 Aug 2008 14:47:24 -0700 (PDT) Subject: SPUG: JOB: Perl/Apache/CGI/SQL - Contract - Downtown Seattle Message-ID: Job Description - Perl Developer We are looking for Perl Developers for an exciting opportunity with a growing company in Seattle. If you are interested, please send us a resume. Below are some of the required skills: Required Skills - 3-5 years of experience with Perl, Apache and CGI web applications. - Solid in Web and related technologies including CGI, HTML, XML, XSL. - Strong data layer skills (SQL, PL/SQL). - An understanding of 3 tier and service oriented architectures. - Strong overview knowledge of software development cycles, web and network technologies. - Demonstrated ability to work with database teams to modify and optimize database code. - Experience working with corporate IT teams to document and automate the configuration of production systems. - Basic experience with performance and scalability analysis. - Ability to technically document software deliverables through use cases, design documents and technical specifications. This is a 2 to 3 month contract (W-2 or 1099) located on-site (no telecommuting) in downtown Seattle with an online advertising company placed through a recruiter. If interested please respond to chrisb at mindseekers.com From m3047 at inwa.net Tue Aug 26 21:50:48 2008 From: m3047 at inwa.net (Fred Morris) Date: Tue, 26 Aug 2008 21:50:48 -0700 Subject: SPUG: Incorrect subtraction result In-Reply-To: References: <48B3CE0E.9000303@indicium.us> <9ebd65110808260631i5b1c887co48e4e0b70866b41b@mail.gmail.com> Message-ID: <200808262150.48523.m3047@inwa.net> I had vague amusing notions that I would put up a web site which would let people put in their 10 digit telephone numbers, and give them two integers which when treated as dividend and divisor would yield them a repeating decimal fraction, repeating their telephone number. That turned out to be pretty interesting. I learned a few things; decided I'd defer the exercise. The problem is that low-order primes don't necessarily occur in the sequence 1/9,1/99,1/999.... or something like that. Anyway it worked with varying degrees of success for some telephone numbers and not at all (within reasonable integer precision) for others. It's late, I have a job; crypto geeks are welcome to ping me back on the weekend. On Tuesday 26 August 2008 07:51, Aaron West wrote: > I'd like to add that if it seems strange that some fractions (such as 1/5 or > 1/10) cannot be represented accurately in binary, consider the fact that 1/3 > and 1/7 (for example) cannot be accurately represented in base 10 (decimal). > The reason is the same. From m3047 at inwa.net Tue Aug 26 21:52:53 2008 From: m3047 at inwa.net (Fred Morris) Date: Tue, 26 Aug 2008 21:52:53 -0700 Subject: SPUG: JOB: Perl/Apache/CGI/SQL - Contract - Downtown Seattle In-Reply-To: References: Message-ID: <200808262152.53912.m3047@inwa.net> That's a 1099 violation... isn't it? Sounds like the peers you'd be working with have (or think they have) the same experience you'd be expected to have. On Tuesday 26 August 2008 14:47, SPUG Jobs wrote: > This is a 2 to 3 month contract (W-2 or 1099) located on-site (no > telecommuting) in downtown Seattle with an online advertising company > placed through a recruiter.