Serhiy Storchaka added the comment:
Resolved conflicts, fixed some noted issues in the patch and committed
unquestionable changes. Thank you for your patch Ramchandra.
--
resolution: - fixed
stage: patch review - resolved
status: open - closed
___
Roundup Robot added the comment:
New changeset b3a7215b9ce4 by Serhiy Storchaka in branch 'default':
Issue #16261: Converted some bare except statements to except statements
https://hg.python.org/cpython/rev/b3a7215b9ce4
--
___
Python tracker
Changes by Serhiy Storchaka storch...@gmail.com:
--
assignee: - serhiy.storchaka
stage: needs patch - patch review
versions: +Python 3.5 -Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
Martin Panter added the comment:
I reviewed the patch on Reitveld. All of the changes that do not have comments
look okay to me, although some will definitely have merge conflicts with the
current code. If someone updated the patch based on the comments, I think it
may be okay to commit.
Terry J. Reedy added the comment:
See more discussion on duplicate #21259.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
___
Changes by Ezio Melotti ezio.melo...@gmail.com:
--
nosy: +ezio.melotti
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
___
Terry J. Reedy added the comment:
The earlier #15313 is about removing bare excepts in Idle code. These should be
handled separately for two reasons.
1. Changes can and in most cases should be backported.
2. As with any other Python-coded application, uncaught exceptions cause Idle
to quit.
Changes by STINNER Victor victor.stin...@gmail.com:
--
nosy: +haypo
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
___
Python-bugs-list
Ramchandra Apte added the comment:
Here's a patch on revision 75fe7f5fda9a (I did it on a trip without an internet
connection)
There might be some mistakes of this type:
I incorrectly changed instances like this
`
try:
something
except:
close file
raise
`
to
`
try:
something
Ramchandra Apte added the comment:
Sorry, I entered the wrong filename for the patch and so it didn't get
attached. Now I have attached it.
--
keywords: +patch
Added file: http://bugs.python.org/file28647/patch.patch
___
Python tracker
Serhiy Storchaka added the comment:
Unhappy Rietveld hasn't recognize your patch. I have regenerated it.
--
nosy: +serhiy.storchaka
Added file: http://bugs.python.org/file28648/bare_except.patch
___
Python tracker rep...@bugs.python.org
Richard Oudkerk added the comment:
try:
_MAXFD = os.sysconf(SC_OPEN_MAX)
-except:
+except ValueError:
_MAXFD = 256
os.sysconf() might raise OSError. I think ValueError is only raised if
_SC_OPEN_MAX was undefined when the module was compiled.
--
nosy: +sbt
Serhiy Storchaka added the comment:
See my comments on Rietveld.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
___
Python-bugs-list
Serhiy Storchaka added the comment:
Want to make a few warnings. Accepting your confirmation may take a long time.
And it is very unlikely that your patch can be applied as a whole. The
maintainers of the individual modules can apply it by parts.
--
Roundup Robot added the comment:
New changeset b2bd62d1644f by Andrew Svetlov in branch 'default':
Issue #16261: fix bare excepts in Doc/
http://hg.python.org/cpython/rev/b2bd62d1644f
--
nosy: +python-dev
___
Python tracker rep...@bugs.python.org
Andrew Svetlov added the comment:
I've fixed bare except: in docs.
Tomorrow we will have Python sprint in Kiev.
Maybe somebody will take a look on Lib.
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
Andrew Svetlov added the comment:
I'm pretty sure Doc and Lib are already fixed, only Tools left.
--
nosy: +asvetlov
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
Ramchandra Apte added the comment:
On 1 November 2012 17:21, Andrew Svetlov rep...@bugs.python.org wrote:
Andrew Svetlov added the comment:
I'm pretty sure Doc and Lib are already fixed, only Tools left.
--
nosy: +asvetlov
___
Python tracker
Andrew Svetlov added the comment:
Sorry, looks like I don't understood you correctly.
Do you want to replace `except:` to `except Exception` or something else?
--
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
Ramchandra Apte added the comment:
Yes.
most of the bare excepts can be replaced with a stricter clause
On 2 November 2012 01:06, Andrew Svetlov rep...@bugs.python.org wrote:
Andrew Svetlov added the comment:
Sorry, looks like I don't understood you correctly.
Do you want to replace
Changes by Ramchandra Apte maniandra...@gmail.com:
--
type: - behavior
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
___
Ramchandra Apte added the comment:
This seems quite difficult for one person;there are 589 lines having except:
I'll work on the Tools directory.
If anybody wants to help, please tell which folder you will do.
--
___
Python tracker
Changes by Éric Araujo mer...@netwok.org:
--
nosy: +eric.araujo
versions: +Python 3.4
___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue16261
___
___
New submission from Ramchandra Apte:
Will attach patch.
--
components: Library (Lib)
messages: 173140
nosy: ramchandra.apte
priority: normal
severity: normal
status: open
title: Fix bare excepts in various places in std lib
___
Python tracker
Brett Cannon added the comment:
One thing to be aware of, Ramchandra, is that there might be a slight
backwards-compatibility problem from tightening up what exceptions propagate.
Now with proper documentation and only applying things to 3.4 this probably
won't be a problem.
--
nosy:
25 matches
Mail list logo