[issue21295] Python 3.4 gives wrong col_offset for Call nodes returned from ast.parse

2014-04-19 Thread Aivar Annamaa
Aivar Annamaa added the comment: Regarding #16795, the documentation says The lineno is the line number of source text and the col_offset is the UTF-8 byte offset of the first token that generated the node, not that lineno and col_offset indicate a suitable position to mention in the error

[issue21200] pkgutil.get_loader() fails on __main__

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset bc4eb1b3db5d by Eric Snow in branch '3.4': Issue #21200: Return None from pkgutil.get_loader() when __spec__ is missing. http://hg.python.org/cpython/rev/bc4eb1b3db5d -- nosy: +python-dev ___ Python

[issue21200] pkgutil.get_loader() fails on __main__

2014-04-19 Thread Eric Snow
Eric Snow added the comment: The change is pretty minor so I went ahead and pushed it. To be honest, we should consider deprecating both get_loader and find_loader. I'm just not going to worry about it right now. :) -- resolution: - fixed stage: patch review - resolved status: open

[issue15002] urllib2 does not download 4 MB file completely using ftp

2014-04-19 Thread Senthil Kumaran
Senthil Kumaran added the comment: Christian's patch is good.It helps in setting the socket.makefile file descriptor to a well behaving well file close wrapper and thus will help us prevent some tricky fd close issues. I added tests for coverage to ensure that we are asserting the type and

[issue21226] PyImport_ExecCodeModuleObject not setting module attributes

2014-04-19 Thread Eric Snow
Eric Snow added the comment: Here's a (currently segfaulting) patch that demonstrates how I'd like to solve this. Feedback on the approach is welcome. :) When I get a chance I'll debug the segfault. -- assignee: - eric.snow keywords: +patch stage: - patch review Added file:

[issue10362] AttributeError: addinfourl instance has no attribute 'tell'

2014-04-19 Thread Senthil Kumaran
Senthil Kumaran added the comment: I agree. Having tell on a file descriptor of a URL request is not going to be of help. You can easily write to a local file and use all the local file features, if it is things like .tell is desired. -- resolution: - not a bug stage: needs patch -

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: Why exactly does it need to be backported? os.urandom under 2.7 works fine. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21305 ___

[issue21292] C API in debug fails

2014-04-19 Thread Martin v . Löwis
Martin v. Löwis added the comment: I think the issue is actually slightly different. You can certainly build your Python in debug, and still link with the release mode Python. The question is what in debug means, and the normal definition would be with the generation of debug symbols by the

[issue21308] PEP 466: backport ssl changes

2014-04-19 Thread Cory Benfield
Changes by Cory Benfield c...@lukasa.co.uk: -- nosy: +Lukasa ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21308 ___ ___ Python-bugs-list mailing

[issue21308] PEP 466: backport ssl changes

2014-04-19 Thread Christian Heimes
New submission from Christian Heimes: I'm interested to assist with all back port tickets as soon as my internet connection is fixed. A technician is going to check my line again on Tuesday. -- ___ Python tracker rep...@bugs.python.org

[issue21308] PEP 466: backport ssl changes

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: I'm not really interested to assist with backport tickets myself. You may nosy me but I may not care at all :) -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21308

[issue21287] Better support for AF_PACKET on opensolaris (illumos)

2014-04-19 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: +neologix stage: - patch review versions: +Python 3.5 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21287 ___

[issue21311] Fix compiler detection when brew's ccache is installed on Mac OS X

2014-04-19 Thread John Szakmeister
New submission from John Szakmeister: It's pretty typical for ccache packages to install symlinks for compilers that may not be present on the system, such as Homebrew's ccache package. Unfortunately, the _osx_support.py file is mislead by the presence of the symlink and ends up backtracing.

[issue21311] Fix compiler detection when brew's ccache is installed on Mac OS X

2014-04-19 Thread John Szakmeister
John Szakmeister added the comment: Here's the alternate fix. -- Added file: http://bugs.python.org/file34973/alt-fix-osx-llvm-detection-with-ccache.patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21311

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Nick Coghlan
Nick Coghlan added the comment: It was in the list of security fixes Alex and Donald wanted to reduce vulnerabilities in 2.x network services, and Guido was OK with backporting it. -- ___ Python tracker rep...@bugs.python.org

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: It was in the list of security fixes Alex and Donald wanted to reduce vulnerabilities in 2.x network services, and Guido was OK with backporting it. What security issue is there exactly? os.urandom() does a similar thing in 2.7 and 3.x (it reads from

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Alex Gaynor
Alex Gaynor added the comment: It's not a security issue per-se, but if you're doing many small reads, there's such an enormous performance and scalability difference that if users run into an issue, they're likely to work around it by using a non-CS PRNG, and compromising their application

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: It's not a security issue per-se, but if you're doing many small reads, there's such an enormous performance and scalability difference that if users run into an issue, they're likely to work around it by using a non-CS PRNG, and compromising their

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: Note that the 3.4 scheme is not fully debugged yet: issue21207. There is a reason we don't backport new features! Regardless, I'm not interested in this, so I'll let you take the risk of regressions if you want to. --

[issue21305] PEP 466: update os.urandom

2014-04-19 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- nosy: -pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21305 ___ ___ Python-bugs-list mailing

[issue21207] urandom persistent fd - not re-openned after fd close

2014-04-19 Thread Alex Gaynor
Changes by Alex Gaynor alex.gay...@gmail.com: -- nosy: +alex ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21207 ___ ___ Python-bugs-list mailing

[issue18967] Find a less conflict prone approach to Misc/NEWS

2014-04-19 Thread Senthil Kumaran
Changes by Senthil Kumaran sent...@uthcode.com: -- nosy: -orsenthil ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue18967 ___ ___ Python-bugs-list

[issue16827] Remove the relatively advanced content from section 2 in tutorial

2014-04-19 Thread Senthil Kumaran
Senthil Kumaran added the comment: For this bug, I think, section 2.2.4 and section 2.2.5 can be moved to section 13 and inserted between section 13.1 and 13.2 as it seem to be fit in naturally there. -- ___ Python tracker rep...@bugs.python.org

[issue2052] Allow changing difflib._file_template character encoding.

2014-04-19 Thread Senthil Kumaran
Changes by Senthil Kumaran sent...@uthcode.com: -- nosy: -orsenthil ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue2052 ___ ___ Python-bugs-list

[issue21226] PyImport_ExecCodeModuleObject not setting module attributes

2014-04-19 Thread Benjamin Peterson
Benjamin Peterson added the comment: The last argument to _PyObject_CallMethodIdObjArgs needs to be NULL... -- nosy: +benjamin.peterson ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21226

[issue9364] some problems with the documentation of pydoc

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset 16207b8495bf by R David Murray in branch '3.4': #9364: Improve the text printed by help(pydoc) and help(help). http://hg.python.org/cpython/rev/16207b8495bf New changeset 256c782ab078 by R David Murray in branch 'default': Merge: #9364: Improve the

[issue9364] some problems with the documentation of pydoc

2014-04-19 Thread R. David Murray
R. David Murray added the comment: Thanks, Glenn. I tweaked the wording further. If someone thinks it is worth the effort to backport this to 2.7, they can do so and reopen the issue. -- assignee: eric.araujo - nosy: +r.david.murray resolution: - fixed stage: needs patch - resolved

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Jack McCracken
New submission from Jack McCracken: The thread_foobar.h reference for the interface for abstracting the platform-specific thread implementation does not include newer features such as timed locking and TLS support. -- components: Interpreter Core files: update_thread_foobar.diff

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Jack McCracken
Jack McCracken added the comment: Missed a word in a comment -- Added file: http://bugs.python.org/file34975/update_thread_foobar_v2.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21312

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: You may want to provide an implementation of PyThread_acquire_lock() that simply defers to PyThread_acquire_lock_timed() (see thread_pthread.h, which does the same). -- nosy: +pitrou ___ Python tracker

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Jack McCracken
Jack McCracken added the comment: Added an example of deferring to PyThread_acquire_lock_timed in PyThread_acquire_lock. Also fixed a mistake in the string of a dprintf in PyThread_acquire_lock_timed. -- Added file: http://bugs.python.org/file34976/update_thread_foobar_v3.diff

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: Hum, your comment about deferring is wrong, since thread_nt.h also does the deferring: int PyThread_acquire_lock(PyThread_type_lock aLock, int waitflag) { return PyThread_acquire_lock_timed(aLock, waitflag ? -1 : 0, 0); } --

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Jack McCracken
Jack McCracken added the comment: Oops... I removed that and just put the deferral in there. -- Added file: http://bugs.python.org/file34977/update_thread_foobar_v4.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21312

[issue21312] Update thread_foobar.h to include timed locking and TLS support

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: Thanks! The patch looks good to me, I'll let it sleep a bit to see if other people have an opinion. -- nosy: +tim.peters stage: - patch review versions: +Python 3.5 ___ Python tracker rep...@bugs.python.org

[issue7221] DispatcherWithSendTests_UsePoll with test_asyncore does nothing

2014-04-19 Thread Jessica McKellar
Jessica McKellar added the comment: This looks like a copy-paste typo from test_asynchat, which does use `usepoll`. Attached is a patch that removes `usepoll` and a `DispatcherWithSendTests_UsePoll` TestCase that did nothing but set `usepoll=True`. * The diff passes `make patchcheck`. * The

[issue21311] Fix compiler detection when brew's ccache is installed on Mac OS X

2014-04-19 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- assignee: - ned.deily nosy: +ned.deily ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21311 ___ ___

[issue7221] DispatcherWithSendTests_UsePoll with test_asyncore does nothing

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset cbe7b5a5a110 by Antoine Pitrou in branch 'default': Issue #7221: remove redundant tests in test_asyncore. Patch by Jessica McKellar. http://hg.python.org/cpython/rev/cbe7b5a5a110 -- nosy: +python-dev

[issue7221] DispatcherWithSendTests_UsePoll with test_asyncore does nothing

2014-04-19 Thread Antoine Pitrou
Antoine Pitrou added the comment: Now committed. Thanks for the patch! -- resolution: - fixed stage: patch review - resolved status: open - closed versions: +Python 3.5 -Python 2.7, Python 3.1, Python 3.2 ___ Python tracker rep...@bugs.python.org

[issue21311] Fix compiler detection when brew's ccache is installed on Mac OS X

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset e3217efa6edd by Ned Deily in branch '2.7': Issue #21311: Avoid exception in _osx_support with non-standard compiler http://hg.python.org/cpython/rev/e3217efa6edd New changeset 3d1578c705c9 by Ned Deily in branch '3.4': Issue #21311: Avoid exception

[issue21311] Fix compiler detection when brew's ccache is installed on Mac OS X

2014-04-19 Thread Ned Deily
Ned Deily added the comment: Thanks for the report and the patches. I am not sure exactly what problem using ccache is causing but it is clear that, if for whatever reason the call to _read_output fails and returns None, the 'llvm-gcc' test will fail so that test should be fixed as suggested

[issue21121] -Werror=declaration-after-statement is added even for extension modules through setup.py

2014-04-19 Thread Ned Deily
Ned Deily added the comment: Stefan, the patch LGTM although I sure wish we were removing some CFLAGS-related configuration variables rather than adding another. But I don't have a better suggestion short of a comprehensive cleanup of all of them. -- stage: - commit review versions:

[issue4744] asynchat documentation needs to be more precise

2014-04-19 Thread R. David Murray
R. David Murray added the comment: The change covered by the patch (which patch rejected as garbage, by the way, I have no idea why) has already been applied by Serhiy Storchaka, apparently as a blanked change of 'empty string' to 'empty bytes object'. There are several other places in the

[issue4744] asynchat documentation needs to be more precise

2014-04-19 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- Removed message: http://bugs.python.org/msg216880 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4744 ___

[issue4744] asynchat documentation needs to be more precise

2014-04-19 Thread R. David Murray
R. David Murray added the comment: The change covered by the patch (which patch rejected as garbage, by the way, I have no idea why) has already been applied by Serhiy Storchaka, apparently as a blanket change of 'empty string' to 'empty bytes object'. There are several other places in the

[issue13966] Add disable_interspersed_args() to argparse.ArgumentParser

2014-04-19 Thread paul j3
paul j3 added the comment: http://bugs.python.org/issue14191 implements the other side of optparse behavior - allowing a complete intermixing of optionals and positionals. It does that with a new 'ArgumentParser.parse_intermixed_args()' method. --

[issue21313] Py_GetVersion() is broken when using mqueue and a long patch name

2014-04-19 Thread Eric Snow
New submission from Eric Snow: Py_GetVersion() (in Python/getversion.c) builds the version string returned by sys.version: PyOS_snprintf(version, sizeof(version), %.80s (%.80s) %.80s, PY_VERSION, Py_GetBuildInfo(), Py_GetCompiler()); In turn, Py_GetBuildInfo() (in

[issue21311] Fix compiler detection when brew's ccache is installed on Mac OS X

2014-04-19 Thread John Szakmeister
John Szakmeister added the comment: Thank you Ned! The issue is that you can create symlinks to ccache to and put them on your path. Distros do this for you now, but most create symlinks for a bunch of compilers... including ones that may not be installed. So the presence of the name

[issue10291] Clean-up turtledemo in-package documentation

2014-04-19 Thread Jessica McKellar
Jessica McKellar added the comment: Thanks for the bug report and patch, belopolsky! The original patch no longer applies cleanly, so attached is a regenerated version. * The new patch passes `make patchcheck`. * The full test suite passes with this patch. * I manually tested that before the

[issue21226] PyImport_ExecCodeModuleObject not setting module attributes

2014-04-19 Thread Eric Snow
Eric Snow added the comment: Thanks, Benjamin. Here's an updated patch that passes all tests. It should be good to go. And yet again our zipimport implementation was a pain point. :( -- Added file: http://bugs.python.org/file34980/fix-PyImport_ExecCodeModuleObject.diff

[issue21302] time.sleep (floatsleep()) should use clock_nanosleep() on Linux

2014-04-19 Thread akira
Changes by akira 4kir4...@gmail.com: -- nosy: +akira ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21302 ___ ___ Python-bugs-list mailing list

[issue8387] use universal newline mode in csv module examples

2014-04-19 Thread Jessica McKellar
Jessica McKellar added the comment: I ran some experiments to see what the state of the world is. I generated a test.csv by exporting a CSV file from Numbers on OSX. This generated a file with Windows-style \r\n-terminated lines. The attached test_csv.py tries to open this CSV file in binary

[issue8387] use universal newline mode in csv module examples

2014-04-19 Thread Jessica McKellar
Changes by Jessica McKellar jesst...@mit.edu: Added file: http://bugs.python.org/file34982/test.csv ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue8387 ___

[issue8387] use universal newline mode in csv module examples

2014-04-19 Thread Jessica McKellar
Jessica McKellar added the comment: All of the examples from https://docs.python.org/3/library/csv.html run without issue on OSX, though. In summary, the Python 2 examples error out on OSX and switching them to use 'U' instead of 'b' would fix this. I don't think any action needs to be taken

[issue11571] Turtle window pops under the terminal on OSX

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset 1f3946b22e64 by Ned Deily in branch '3.4': Issue #11571: Ensure that the turtle window becomes the topmost window http://hg.python.org/cpython/rev/1f3946b22e64 New changeset 01228d7b5e01 by Ned Deily in branch 'default': Issue #11571: merge with

[issue10291] Clean-up turtledemo in-package documentation

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset 004fe3449193 by Ned Deily in branch 'default': Issue #10291: Cleanup turtledemo to use docstrings for help. http://hg.python.org/cpython/rev/004fe3449193 -- nosy: +python-dev ___ Python tracker

[issue11571] Turtle window pops under the terminal on OSX

2014-04-19 Thread Ned Deily
Changes by Ned Deily n...@acm.org: -- versions: +Python 3.4, Python 3.5 -Python 2.7, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11571 ___

[issue11571] Turtle window pops under the terminal on OSX

2014-04-19 Thread Ned Deily
Ned Deily added the comment: The fix for turtle has been applied for release in 3.4.1 and 3.5.0. -- resolution: wont fix - fixed stage: commit review - resolved ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue11571

[issue8387] use universal newline mode in csv module examples

2014-04-19 Thread Mark Lawrence
Mark Lawrence added the comment: I think that it's complete nonsense to talk about binary csv files on Windows. They are just plain text files that can be manipulated with any old editor or a spreadsheet. -- nosy: +BreamoreBoy ___ Python tracker

[issue10291] Clean-up turtledemo in-package documentation

2014-04-19 Thread Ned Deily
Ned Deily added the comment: Thanks for the refresh, Jessica. I decided to separate out the turtle window raise for OS X and apply that for 3.4.1 and 3.5.0 in Issue11571. The remainder of the patch to use the docstrings, plus removal of the two other obsolete text files, is spplied here for

[issue8387] use universal newline mode in csv module examples

2014-04-19 Thread R. David Murray
R. David Murray added the comment: The magic of newline='' in python3 is that it *preserves* the line end characters, which is the same thing binary mode does on windows. The place that matters, as I remember it, is when there is a newline embedded inside a quoted string. I don't remember

[issue21296] smtplib Sends Commands in Lower-Case

2014-04-19 Thread Luiji Maryo
Luiji Maryo added the comment: Apologies, I was tired when I looked into this. It turns out that SMTP is explicitly case-insensitive with command names. I still think it'd be nice to use upper-case commands for consistency with the FROM: and TO: lines, though, or to put the FROM: and TO:

[issue21296] smtplib Sends Commands in Lower-Case

2014-04-19 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- components: +email nosy: +barry, r.david.murray ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21296 ___

[issue837046] pyport.h redeclares gethostname() if SOLARIS is defined

2014-04-19 Thread R. David Murray
R. David Murray added the comment: Can you confirm that this is really still a problem, despite the Solaris cleanup in issue 1759169? -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue837046

[issue12220] minidom xmlns not handling spaces in xmlns attribute value field

2014-04-19 Thread Roundup Robot
Roundup Robot added the comment: New changeset 13c1c5e3d2ee by R David Murray in branch '3.4': #12220: improve minidom error when URI contains spaces. http://hg.python.org/cpython/rev/13c1c5e3d2ee New changeset 3e67d923a0df by R David Murray in branch 'default': Merge: #12220: improve minidom

[issue12220] minidom xmlns not handling spaces in xmlns attribute value field

2014-04-19 Thread R. David Murray
R. David Murray added the comment: Thanks, amathew and Marek. -- resolution: - fixed stage: needs patch - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue12220

[issue21221] Minor struct_time documentation bug

2014-04-19 Thread R. David Murray
Changes by R. David Murray rdmur...@bitdance.com: -- nosy: +belopolsky ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21221 ___ ___