Issue1506561

classification
Title: assert parameter evaluation
Type: Severity: normal
Components: Core Versions:
Milestone:
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: cgroves, gscokart, raptoraudio
Priority: normal Keywords:

Created on 2006-06-15.09:53:58 by gscokart, last changed 2006-08-20.20:13:14 by cgroves.

Messages
msg1150 (view) Author: Gilles Scokart (gscokart) Date: 2006-06-15.09:53:58
in the statement

assert true , f()

The function f is always invoked.  It should only be
invoked in
assert false , f()

CPython only evaluate the second parameter when the
assertion fails.
msg1151 (view) Author: Raptor Audio (raptoraudio) Date: 2006-08-19.06:09:15
Logged In: YES 
user_id=1579229

Patch # 1542997 has been submitted to handle this issue.

Raptor
msg1152 (view) Author: Charlie Groves (cgroves) Date: 2006-08-20.20:13:14
Logged In: YES 
user_id=1174327

The patch fixed the problem and was applied in r2900
History
Date User Action Args
2006-06-15 09:53:58gscokartcreate