Re: [1003.1(2016/18)/Issue7+TC2 0001368]: Unworldly use of redirection and mailx(1) in at(1) and batch(1) examples.

2020-12-14 Thread Robert Elz via austin-group-l at The Open Group
Another issue where new text with a proposed resolution is posted
to the bug, and the bug is then closed within minutes, preventing
any further (in bug report) discussion.

People, please stop doing this - if a new note is added with a proposed
resolution (other than "apply the text in note NNN" perhaps) then leave
the issue open, for at least a week, before closing it (assuming there
are no more substantive comments).

In this one, while the example 3 being added (both of them) will work,
it is (or they are, this applies to both) (or seems to me to be) more
complicated than it needs to be.

That is:

at now + 1 hour <&1
run-batch-processing 2>&1 >&3 \
| mailx -E -s "errors during batch processing" mygroup
} | mailx -s "batch processing output" mygroup
EOF

could be written as

at now + 1 hour <&1 | mailx -E -s "errors during batch processing" mygroup

couldn't it?

Note there are two changes ... splitting the order in which the stdout and
stderr pipes are done, so that natural fd ordering is preserved, and hacks
using duplication onto another fd aren't required (in some cases, though 
probably not usefully here, it also means that any errors during the normal
stdout mail processing are also included in the stderr mail) and second,
avoiding use of the backslash-newline combination for line joining when
there's not really any good reason to do it that way (the change in
indentation is superficial, a result of my re-typing, and irrelevant).

Since 3 is a new example, it can hardly be needed to demonstrate a use
of duplicating onto another fd (ie: explicitly to show how to do that)
or an example using that technique would have been there already (and it
would be one where it really is needed, otherwise all people do is ask
"why that way?")

If the intent of the complicated processing is to avoid the "empty message
body, hope that's OK?" or whatever message it is from mailx from the stdout
mail being sent in the error mail (and perhaps only that), then

at now + 1 hour <&1 | mailx -E -s "errors during batch processing" mygroup

would avoid that happening, in a harmless way, and what's more demonstrates
the one and only truly safe use of "echo".

kre



Re: [1003.1(2016/18)/Issue7+TC2 0001368]: Unworldly use of redirection and mailx(1) in at(1) and batch(1) examples.

2021-01-14 Thread Richard Hansen via austin-group-l at The Open Group
On 2020-12-14 19:11, Robert Elz via austin-group-l at The Open Group wrote:
> Another issue where new text with a proposed resolution is posted 
> to the bug, and the bug is then closed within minutes, preventing 
> any further (in bug report) discussion.
> 
> People, please stop doing this - if a new note is added with a proposed 
> resolution (other than "apply the text in note NNN" perhaps) then leave 
> the issue open, for at least a week, before closing it (assuming there 
> are no more substantive comments).

The accepted text has been updated to address your comments. Please let us know 
if we missed anything.

Closing a bug doesn't mean that the "final accepted text" is actually final, 
only that we think the issue has been sufficiently addressed. We will revise 
the accepted text if a valid concern is raised.

-Richard



Re: [1003.1(2016/18)/Issue7+TC2 0001368]: Unworldly use of redirection and mailx(1) in at(1) and batch(1) examples.

2021-01-14 Thread Robert Elz via austin-group-l at The Open Group
Date:Thu, 14 Jan 2021 13:39:29 -0500
From:Richard Hansen 
Message-ID:  <873368db-6447-6f90-be5d-65037e06b...@rhansen.org>

  | The accepted text has been updated to address your comments.
  | Please let us know if we missed anything.

Looks fine now.   Thanks.

  | Closing a bug doesn't mean that the "final accepted text" is actually
  | final, only that we think the issue has been sufficiently addressed.

That problem was corrected already, and the issues now have
note boxes in which comments can be made - the point was just
that doing it via e-mail rather than adding a note means you
have to do things like note 5201, which is meaningless extra
work, both for you, and for people who later try to work out
what has happened and why, who no longer find all the information
in one convenient place.

kre