Hi,
http://hg.python.org/cpython/rev/72de2ac8bb4f branch: 2.7 user: Petri Lehtinen
date: Sun Oct 30 13:55:02 2011 +0200 summary: Avoid unnecessary recursive function calls (closes #10519)
http://hg.python.org/cpython/rev/0694ebb5db99 branch: 2.7 user: Jesus Cea
date: Mon Oct 31 16:02:12 2011 +0100 summary: Closes #13283: removal of two unused variable in locale.py
I thought that patches that clean up code but don’t fix actual bugs were not done in stable branches. Has this changed? (The first commit quoted above may be a performance fix, which would be okay IIRC.) Regards
Removing dead code and bypassing redundant code are both reasonable bug fixes. The kind of change to be avoided is gratuitous replacement of older idioms with newer ones. -- Nick Coghlan (via Gmail on Android, so likely to be more terse than usual)
On Mon, Oct 31, 2011 at 13:24, Nick Coghlan
Removing dead code and bypassing redundant code are both reasonable bug fixes. The kind of change to be avoided is gratuitous replacement of older idioms with newer ones.
What Nick said as I was in the middle of typing when he sent this. =) -Brett
-- Nick Coghlan (via Gmail on Android, so likely to be more terse than usual)
_______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/brett%40python.org
On Oct 31, 2011, at 06:23 PM, Éric Araujo wrote:
I thought that patches that clean up code but don’t fix actual bugs were not done in stable branches. Has this changed?
I hope not. Sure, if they fix actual bugs, that's fine, but as MvL often points out, even innocent looking changes can break code *somewhere*. We don't lose by being conservative with our stable branches. -Barry
On Nov 1, 2011, at 1:31 PM, Barry Warsaw wrote:
On Oct 31, 2011, at 06:23 PM, Éric Araujo wrote:
I thought that patches that clean up code but don’t fix actual bugs were not done in stable branches. Has this changed?
I hope not. Sure, if they fix actual bugs, that's fine, but as MvL often points out, even innocent looking changes can break code *somewhere*. We don't lose by being conservative with our stable branches.
-Barry
I concur with Barry and MvL. Random code cleanups increase the risk of introducing new bugs. Raymond
Nick and Brett share the opinion that some code cleanups can be considered bugfixes, whereas MvL, Barry and Raymond defend that we never know what can get broken and it’s not worth risking it. I have added a comment on #13283 (removal of two unused variable in locale.py) to restate this policy, but haven’t asked for a revert; I did not comment on #10519 (Avoid unnecessary recursive function calls), as it can be considered a bugfix and Raymond took part in the discussion and thus implicitly approved the change. Regards
On Sat, Nov 5, 2011 at 3:05 AM, Éric Araujo
Nick and Brett share the opinion that some code cleanups can be considered bugfixes, whereas MvL, Barry and Raymond defend that we never know what can get broken and it’s not worth risking it.
I have added a comment on #13283 (removal of two unused variable in locale.py) to restate this policy, but haven’t asked for a revert; I did not comment on #10519 (Avoid unnecessary recursive function calls), as it can be considered a bugfix and Raymond took part in the discussion and thus implicitly approved the change.
There's always going to be a grey area where it's a judgment call - my opinion is basically the same as what you state in your second paragraph. Cheers, Nick. -- Nick Coghlan | ncoghlan@gmail.com | Brisbane, Australia
participants (5)
-
Barry Warsaw
-
Brett Cannon
-
Nick Coghlan
-
Raymond Hettinger
-
Éric Araujo