asserts would be removed. Apart from tools like py2exe I have barely seen -O in the wild.
But, yes, the asserts would render useless – so it's important to have a good test coverage.
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
Are asserts still removed when python runs with -O? If so what does that mean for code accuracy by using asserts?
assert
s would be removed. Apart from tools likepy2exe
I have barely seen-O
in the wild.But, yes, the
assert
s would render useless – so it's important to have a good test coverage.