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

Bug#331532: [PROPOSAL] change §10.4 "set -e OR check return status" to AND or be rewritten



On 02-Oct-2005, Eduard Bloch wrote:
> "Every script should should be implemented in the most problem
> tolerant way. Exit status of every command should be checked and
> handled appropriately if it can cause potential failure."

I'd make the structure of the last sentence clearer:

    [...] If any command can potentially cause failure for the
    process, its exit status should be checked and handled
    appropriately.

Even reworded like this, however, is both too specific and too vague.

Programs can communicate failure in ways other than only their exit
status: semaphore files, for example. If policy is to proscribe this
kind of checking, it shouldn't limit itself only to those failures
indicated by an exit status.

The proscription gives no guidance what to actually do: "checked and
handled appropriately" is useless as a guide to action.

The final question is: Why is this necessary in policy? If this were
not implemented, would any of these programming errors *not* warrant
an important bug? If it's already grounds for a bug report, what good
is done by proscribing it in policy?

-- 
 \        "None can love freedom heartily, but good men; the rest love |
  `\                        not freedom, but license."  -- John Milton |
_o__)                                                                  |
Ben Finney <ben@benfinney.id.au>

Attachment: signature.asc
Description: Digital signature


Reply to: