[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-18 Thread Terry J. Reedy
Terry J. Reedy tjre...@udel.edu added the comment: the interfaces of the v4 and v6 variants are deliberately very similar I am hoping that means 'identical, once the obvious translations are made': v4 to v6, xxx.xxx.xxx.xxx to whatever the v6 notation is, and anything else? documenting

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-18 Thread Nick Coghlan
Nick Coghlan ncogh...@gmail.com added the comment: My current thoughts are to avoid the usual approach of embedding the method and property definitions in the class definitions, and instead have separate sections under [1] for IP Addresses IP Interfaces IP Networks Inside each of those

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-18 Thread Hynek Schlawack
Hynek Schlawack h...@ox.cx added the comment: Martin, what exactly is the intended proceeding now? Are you going to fix your patch and tests as soon as you have time or was that just a PoC and expect me/us to bring it into shape? (- troll-free question, I have no idea what to do next here and

[issue15036] mailbox.mbox fails to pop two items in a row, flushing in between

2012-06-18 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 8b38a81ba3bf by Petri Lehtinen in branch '2.7': Fix NEWS entry for #15036 http://hg.python.org/cpython/rev/8b38a81ba3bf New changeset 38e2a87c9051 by Petri Lehtinen in branch '3.2': Fix NEWS entry for #15036

[issue15036] mailbox.mbox fails to pop two items in a row, flushing in between

2012-06-18 Thread Petri Lehtinen
Petri Lehtinen pe...@digip.org added the comment: Perfect, fixed. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15036 ___ ___ Python-bugs-list

[issue4489] shutil.rmtree is vulnerable to a symlink attack

2012-06-18 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Martin, what exactly is the intended proceeding now? Are you going to fix your patch and tests as soon as you have time or was that just a PoC and expect me/us to bring it into shape? (- troll-free question, I have no idea what to do next

[issue9559] mailbox.mbox creates new file when adding message to mbox

2012-06-18 Thread Petri Lehtinen
Petri Lehtinen pe...@digip.org added the comment: This is actually not true. When calling add(), mbox (and MMDF and Babyl) append the message to the file without rewriting it. It's the following flush() call that rewrites the whole mailbox contents. I think this could be changed to work

[issue3665] Support \u and \U escapes in regexes

2012-06-18 Thread Serhiy Storchaka
Serhiy Storchaka storch...@gmail.com added the comment: I forgot about byte patterns. Here is an updated patch. -- Added file: http://bugs.python.org/file26040/re_unicode_escapes-3.patch ___ Python tracker rep...@bugs.python.org

[issue1590744] mail message parsing glitch

2012-06-18 Thread Petri Lehtinen
Changes by Petri Lehtinen pe...@digip.org: -- nosy: +petri.lehtinen ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1590744 ___ ___ Python-bugs-list

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread John Firestone
New submission from John Firestone jo...@freenet.de: exec(source, Dict()) doesn't call Dict().__getitem__ or Dict().__missing__ if the source string contains a function and the function references an undefined global. class Dict1(dict): def __getitem__(self, key): print '

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-18 Thread Radoslaw A. Zarzynski
New submission from Radoslaw A. Zarzynski radoslaw.zarzyn...@student.put.poznan.pl: shutil.copy and shutil.copy2 first copy a file content and afterwards change permissions of a destination file. Unfortunately, the sequence isn't atomical and may lead to disclosure of matter of any file that

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-18 Thread Radoslaw A. Zarzynski
Changes by Radoslaw A. Zarzynski radoslaw.zarzyn...@student.put.poznan.pl: Added file: http://bugs.python.org/file26043/python_shutil_copy_with_umask.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15100

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-18 Thread Florent Xicluna
Changes by Florent Xicluna florent.xicl...@gmail.com: -- components: +IO nosy: +flox ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15100 ___ ___

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: This looks like a documentation issue: it's well documented that in the exec statement, the globals dictionary must be a dict. What's not so clear from the documentation (AFAICT) is that it must actually have *type* dict, rather than

[issue15100] Race conditions in shutil.copy, shutil.copy2 and shutil.copyfile

2012-06-18 Thread Hynek Schlawack
Changes by Hynek Schlawack h...@ox.cx: -- nosy: +hynek ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15100 ___ ___ Python-bugs-list mailing list

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread John Firestone
John Firestone jo...@freenet.de added the comment: I find the behavior inconsistent. As you can see from this example, the exec'uted code *does* call the instance's overloaded __getitem__ and __missing__ methods when outside a function, but doesn't when inside. --

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: As you can see from this example, the exec'uted code *does* call the instance's overloaded __getitem__ and __missing__ methods when outside a function, but doesn't when inside. Yep; that's because the 's' and 'f' lookups at top level

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: With Python3 though, __getitem__ seems called though. OTOH the 'print' symbol is not found, even though the Dict1 got a '__builtins__' entry added. -- nosy: +amaury.forgeotdarc ___ Python

[issue15101] multiprocessing pool finalizer can fail if triggered in background pool thread

2012-06-18 Thread Richard Oudkerk
New submission from Richard Oudkerk shibt...@gmail.com: Multiprocessing's process pool originally used a finalizer to shutdown the pool when the pool object is garbage collected. Since the maxtasksperchild feature was added, the worker_handler thread holds a reference to the pool, preventing

[issue15102] Fix 64-bit building for buildbot scripts

2012-06-18 Thread Jeremy Kloth
New submission from Jeremy Kloth jeremy.kloth+python-trac...@gmail.com: The buildbot scripts do not work for the 64-bit targets. Firstly, the /p:UseEnv=True parameter to msbuild causes the 32-bit only projects (make_buildinfo and make_versioninfo) to fail due to architecture mismatch. The

[issue15052] Outdated comments in build_ssl.py

2012-06-18 Thread Jeremy Kloth
Jeremy Kloth jeremy.kloth+python-trac...@gmail.com added the comment: In addition to the fixes from issue15102, the only way I could get the ssl project to build successfully was to add the Perl installation (C:\Perl\bin) to my PATH. -- ___ Python

[issue15040] stdlib compatibility with pypy: mailbox module

2012-06-18 Thread Éric Araujo
Changes by Éric Araujo mer...@netwok.org: -- title: stdlib compatability with pypy: mailbox.py - stdlib compatibility with pypy: mailbox module ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15040

[issue15052] Outdated comments in build_ssl.py

2012-06-18 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Again: installing Perl should not be necessary. That it is currently necessary is a bug in the sources. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15052

[issue15052] Outdated comments in build_ssl.py

2012-06-18 Thread Jeremy Kloth
Jeremy Kloth jeremy.kl...@gmail.com added the comment: Should I then open another issue just to track that bug? Have you even tried using build_ssl.py *without* Perl? The changes required to get that to work seem fairly extensive. -- ___ Python

[issue15101] multiprocessing pool finalizer can fail if triggered in background pool thread

2012-06-18 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 4c07b9c49b75 by Richard Oudkerk in branch '2.7': Issue #15101: Make pool finalizer avoid joining current thread http://hg.python.org/cpython/rev/4c07b9c49b75 New changeset e1cd1f430ff1 by Richard Oudkerk in branch

[issue15064] multiprocessing should use more context manager

2012-06-18 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 6d2a773d8e00 by Richard Oudkerk in branch 'default': Issue #15064: Implement context manager protocol for multiprocessing types http://hg.python.org/cpython/rev/6d2a773d8e00 -- nosy: +python-dev

[issue14814] Implement PEP 3144 (the ipaddress module)

2012-06-18 Thread pmoody
pmoody pyt...@hda3.com added the comment: I'm not sure if this is still an issue, but returning the address in a packed format was an early issue (http://code.google.com/p/ipaddr-py/issues/detail?id=14). No objections from me for removing it from the network objects or for removing the packed

[issue7360] [mailbox] race: mbox may lose data with concurrent access

2012-06-18 Thread Petri Lehtinen
Petri Lehtinen pe...@digip.org added the comment: Can this be closed? -- nosy: +petri.lehtinen ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue7360 ___

[issue5346] mailbox._singlefileMailbox.flush doesn't preserve file rights

2012-06-18 Thread Petri Lehtinen
Changes by Petri Lehtinen pe...@digip.org: -- nosy: +petri.lehtinen ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5346 ___ ___ Python-bugs-list

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread John Firestone
John Firestone jo...@freenet.de added the comment: Thank you all for the quick and interesting responses! Here is another example, this time showing a simple s sometimes behaves like globals()['s'] and sometimes doesn't. class Dict(dict): def __getitem__(self, key): if key

[issue7360] [mailbox] race: mbox may lose data with concurrent access

2012-06-18 Thread R. David Murray
R. David Murray rdmur...@bitdance.com added the comment: Probably. Unless I'm mistaken, the issue with concurrent rewrite (as opposed to append) exists for single-file-mailboxes in the general case, not just in Python. And as far as I know failure is never noisy, the last writer wins.

[issue7359] mailbox cannot modify mailboxes in system mail spool

2012-06-18 Thread Petri Lehtinen
Petri Lehtinen pe...@digip.org added the comment: Every program that accesses mailboxes in the system-wide mail spool directory needs to have write access to it. This is because dot-locking is achieved by creating additional files to that directory, and it must be used (in addition to fcntl()

[issue15099] exec of function doesn't call __getitem__ or __missing__ on undefined global

2012-06-18 Thread Mark Dickinson
Mark Dickinson dicki...@gmail.com added the comment: Yes, this is definitely a dark corner of Python, and one that it seems worth trying to illuminate a bit in the documentation. -- ___ Python tracker rep...@bugs.python.org

[issue15052] Outdated comments in build_ssl.py

2012-06-18 Thread Jeremy Kloth
Jeremy Kloth jeremy.kloth+python-trac...@gmail.com added the comment: OK, I have discovered my issue(s) building OpenSSL. When I first downloaded the openssl-1.0.1c external, the timestamps for the .asm files ended up being older than their corresponding .pl sources therefore triggering the

[issue15042] Implemented PyState_AddModule, PyState_RemoveModule

2012-06-18 Thread Robin Schreiber
Robin Schreiber robin.schrei...@me.com added the comment: Added missing documentation. Also added documentation of PyState_FindModule() which still happened to be missing. -- Added file: http://bugs.python.org/file26046/PyState_add-remove_module_v2.patch

[issue15052] Outdated comments in build_ssl.py

2012-06-18 Thread Jeremy Kloth
Jeremy Kloth jeremy.kloth+python-trac...@gmail.com added the comment: I forgot to add that with the patch the comment wrt Perl is truly correct. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15052

[issue15096] Drop support for the ur string prefix

2012-06-18 Thread Arfrever Frehtes Taifersar Arahesis
Changes by Arfrever Frehtes Taifersar Arahesis arfrever@gmail.com: -- nosy: +Arfrever ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15096 ___

[issue15102] Fix 64-bit building for buildbot scripts

2012-06-18 Thread Antoine Pitrou
Changes by Antoine Pitrou pit...@free.fr: -- keywords: +patch Added file: http://bugs.python.org/file26047/2a20cee18add.diff ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15102 ___

[issue13512] ~/.pypirc created insecurely

2012-06-18 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: Eric, do you plan to fix this soon? Linux distributions have started patched their Pythons manually. -- nosy: +pitrou ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue13512

[issue14684] zlib set dictionary support inflateSetDictionary

2012-06-18 Thread Jesús Cea Avión
Jesús Cea Avión j...@jcea.es added the comment: Sam, the window for Python 3.3 integration is almost close. Could you possibly update your patch with Nadeem's feedback?. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14684

[issue15064] multiprocessing should use more context manager

2012-06-18 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 198382b4bcd0 by Richard Oudkerk in branch 'default': Issue #15064: Make BaseManager.__enter__() start server if necessary. http://hg.python.org/cpython/rev/198382b4bcd0 New changeset 836d712461b3 by Richard Oudkerk

[issue15038] Optimize python Locks on Windows

2012-06-18 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 978326f98316 by Kristján Valur Jónsson in branch 'default': Issue #15038: Optimize python Locks on Windows http://hg.python.org/cpython/rev/978326f98316 -- nosy: +python-dev

[issue15102] Fix 64-bit building for buildbot scripts

2012-06-18 Thread Stefan Krah
Stefan Krah stefan-use...@bytereef.org added the comment: There's some unrelated stuff in the patch that reverts commits in mpdecimal.c and multiprocessing. Maybe a Rietveld issue. -- nosy: +skrah ___ Python tracker rep...@bugs.python.org

[issue15102] Fix 64-bit building for buildbot scripts

2012-06-18 Thread Jeremy Kloth
Jeremy Kloth jeremy.kl...@gmail.com added the comment: The unrelated changes do seem to be an issue with the diff generated by Rietveld -- nosy: +jeremy.kloth ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15102

[issue15102] Fix 64-bit building for buildbot scripts

2012-06-18 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: If I understand, the proposed changes are the following: https://bitbucket.org/jkloth/cpython-buildbot-amd64/changeset/2a20cee18add ? I'm not a Windows specialist, but they do seem a bit weird: - the pcbuild.sln changes remove Debug|x64.Build and

[issue15103] Solaris compiler chokes on importlib.h

2012-06-18 Thread Antoine Pitrou
New submission from Antoine Pitrou pit...@free.fr: The Solaris compiler chokes on the embedded NUL character. Perhaps we can find another way to remove the importlib.h diffs from the notification e-mails (simply hardcode the filename?).

[issue15052] Outdated comments in build_ssl.py

2012-06-18 Thread Martin v . Löwis
Martin v. Löwis mar...@v.loewis.de added the comment: Should I then open another issue just to track that bug? Have you even tried using build_ssl.py *without* Perl? The changes required to get that to work seem fairly extensive. The 3.3 tree works fine for me without Perl, I'm confident

[issue15038] Optimize python Locks on Windows

2012-06-18 Thread Antoine Pitrou
Antoine Pitrou pit...@free.fr added the comment: There's a problem here: Fatal Python error: PyCOND_SIGNAL(gil_cond) failed http://www.python.org/dev/buildbot/all/builders/x86%20XP-4%203.x/builds/6859/steps/test/logs/stdio -- ___ Python tracker

[issue15102] Fix 64-bit building for buildbot scripts

2012-06-18 Thread Jeremy Kloth
Jeremy Kloth jeremy.kl...@gmail.com added the comment: On Mon, Jun 18, 2012 at 3:27 PM, Antoine Pitrou rep...@bugs.python.org wrote: If I understand, the proposed changes are the following: https://bitbucket.org/jkloth/cpython-buildbot-amd64/changeset/2a20cee18add That seems to be correct,

[issue15038] Optimize python Locks on Windows

2012-06-18 Thread Richard Oudkerk
Richard Oudkerk shibt...@gmail.com added the comment: Py_LOCAL_INLINE(int) _PyCOND_WAIT_MS(PyCOND_T *cv, PyMUTEX_T *cs, DWORD ms) { DWORD wait; cv-waiting++; PyMUTEX_UNLOCK(cs); /* lost wakeup bug would occur if the caller were interrupted here, * but we are safe because we

[issue14772] Return destination values in some shutil functions

2012-06-18 Thread Roundup Robot
Roundup Robot devn...@psf.upfronthosting.co.za added the comment: New changeset 8281233ec648 by Brian Curtin in branch 'default': Fix #14772: Return the destination from some shutil functions. http://hg.python.org/cpython/rev/8281233ec648 -- nosy: +python-dev

[issue14772] Return destination values in some shutil functions

2012-06-18 Thread Brian Curtin
Changes by Brian Curtin br...@python.org: -- resolution: - fixed stage: commit review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue14772 ___

[issue15103] Solaris compiler chokes on importlib.h

2012-06-18 Thread Jesús Cea Avión
Changes by Jesús Cea Avión j...@jcea.es: -- nosy: +jcea ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue15103 ___ ___ Python-bugs-list mailing list

[issue14684] zlib set dictionary support inflateSetDictionary

2012-06-18 Thread Sam Rushing
Sam Rushing rushing@gmail.com added the comment: I think other than the disagreement about whether the dictionary constructor arg should be a buffer object, it's good to go. To restate my position: the need is for an immutable string of bytes, and that's exactly what PyBytes_Type is for.

[issue15103] Solaris compiler chokes on importlib.h

2012-06-18 Thread Justin Venus
Justin Venus justin.ve...@gmail.com added the comment: What is the purpose of the comment at the end of Python/importlib.h? If I remove the comment that states binary marker for mercurial (something to that effect anyhow) the code compiles and only the tests fail. -- nosy:

[issue3173] external strftime for Python?

2012-06-18 Thread Alexander Belopolsky
Alexander Belopolsky alexander.belopol...@gmail.com added the comment: IANA is now distributing Olson's timezone database software which includes an implementation of strftime(): http://www.iana.org/time-zones/repository/releases/tzcode2012b.tar.gz The code was designated as public domain by

[issue15008] PEP 362 Signature Objects reference implementation

2012-06-18 Thread Yury Selivanov
Yury Selivanov yseliva...@gmail.com added the comment: New version (pep363.4.patch) Summary: 1. Removed 'Signature.implemented' 2. No more patching built-ins - no issues with shared interpreters 3. Removed 'Signature.format()'. If needed we'll reintroduce it in 3.4 (although we still have

[issue15008] PEP 362 Signature Objects reference implementation

2012-06-18 Thread Yury Selivanov
Yury Selivanov yseliva...@gmail.com added the comment: Eric, I personally prefer simple 'signature()' more than 'get_signature()'. But I'll ask this question on python-dev on the next PEP update. -- ___ Python tracker rep...@bugs.python.org

[issue7584] datetime.rfcformat() for Date and Time on the Internet

2012-06-18 Thread Alexander Belopolsky
Alexander Belopolsky alexander.belopol...@gmail.com added the comment: I have reviewed RFC 3339 and it looks like the following produces a fully compliant timestamp: print(datetime(2000,1,1, tzinfo=timezone.utc).isoformat('T')) 2000-01-01T00:00:00+00:00 I see the following remaining issues:

[issue9527] Add aware local time support to datetime module

2012-06-18 Thread Alexander Belopolsky
Alexander Belopolsky alexander.belopol...@gmail.com added the comment: On Mon, Jun 11, 2012 at 11:18 PM, James Henstridge rep...@bugs.python.org wrote: One problem I can see with using a fixed offset tzinfo for localtime is that it might confuse people when doing date arithmetic. Yes, this

[issue9527] Add aware local time support to datetime module

2012-06-18 Thread Alexander Belopolsky
Alexander Belopolsky alexander.belopol...@gmail.com added the comment: ... is a well-defined problem which does not have an adequate solution. I meant to say does not have an adequate solution *in the current datetime module*. I think the enhanced datetime.astimezone() method will solve