Many people are discovering that the scripting language Perl is the most useful language for getting many computing tasks done. In this article Dave Cross takes a brief look at Perl newsgroups.
This article first appeared in the October 1999 issue of the online Perl magazine PerlMonth (which no longer seems to be online).
Note: All of the articles in the RTFM series are really old. It’s likely that many of the links no longer work. I’m leaving these articles online for historical reasons, but these days you should visit perl.org for links to the best current Perl resources.
Introduction
After last month’s detour into the world of commercialism, this month we’re back with free Perl documentation and support as we take a look at the Perl newsgroups.
The Perl newsgroups have a reputation for being very unfriendly places. The truth is that they are full of extremely knowledgeable people who are only too happy to help out people with Perl problems. The problems arise because there are too many people who try to take advantage of this expertise without making any effort to help themselves first. You can be the most laid back and helpful person in the world, but I defy you not to get a little snappy when you see the same question asked for the one hundredth time, particularly when it’s one that you know is answered definitively in a document installed on the poster’s computer.
The Perl experts who read the newsgroups do want to help, but you just have to follow a few simple rules in order to avoid wasting too much of their time.
Rule One – Pick the right group
There are a number of newsgroups with ‘perl’ in the name. To get the best help and advice, it is essential to post your question in the right one. Here is a list of all of the Perl-related groups currently on my news server.
alt.music.perl-jam
This was created as a joke some years ago. The same person created alt.music.awk-jam and alt.music.sed-jam on the same day. These days it is only used by confused Pearl Jam fans (if that’s not a tautology!)
alt.perl
This group is best avoided. It was formed some time ago as a reaction to what some people see as over-strict posting policies in comp.lang.perl.misc. As a result no real Perl expects seem to frequent it and any advice you get from here will be largely untrustworthy.
alt.perl.sockets
I only discovered this group when researching this column. There are very few posts to it and they would get much better responses in comp.lang.perl.misc or comp.lang.perl.modules. Probably best to avoid this one too.
comp.lang.perl.announce
This is a moderated newsgroup. This means that all posts to the group are automatically forwarded to a moderator for approval. If the moderator thinks that the post is on-topic for the group then it will be posted for everyone to read. Your post will be approved if it is an announcement that is of interest to the Perl community. Mostly this means new versions of Perl or Perl modules. Requests for help are never on topic in this group.
comp.lang.perl
This was the original Perl newsgroup. It is no longer used, having been split into the other groups in the comp.lang.perl hierarchy. Most news server administrators should have removed it from their newsgroup lists. If you find it on your news server, please inform the administrator and don’t post to it.
comp.lang.perl.misc
This is the general discussion area for Perl topics. Any Perl-related post that doesn’t fit better in one of the other groups should probably be posted here. Please ensure that your post is about Perl though. There are other specific groups that handle CGI programming, web server configuration and any number of other subjects that are tangentially associated with Perl.
comp.lang.perl.moderated
In the spring of 1998 a group of regular posters to comp.lang.perl.misc were getting frustrated with the number of newbie questions and FAQs that were getting posted to the group. This newsgroup was introduced as a remedy to the problem. The group is auto-moderated, which is a little less stringent than the manual moderation in place on comp.lang.perl.anounce, but still manages to keep the level of debate pretty high. This is a low traffic group as, in practice, most discussion still takes place in comp.lang.perl.misc.
comp.lang.perl.modules
This group was set up for the discussion of Perl modules and CPAN. If you have a question that is about a particular module, then this is the best place to post it.
comp.lang.perl.tk
This group is specifically for the discussion of the Perl/Tk module. This module is used to create GUI front ends for Perl applications.
comp.infosystems.www.authoring.cgi
Not specifically a Perl group, but this is the place to discuss CGI programming (most of which is done in Perl). If a question that you post in a Perl newsgroup is really a CGI question, you’ll be redirected to this group. A good rule of thumb to use when deciding whether your question is a Perl question or a CGI question is to see if you can describe the problem without mentioning web pages, web servers or HTML. If you can, then it’s probably a Perl question.
Rule Two – Don’t ask FAQs
Perl comes with a comprehensive set of free documentation. This includes a huge list of frequently asked questions (FAQs) together with their answers. Every copy of Perl contains these files either as POD (plain old documentation) or as HTML. Asking a question that is answered in one of these files is just about the quickest way to get yourself a bad reputation in the newsgroups. I covered this in more detail in my first RTFM column, but some of the more common FAQs include:
- Is Perl Y2K compliant? (or its close relative Why does localtime return two digit years?)
This is answered clearly in perlfaq4 Does Perl have a year 2000 problem? Is Perl Y2K compliant? - How do I alter one piece of text in a file?
Answered in perlfaq5 How do I change one line in a file/delete a line in a file/insert a line in the middle of a file/append to the beginning of a file? - How do I read data from a web page into my program?
Answered in perlfaq9 How do I fetch an HTML file?
In short, as a Perl programmer you should have a good grasp of what is in the FAQ files and shouldn’t post a question to the newsgroups if it is answered in these files.
A common complaint in the newsgroup is that FAQs are often answered by pointing the poster at the relevant FAQ document rather than by posting the answer to the newsgroup. The reason for this is that it is better to encourage people to look up answers themselves as it (hopefully) makes them less likely to post a FAQ next time they have a problem.
Rule Three – Don’t ask for scripts to be written for you
It is becoming quite common for people to post messages saying something like ‘I need a script to do X, can someone write this script for me’. This is not what the newgroups are for. If you’re stuck with a script you’re writing then post a cut-down version of the code and explain the problem and we’ll be happy to help, but if you want a script written then hire a programmer (we all have to eat).
A closely related problem to this is people posting homework questions to the group. The regular posters have become very adept at spotting this kind of question. If you’re lucky, you’ll just be ignored. If you’re unlucky someone will post a really obscure solution to your problem which you’ll never be able to explain to your lecturer.
Rule Four – Use a descriptive subject line
Most people don’t read every post in a newsgroup. They will just scan the list of subject lines and choose the ones that interest them. A post with a subject of ‘Help!!!’ or ‘Perl problem’ will get far less responses than one with a subject line of ‘Need help writing data to file’ or ‘use strict makes my program crash’.
Rule Five – give a little back
USENET works best as a collaborative effort. There are two ways that you can do your bit to help it work at maximum efficiency.
- Don’t ask for responses to emailed to you. If you have time to post your question to a newsgroup, then make the time to read the responses in the same place. Other people may have the same problems that you do and will appreciate reading the responses to your post.
- Once your question has been answered, keep reading the group. People may ask questions that you know the answer to. Share your expertise the same way that you’d like people to share their expertise with you.
Rule Six – Follow standard USENET etiquette
When you first get access to USENET you should be directed to the group news.announce.newusers. This group contains posts that introduce new users to the recommended ways to interact with USENET. If you haven’t already, you should look at these messages now. The most important ones are called ‘Rules for posting to Usenet’, ‘A Primer on How to Work With the Usenet Community’ and ‘Emily Postnews Answers Your Questions on Netiquette’. The advice in these messages applies across all newsgroups and following it will go a long way towards preventing you from annoying the people who you’d like to get help from.
Conclusion
I hope I’ve shown that asking for help in the Perl newsgroups needn’t be the terrifying experience that some people claim it to be. As long as you realise that the people answering the questions are all doing it in their spare time and treat them accordingly, you should get on fine.
I’d like to briefly return to last month’s topic of Perl books. A couple of people have emailed me to point out that my platform bias was showing. I missed two books that cover using Perl on non-Unix platforms. These are Learning Perl on Win32 Systems (O’Reilly) ISBN: 1565923243 by Randal L Schwartz, Erik Olson & Tom Christiansen and MacPerl: Power and Ease (Prime Time) ISBN: 1881957322 by Vicki Brown and Chris Nandor. Apologies to the authors for the omissions.