News for hackers. Stuff that matters.
Re:3 percent of Python codebases we checked had silently fai... by justinsaccount on Wednesday February 16, 2022 @10:09AM (#30360916)
The 2nd argument is the 'msg' argument.

With modern features in python you could change the signature to

  assertTrue(expr, *, msg=None)
which would prevent that issue.
Re:3 percent of Python codebases we checked had silently fai... by d0mine on Wednesday February 16, 2022 @12:39PM (#30362993)
or just:

    assert expr, "custom message"
though given the verbose api, it is ok to require the explicit msg kwarg (duplication in the tests is ok if it makes them more robust)