logoalt Hacker News

cassianoleallast Friday at 11:28 PM2 repliesview on HN

I had some shell scripts littered with `|| true`, which was obviously obscuring real errors everywhere. When I challenged the model, it gave me the same "cargo-culting" answer.


Replies

bewuethryesterday at 2:32 AM

The `|| true` is often done because people use `errexit` as part of "Bash strict mode"[1], which comes with so many caveats[2] that I usually avoid it. Claude, however, loves it.

[1]: http://redsymbol.net/articles/unofficial-bash-strict-mode/

[2]: https://mywiki.wooledge.org/BashPitfalls#set_-euo_pipefail

kingforadayyesterday at 12:38 PM

From your statement and the parent comment, just learned that "cargo cult" is a thing, but cargo-culting as a compound is something AI has made up? [1].

As I was educating myself, I found Richard Feynman's Commencement Speech at Caltech in '74 [2] that might have coined this for our industry? If you would rather listen than read [3]. Posting this for others curious on the term.

1. https://trends.google.com/trends/explore?q=Cargo-culting&hl=...

2. https://calteches.library.caltech.edu/51/2/CargoCult.htm

3. https://www.youtube.com/watch?v=yvfAtIJbatg

show 1 reply