help-gawk
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to make "division by zero attempted" error message more informat


From: Neil R. Ormos
Subject: Re: How to make "division by zero attempted" error message more informative?
Date: Thu, 3 Mar 2022 15:11:34 -0600 (CST)

Wolfgang Laun wrote:
> Neil R. Ormos wrote:

> > For each call to gawk in the multiple scripts,
> > you could create a symlink to the gawk
> > executable with a different distinguishing
> > name, and then call gawk using that name.
> > Then, each error message will be prefaced by
> > the distinguishing name.

> You might do this on your very personal
> computer. But you might not care to pull this
> through on a production system with any number
> of users and an IT department that might have to
> say something in this matter.

That's a fair point.

The OP hasn't disclosed the nature of the environment--production, dev, 
prototype, toy.

What's "production worthy" is in the eye of the beholder.

Code that relies on capturing interpreter error messages in normal operation 
might not be production worthy in the first place.

The /usr hierarchy on a typical Linux system can have more than 30,000 
symlinks, including a fair number that are at least three levels deep.  And 
there's the Alternatives mechanism.  If the use of the symlink canard is part 
of the design of the application, I don't see it as any more objectionable for 
production than other common techniques.

On the other side of this, I've seen an environment where local standards 
required that every executable object, including utilities, have a versionized 
name, and every invocation be made to a specific version.  The rule was an 
over-reaction to a calamity unlikely to recor, but once it was implemented, 
system behavior became very brittle.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]