[12223] in Perl-Users-Digest
Perl-Users Digest, Issue: 5823 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri May 28 20:07:46 1999
Date: Fri, 28 May 99 17:01:24 -0700
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Fri, 28 May 1999 Volume: 8 Number: 5823
Today's topics:
Re: Y2K infected Perl code <webmaster@chatbase.com>
Re: Y2K infected Perl code <bradw@newbridge.com>
Re: Y2K infected Perl code <tchrist@mox.perl.com>
Re: Y2K infected Perl code <tchrist@mox.perl.com>
Re: Y2K infected Perl code ()
Re: Y2K infected Perl code (Alastair)
Re: Y2K infected Perl code (Sam Holden)
Re: Y2K infected Perl code <jeromeo@atrieva.com>
Re: Y2K infected Perl code (Larry Rosler)
Re: Y2K infected Perl code ()
Re: Y2K infected Perl code ()
Special: Digest Administrivia (Last modified: 12 Dec 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 28 May 1999 13:09:12 -0700
From: TRG Software : Tim Greer <webmaster@chatbase.com>
Subject: Re: Y2K infected Perl code
Message-Id: <374EF7E8.80293556@chatbase.com>
finsol@ts.co.nz wrote:
>
> You may have missed my posting today where I gave examples of Y2K broken
> code,
Not in CGI. :-) Wait, what was your point?
> so I have included them below. These examples are in Perl but
> similar examples can be found in Java and several other languages
> frequently used for CGI programming. I targetted localtime in Perl as it
> appears to be the most frequently found Y2K problem within CGI routines.
> If Perl code can be infected with Y2K problems, then so can CGI routines
> - deny that if you can!
I won't deny anything. I admit you're unqualified to make such
statements.
If you're going to try and prove a point, by going to Matt's Script
archive, then you may as well zip up the entire site and get it over
with. Posting examples of some bad code, doesn't help. I can do a search
and find poorly written code in 95% of the Perl scripts available on the
Net and show you plenty of them that won't work *now*, or after the Y2K
issue. it's due to "poor programming", "bad code", and has nothing to do
with the Y2K issue, other then the people were clueless that wrote that
code, and further, because they have other poorly written parts of code
in the script, doesn't mean it's a Y2K problem either. Are you talking
about a program that functions based on the year, etc., or are you
talking about a program that PRINTS the date? Do you see the difference?
Any programmer that has any clue of what he's doing, isn't going to get
into that situation. Any bad programmer will get themselves into a bug
ridden situation anyway, no matter what year it is.
You haven't been proving any good points. Just drop it and stop
"denying" that there's some urgent underlying problem, simply because
you want people to believe it.
The PROBLEM with Y2K, is how people react about it. You have the choice
as an individual to completely panic, or remain calm and use your head.
If you choose the latter, then you'll see there's nothing to panic
about. People cause riots, not computers. Oxygen is still going to be
available to all humans to breath, your dog will still bark, things
won't "explode", your car will still steer, your shoes will still tie.
Do you think hospitals run their life support systems on a Windows
machine? Do you think traffic lights run on a PC? What is wrong with
you? There's quite obviously a few problems that will happen, but
nothing catastrophic -- not unless everyone decides to assume the worst
and panic about everything. Anyone with a normal grasp of reality and
common sense, will know this is more of a hoax then anything else.
So, spare me little snippets of poorly written code. I can only assume
that those programs were written to only be in use for so long, and
believe me, that was a mistake already. Find a more reliable source to
make examples from, because I could write a program in any language you
like (for CGI or not), and have them all break at the Y2K, or run past
the Y2K. It's a choice of good or bad programming. Any program worth
anything, or any critical program isn't going to have those sort of
"gotcha's".
--
Regards,
Tim Greer: chatmaster@chatbase.com / software@linkworm.com
Chat Base: http://www.chatbase.com | 250,000+ hits daily Worldwide!
TRG Software: http://www.linkworm.com | CGI scripting in Perl/C, & more.
Unix/NT/Novell Administration, Security, Web Design, ASP, SQL, & more.
Freelance Programming & Consulting, Musician, Martial Arts, Sciences.
------------------------------
Date: 28 May 1999 18:14:47 -0400
From: bj <bradw@newbridge.com>
Subject: Re: Y2K infected Perl code
Message-Id: <op1wvxsalk8.fsf@newbridge.com>
docdwarf@clark.net () writes:
> Please be so kind, then, as to address the situation posed and not my
> responses to it... what happens if a person writing code is not a 'retard'
> but the specs demand the adherance to certain standards?
Please be so kind to supply an example of such a spec. While the
standards may be truely stupid in a broader context, producing code
that performs according to the spec is by definition correct code.
For example, if the spec states that 2 digit "year" fields must be
used then there must be an expectation and presumably a stated
requirement for what is required 7 months from now. If the spec calls
for "00", then it ain't broken.
Are you saying that you have a standard that states you must take the
output of the years field in localtime and concatenate it to "19" to
produce a correct 4 digit date?
puzzled,
bj
------------------------------
Date: 28 May 1999 16:34:05 -0700
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: Y2K infected Perl code
Message-Id: <374f19dd@cs.colorado.edu>
[courtesy cc of this posting mailed to cited author]
In comp.lang.perl.misc,
finsol@ts.co.nz writes:
:Just because a particular language makes this particularly
:easy to do (as with Perl and as with languages that have non-compliant
:components) doesn't change the fact.
Can you open your mouth for any other purpose than to spread fear,
uncertainty, and doubt -- or just plain lies, as in this case?
Perl has no non-compliant component. It has non-compliant progammers.
So does any langauge.
THERE IS NO SOLUTION. If it had always been 4 digits, people would
have just subtracted 1900 to get that 2-digit year which people
adore printing, and then they still would be wrong. And for the
same reason: they neglected to
READ
THE
FUCKING
MANUAL
I am convinced that you are too dim to understand any of this.
--tom
--
Mister Catbert, the company is trying to force me to use a different kind
of computer. You're the human resources directory. what are you doing
to sop this religious persecution?! What every happened to "Diversity"??
The longer you verk here, diverse it gets. next. --Scott Adams, "Dilbert"
------------------------------
Date: 28 May 1999 16:37:07 -0700
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: Y2K infected Perl code
Message-Id: <374f1a93@cs.colorado.edu>
[courtesy cc of this posting mailed to cited author]
In comp.lang.perl.misc,
lr@hpl.hp.com (Larry Rosler) writes:
: s?printf '...19%d...', ..., $year, ...;
:will be next, I presume?
Yup, remarkably enough. Check out the p5p archives for discussion of the same.
Feel free to kibbitz^Wcontribute.
--tom
--
"The road to hell is paved with melting snowballs."
--Larry Wall in <1992Jul2.222039.26476@netlabs.com>
------------------------------
Date: Fri, 28 May 1999 22:27:15 GMT
From: docdwarf@clark.net ()
Subject: Re: Y2K infected Perl code
Message-Id: <7LE33.143$K2.4998@iad-read.news.verio.net>
In article <op1wvxsalk8.fsf@newbridge.com>, bj <bradw@newbridge.com> wrote:
>docdwarf@clark.net () writes:
>
>> Please be so kind, then, as to address the situation posed and not my
>> responses to it... what happens if a person writing code is not a 'retard'
>> but the specs demand the adherance to certain standards?
>
>Please be so kind to supply an example of such a spec. While the
>standards may be truely stupid in a broader context, producing code
>that performs according to the spec is by definition correct code.
>
>For example, if the spec states that 2 digit "year" fields must be
>used then there must be an expectation and presumably a stated
>requirement for what is required 7 months from now. If the spec calls
>for "00", then it ain't broken.
>
>Are you saying that you have a standard that states you must take the
>output of the years field in localtime and concatenate it to "19" to
>produce a correct 4 digit date?
Oh dear, my apologies... I had expanded upon a posting which I found in
comp.software.year-2000 which had referred to the 'person writing the
code' as a 'retard'; it now becomes that the author might not have been
referring to 'coders' but to Perl-slingers. It was wrong of me,
obviously, to conclude that a 'person writing the code' might be writing
anything *but* Perl... say, BAL, FORTRAN or COBOL.
DD
------------------------------
Date: Fri, 28 May 1999 23:04:24 GMT
From: alastair@calliope.demon.co.uk (Alastair)
Subject: Re: Y2K infected Perl code
Message-Id: <slrn7kubr2.fp.alastair@calliope.demon.co.uk>
finsol@ts.co.nz <finsol@ts.co.nz> wrote:
>Lane's point still holds - a programmer can create Y2K problems in COBOL
>and in Perl.
True.
>Just because a particular language makes this particularly
>easy to do (as with Perl and as with languages that have non-compliant
>components) doesn't change the fact.
Easy? Not if you have a a clue. After all, when you use a particular function or
programming contsruct, you read the manual. If you don't, you deserve the
consequences.
>Y2K problems can occur in applications written in any programming
>language and all programming languages can be used to write non-Y2K
>problem applications.
True.
>> I think that uri's point is that basically if someone is too dumb to
>have read and understood the documentation for the localtime function
>then its basically tough shit - it is not a problem with Perl its a
>problem with the meatware.
>> /J\
>> --
>> Jonathan Stowe <jns@gellyfish.com>
>
>Tough shit for who? Just think about it. Who is going to suffer from all
>this denial and ignorance the most? There is certainly a problem Perl
>developers if they can be so blase about the consequences of Y2K
>problems within the organisations which use the Perl progranmming
>language.
Eh? You just said that it's a potential problem with *any* programming language.
Therefore I'd say the programmer is the one needing to take care - in the usual
way. RTFM.
End of story.
--
Alastair
work : alastair@psoft.co.uk
home : alastair@calliope.demon.co.uk
------------------------------
Date: 28 May 1999 23:13:16 GMT
From: sholden@pgrad.cs.usyd.edu.au (Sam Holden)
Subject: Re: Y2K infected Perl code
Message-Id: <slrn7ku8oc.8ph.sholden@pgrad.cs.usyd.edu.au>
On Fri, 28 May 1999 22:27:15 GMT, docdwarf@clark.net <docdwarf@clark.net> wrote:
>In article <op1wvxsalk8.fsf@newbridge.com>, bj <bradw@newbridge.com> wrote:
>>
>>Are you saying that you have a standard that states you must take the
>>output of the years field in localtime and concatenate it to "19" to
>>produce a correct 4 digit date?
>
>Oh dear, my apologies... I had expanded upon a posting which I found in
>comp.software.year-2000 which had referred to the 'person writing the
>code' as a 'retard'; it now becomes that the author might not have been
>referring to 'coders' but to Perl-slingers. It was wrong of me,
>obviously, to conclude that a 'person writing the code' might be writing
>anything *but* Perl... say, BAL, FORTRAN or COBOL.
Some people would have read the subject and made a reasonable guess...
Though cross posting always confuses the hell out of every one...
--
Sam
PC's are backwards ... throw them out! Linux is ok though.
--Rob Pike (on the subject of CR/LF etc)
------------------------------
Date: Fri, 28 May 1999 16:18:00 -0700
From: Jerome O'Neil <jeromeo@atrieva.com>
To: docdwarf@clark.net
Subject: Re: Y2K infected Perl code
Message-Id: <374F2428.928C3452@atrieva.com>
docdwarf@clark.net wrote:
> Oh dear, my apologies... I had expanded upon a posting which I found in
> comp.software.year-2000 which had referred to the 'person writing the
> code' as a 'retard'; it now becomes that the author might not have been
> referring to 'coders' but to Perl-slingers. It was wrong of me,
> obviously, to conclude that a 'person writing the code' might be writing
> anything *but* Perl... say, BAL, FORTRAN or COBOL.
<From way off yon in c.l.p.m>
Well, if the shoe fits...
:-)
--
Jerome O'Neil, Operations and Information Services
Atrieva Corporation, 600 University St., Ste. 911, Seattle, WA 98101
jeromeo@atrieva.com - Voice:206/749-2947
The Atrieva Service: Safe and Easy Online Backup http://www.atrieva.com
------------------------------
Date: Fri, 28 May 1999 16:28:32 -0700
From: lr@hpl.hp.com (Larry Rosler)
Subject: Re: Y2K infected Perl code
Message-Id: <MPG.11b8c67ba55ec22d989b2c@nntp.hpl.hp.com>
[Posted and a courtesy copy mailed.]
In article <374f1a93@cs.colorado.edu> on 28 May 1999 16:37:07 -0700, Tom
Christiansen <tchrist@mox.perl.com> says...
> In comp.lang.perl.misc,
> lr@hpl.hp.com (Larry Rosler) writes:
> : s?printf '...19%d...', ..., $year, ...;
> :will be next, I presume?
>
> Yup, remarkably enough. Check out the p5p archives for discussion of the same.
> Feel free to kibbitz^Wcontribute.
You are right -- it is remarkable, in fact, incredible. At least it is
labeled Y2K_HACK :-).
All the tests seem to focus on '19%02d' and none mention '19%.2d' which
is equivalent and (in some cases, though not in this) superior. Perhaps
someone will note that and include it. Not me, though -- I don't have
more than the 24 hours a day or so that I seem to spend in the
comp.perl... newsgroups, mostly this one. Maybe if/when I retire from
my full-time job.
--
(Just Another Larry) Rosler
Hewlett-Packard Company
http://www.hpl.hp.com/personal/Larry_Rosler/
lr@hpl.hp.com
------------------------------
Date: Fri, 28 May 1999 23:18:06 GMT
From: docdwarf@clark.net ()
Subject: Re: Y2K infected Perl code
Message-Id: <OuF33.146$K2.4954@iad-read.news.verio.net>
In article <slrn7ku8oc.8ph.sholden@pgrad.cs.usyd.edu.au>,
Sam Holden <sholden@cs.usyd.edu.au> wrote:
>On Fri, 28 May 1999 22:27:15 GMT, docdwarf@clark.net <docdwarf@clark.net> wrote:
>>In article <op1wvxsalk8.fsf@newbridge.com>, bj <bradw@newbridge.com> wrote:
>>>
>>>Are you saying that you have a standard that states you must take the
>>>output of the years field in localtime and concatenate it to "19" to
>>>produce a correct 4 digit date?
>>
>>Oh dear, my apologies... I had expanded upon a posting which I found in
>>comp.software.year-2000 which had referred to the 'person writing the
>>code' as a 'retard'; it now becomes that the author might not have been
>>referring to 'coders' but to Perl-slingers. It was wrong of me,
>>obviously, to conclude that a 'person writing the code' might be writing
>>anything *but* Perl... say, BAL, FORTRAN or COBOL.
>
>Some people would have read the subject and made a reasonable guess...
... and others would realise that after a few responses a thread can be
rather... tangentially related to the subject.
>
>Though cross posting always confuses the hell out of every one...
You mean this *isn't* where I can get binaries of a naked platypus?
DD
------------------------------
Date: Fri, 28 May 1999 23:28:27 GMT
From: docdwarf@clark.net ()
Subject: Re: Y2K infected Perl code
Message-Id: <vEF33.148$K2.5022@iad-read.news.verio.net>
In article <374F2428.928C3452@atrieva.com>,
Jerome O'Neil <jeromeo@atrieva.com> wrote:
>docdwarf@clark.net wrote:
>> Oh dear, my apologies... I had expanded upon a posting which I found in
>> comp.software.year-2000 which had referred to the 'person writing the
>> code' as a 'retard'; it now becomes that the author might not have been
>> referring to 'coders' but to Perl-slingers. It was wrong of me,
>> obviously, to conclude that a 'person writing the code' might be writing
>> anything *but* Perl... say, BAL, FORTRAN or COBOL.
>
><From way off yon in c.l.p.m>
>
>Well, if the shoe fits...
Well, I write code, sure... as for my own retardation I'll opine no
opinions. Consider Wittgenstein's question of 'Imagine a parrot saying 'I
don't understand a word i say', is there Truth there?'... imagine a retard
saying 'I am/am not a retard'...
DD
------------------------------
Date: 12 Dec 98 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Special: Digest Administrivia (Last modified: 12 Dec 98)
Message-Id: <null>
Administrivia:
Well, after 6 months, here's the answer to the quiz: what do we do about
comp.lang.perl.moderated. Answer: nothing.
]From: Russ Allbery <rra@stanford.edu>
]Date: 21 Sep 1998 19:53:43 -0700
]Subject: comp.lang.perl.moderated available via e-mail
]
]It is possible to subscribe to comp.lang.perl.moderated as a mailing list.
]To do so, send mail to majordomo@eyrie.org with "subscribe clpm" in the
]body. Majordomo will then send you instructions on how to confirm your
]subscription. This is provided as a general service for those people who
]cannot receive the newsgroup for whatever reason or who just prefer to
]receive messages via e-mail.
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V8 Issue 5823
**************************************