Skip to content
Better HN
Top
Best
Ask
Show
New
Jobs
Search
⌘K
0 points
Kristine1975
10y ago
0 comments
Save
Share
Isn't that what assertions are for?
0 comments
2 comments · 2 top-level
top
newest
oldest
Karunamon
10y ago
Assertions can be disabled at runtime. If your goal is to call out the fact that something has gone fundamentally wrong with your program's state, an exception is the way to go.
amatix
10y ago
in Python, running with `-O`, from .pyo files, or equivalent settings in your webserver will all disable assertions.
surprise!
j
/
k
navigate · click thread line to collapse