News for hackers. Stuff that matters.
Re:The Trouble with __all__ by kstrauser on Thursday August 01, 2024 @05:14PM (#41133699)
The false assumption that a language can enforce something is the root of 10,000 CVEs.

For instance, in C, you have read/write access to the whole program's memory space. Want to work around some security mechanism? A well-aimed pointer will do the right trick.

Python doesn't prevent you from ever touching _internal or __private names. If you're reviewing a Python PR that does that, you should be as suspicious as if you were reviewing C code that stomps all over memory. In either case you almost certainly should not be doing that.

But sometimes, only sometimes, you might be the right person in the right use case to do it. Then you can ignore the linters screaming at you and concentrate on convincing your coworker this is a good idea.

There are no comments on this comment yet.