[issue15746] test_winsound bombing out on 2003 buildslave

2012-08-22 Thread Trent Nelson

Trent Nelson added the comment:

Affirmative:


E:\Apps\activestate-python-2.7.2.5-x86python
ActivePython 2.7.2.5 (ActiveState Software Inc.) based on
Python 2.7.2 (default, Jun 24 2011, 12:21:10) [MSC v.1500 32 bit (Intel)] on 
win32
Type help, copyright, credits or license for more information.
 import test.test_winsound
 test.test_winsound._have_soundcard()
False
 import winsound
 winsound.PlaySound('!$%/(#+*', winsound.SND_ALIAS | 
 winsound.SND_NODEFAULT)


No exception raised.  (No sound is played, either, FWIW.)

I like the approach taken by the method before test_alias_nofallback():

def test_alias_fallback(self):
# This test can't be expected to work on all systems.  The MS
# PlaySound() docs say:
#
# If it cannot find the specified sound, PlaySound uses the
# default system event sound entry instead.  If the function
# can find neither the system default entry nor the default
# sound, it makes no sound and returns FALSE.
#
# It's known to return FALSE on some real systems.

# winsound.PlaySound('!$%/(#+*', winsound.SND_ALIAS)
return

I suspect that'll solve all our problems ;-)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15746
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7741] Allow multiple statements in code.InteractiveConsole.push

2012-08-22 Thread Kristján Valur Jónsson

Kristján Valur Jónsson added the comment:

What's the purpose of the new patch, particularly 2/2 since it is equivalent to 
multiple push() calls?
I.e. since this issue has laid dormant for two years, what prompts the sudden 
activity?

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7741
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1207589] Right Click Context Menu

2012-08-22 Thread Nashev

Nashev added the comment:

display assigned hot keys in popup menu is must-have feature, that allow users 
to teach them while using commands by menu or by context menu. For examples 
look Delphi IDE

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1207589
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Chris Jerdonek

Chris Jerdonek added the comment:

Should this issue be fixed before the release?  If it is not fixed, certain 
problems found after the release may become harder to report and diagnose 
(because the true source of error will be masked).

Two months ago issue 15111 which was thought to be the same was given a 
priority of high.

--
nosy: +georg.brandl, r.david.murray

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5088] optparse: inconsistent default value for append actions

2012-08-22 Thread Louis Deflandre

Louis Deflandre added the comment:

Hello,

Tell me if the issue is too old to deserve comments anymore. But I would like 
to challenge the conclusion made in this issue.

The message msg9944 stated Think of the default as the initial list but it is 
inconsistent with the proper meaning of default which can be defined as : a 
preselected option adopted by a computer program or other mechanism WHEN NO 
ALTERNATIVE IS SPECIFIED (http://www.wordreference.com/definition/default - 
Oxford Dictionary).

The initial list conclusion seems to me more implementation oriented than 
really user oriented

--
nosy: +louis.deflandre

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5088
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue10852] SSL/TLS sni use in smtp, pop, imap, nntp, ftp client libs by default

2012-08-22 Thread danblack

danblack added the comment:

 Thanks for the patch
 Daniel. 3.3 is nearing the release candidate phase, so I'm re-targetting to 
 3.4. I'll take a detailed look soon.

Welcome. Just noticed conflicts with #4473 in the client POP implementation. 
Hopefully they are close anyway.

 (I suppose there's no easy way to write automated tests for this, 
 unfortunately)
Well since #8109 writes the server SNI its getting easier.

In Lib/test/test_ssl.py combined with the changes of #8109 it would seem that 
changing ConnectionHandler.run to respond to AUTH TLS, AUTH SSL (ftp) and 
STLS for pop (preempt #4473).

Changing server_params_test to support a proper arguments that correspond the 
the client protocol would be the way to do it.

 By the way, could you sign a contributor agreement
yes - emailed in.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue10852
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14292] OS X installer build script doesn't set $CXX, so it ends up as c++

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

The attached patch sets not just 'CC' but 'CXX' as well.

I haven't tested the patch beyond building on an OSX 10.8 system (that is, the 
primary use of the script is not tested)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14292
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7741] Allow multiple statements in code.InteractiveConsole.push

2012-08-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Aaron was looking for something to work on for the PyConAU sprints, and set 
himself the task of closing as many issues related to the code module as 
possible.

The main outcome of that was the new test suite added in #12643, which should 
make it easier to work on the module (at least in 3.3+)

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7741
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15757] ./configure --with-pydebug on FreeBSD results in -O2 -pipe eventually ending up in CFLAGS.

2012-08-22 Thread Stefan Krah

Stefan Krah added the comment:

 So, looks like FreeBSD's /usr/share/mk/sys.mk is to blame here.
 It unconditionally sets CFLAGS to `-O2 -pipe`.

I've been debugging this once, too. My conclusion was that if the OS is set up
that way, we shouldn't do anything about it in the Python source tree.

All important features of --with-pydebug should also work if -O0 is overridden
by -O2.

So I think that FreeBSD users who really want -O0 should change sys.mk
or set CFLAGS manually. For the buildbots it should not matter, except
that compile times are slower.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15757
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14292] OS X installer build script doesn't set $CXX, so it ends up as c++

2012-08-22 Thread Ronald Oussoren

Changes by Ronald Oussoren ronaldousso...@mac.com:


Added file: http://bugs.python.org/file26957/issue14292.txt

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14292
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13405] Add DTrace probes

2012-08-22 Thread Samuel John

Samuel John added the comment:

On OS X 10.8 with Xcode only (no command line tools), I get the following err 
(when using clang or when using llvm-gcc):

```
dtrace: failed to compile script ./Include/pydtrace.d: Preprocessor not found
make: *** [Include/pydtrace.h] Error 1
```

At homebrew we optionally try to apply your patch to python 
https://github.com/mxcl/homebrew/pull/14343.

I'd really like to be able to make the Command Line Tools for Xcode optional.

Note, there is no cpp for clang. Usually, the CC=/path/to/clang just works. 
(I have seen CPP = $CC -E before, but that did *not* do the trick here).

Any ideas?

--
nosy: +samueljohn

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13405
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13370] test_ctypes fails when building python with clang

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

The change to ppc-ffi_darwin.c was unintentional and should be removed. I must 
have been sleeping during the merge, as I only intended to copy the files for 
i386/x86_64 and not for PPC as the latter architecture didn't have problems 
when compiled with clang.

I've copied the ppc-ffi_darwin.c file from Python's tree into the PyObjC tree 
to avoid problems when there are future merges.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13370
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15760] make install should generate grammar file

2012-08-22 Thread Lennart Regebro

New submission from Lennart Regebro:

If you install Python 3.3b2 with sudo make install, a standard way of 
installing it so that users don't have rights to install global modules, then 
everytime lib2to3.pgen2.driver.load_grammar() is called, it aims to generate a 
a grammar table and write it as a pickle to a cache file.

However, unless you are superuser when doing this, writing the file will of 
course fail, with a message similar to this:

INFO:root:Generating grammar tables from 
/opt/python33/lib/python3.3/lib2to3/PatternGrammar.txt
INFO:root:Writing grammar tables to 
/opt/python33/lib/python3.3/lib2to3/PatternGrammar3.3.0.beta.2.pickle
INFO:root:Writing failed:[Errno 13] Permission denied: 
'/opt/python33/lib/python3.3/lib2to3/PatternGrammar3.3.0.beta.2.pickle'

A workaround is to run the script that creates the above errors as superuser 
once, and the message goes away.

I think the correct thing to do here is for make install to Generate these 
grammar tables and write the pickle. 

Steps to reproduce:

1. Install Python 3.3.b2 with ./configure;make;sudo make install
2. Check out the Distribute sources: hg clone 
https://bitbucket.org/stefanholek/distribute;
3. Run the Distribute tests: python3.3 setup.py test

--
messages: 168854
nosy: lregebro
priority: normal
severity: normal
status: open
title: make install should generate grammar file
type: behavior
versions: Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15760
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15760] make install should generate grammar file

2012-08-22 Thread Lennart Regebro

Changes by Lennart Regebro rege...@gmail.com:


--
components: +Installation

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15760
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15760] make install should generate grammar file

2012-08-22 Thread Hynek Schlawack

Hynek Schlawack added the comment:

Seems related to #15645, no?

--
nosy: +hynek

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15760
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15761] Setting PYTHONEXECUTABLE can cause segfaults on OS X

2012-08-22 Thread Ned Deily

New submission from Ned Deily:

Setting the environment variable PYTHONEXECUTABLE can cause the interpreter to 
crash with a segfault or to otherwise fail during initialization.  Another 
manifestation is the failure of test test_osx_env with:

AssertionError: -10 != 2 : expected PYTHONEXECUTABLE == sys.executable

(-10 means the interpreter subprocess under test segfaulted)

I have not yet been able to identify the root cause or the minimum set of 
conditions to produce a crash.  So far it seems that the interpreter must be 
32-bit and running on 10.6 or later.  In all of the failures I've seen, 
PYTHONEXECUTABLE was set to an absolute path, not necessarily a valid path.  
When running a debug build, I've seen two failure modes:

Assertion failed: (value), function PyDict_SetItem, file 
Objects/dictobject.c, line 1197.

#0  0x942a9332 in __kill ()
#1  0x942a8932 in kill$UNIX2003 ()
#2  0x98563c0c in abort ()
#3  0x9859820b in __assert_rtn ()
#4  0x00091b0f in PyDict_SetItem (op=0x48f438, key=0x487610, value=0x0) at 
Objects/dictobject.c:1197
#5  0x0009669d in PyDict_SetItemString (v=0x48f438, key=0x30ccfd version, 
item=0x0) at Objects/dictobject.c:2695
#6  0x00245616 in make_impl_info (version_info=0x0) at ./Python/sysmodule.c:1525
#7  0x00244a00 in _PySys_Init () at ./Python/sysmodule.c:1690
#8  0x0022fdc1 in _Py_InitializeEx_Private (install_sigs=1, 
install_importlib=1) at Python/pythonrun.c:334
#9  0x00231577 in Py_InitializeEx (install_sigs=1) at Python/pythonrun.c:401
#10 0x0023159a in Py_Initialize () at Python/pythonrun.c:407
#11 0x00269138 in Py_Main (argc=3, argv=0x446028) at Modules/main.c:646


Also:
Could not find platform independent libraries prefix
Could not find platform dependent libraries exec_prefix
Consider setting $PYTHONHOME to prefix[:exec_prefix]
Fatal Python error: Py_Initialize: unable to load the file system codec
ImportError: No module named 'encodings'

#0  0x942a9332 in __kill ()
#1  0x942a8932 in kill$UNIX2003 ()
#2  0x98563c0c in abort ()
#3  0x001a8d09 in Py_FatalError (
msg=0x2506d4 Py_Initialize: unable to load the file system codec)
at Python/pythonrun.c:2358
#4  0x001a3320 in _Py_InitializeEx_Private (install_sigs=1, install_importlib=1)
at Python/pythonrun.c:374
#5  0x001a3442 in Py_InitializeEx (install_sigs=1) at Python/pythonrun.c:401
#6  0x001a3456 in Py_Initialize () at Python/pythonrun.c:407
#7  0x001cd0f2 in Py_Main (argc=1, argv=0x394028) at Modules/main.c:646
#8  0x25e7 in main (argc=1, argv=0xb994) at python.c:66

Inspecting and gdb stepping through main.c, getpath.c, and pythonrun.c has not 
uncovered anything obvious yet.  Note, there have been changes in these areas 
for 3.3 in support of venv and bug fixes.

PYTHONEXECUTABLE is a somewhat vestigial environment variable supported only on 
OS X.  AFAIK, it was only intended for used with the deprecated 
bundlebuilder.py tool but it is externally documented; it's also still used by 
IDLE.app initialization which is based on bundlebuilder.  So it might not be a 
release blocker to fix immediately but it is disquieting.  As there are other 
higher priority issues at the moment, I probably won't be able to get back to 
this until after rc1.

--
assignee: ronaldoussoren
components: Macintosh
messages: 168856
nosy: ned.deily, ronaldoussoren
priority: high
severity: normal
status: open
title: Setting PYTHONEXECUTABLE can cause segfaults on OS X
type: crash
versions: Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15761
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15760] make install should generate grammar file

2012-08-22 Thread Lennart Regebro

Lennart Regebro added the comment:

Yes, and for some reason it didn't show up when I searched for Grammar 10 
minutes ago, but now it does. :-) It's a duplicate, indeed.

--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15760
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15645] 2to3 Grammar pickles not created when upgrading to 3.3.0b2

2012-08-22 Thread Lennart Regebro

Lennart Regebro added the comment:

I can confirm that this is an issue on Ubuntu 12.04 as well, and that removing 
the existing pre 3.3b2 install before installing solves the problem.

--
nosy: +lregebro

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15645
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15762] Windows 8 certification

2012-08-22 Thread Aaron Galea

New submission from Aaron Galea:

Hi

We have an application created with python2.7 and created into an executable 
using py2exe. However we are getting an issue with Windows 8 certification due 
to compiler parameters. We would like to have this application Windows 8 
certified but we can't get pass the following warning:
===
Windows security features test 


WARNING 
Binary analyzer
•
Warning: The binary analyzer test detected the following errors: 
◦File C:\Program Files (x86)\TestApp\test.exe has failed the DBCheck check.
◦File C:\Program Files (x86)\TestApp\test.exe has failed the NXCheck check.

•
Impact if not fixed: If the app doesn’t use the available Windows protections, 
it can increase the vulnerability of customer's computer to malware. 

•
How to fix: Apply the SAFESEH, DYNAMICBASE, and NXCOMPAT options when you link 
the app. See link below for more information:
Fixing Binary Analyzer Errors 



In order to fix this issue I had to modify the file msvc9compiler.py by 
changing the following line from:

self.ldflags_shared = ['/DLL', '/nologo', '/INCREMENTAL:NO']

to

self.ldflags_shared = ['/DLL', '/nologo', '/INCREMENTAL:NO', '/DYNAMICBASE', 
'/SAFESEH', '/NXCOMPAT']

and rebuild py2exe. Once I have done this the test passed.

I could go about it by having local patch available to my team but preferably I 
try to avoid patching the standard python modules.

My question is if there is another way to do this? and whether it would be a 
good idea to include these flags in future distutils?

--
assignee: eric.araujo
components: Distutils
messages: 168859
nosy: agale031176, eric.araujo, tarek
priority: normal
severity: normal
status: open
title: Windows 8 certification
type: enhancement
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15762
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15761] Setting PYTHONEXECUTABLE can cause segfaults on OS X

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

There could be an off by one error in the decoding of PYTHONEXECUTABLE, 
mbstowcs will only add a NUL character when there is room for one and when the 
environment variable is all ASCII the buffer isn't large enough which means the 
argument to Py_SetProgramName is not NUL-terminated unless there happens to be 
a NUL byte just beyond the allocated buffer.

The attached patch ensures that there is room for a NUL character. I don't know 
if this actually fixes the crash as I've been unable to reproduce the issue 
(with various values of PYTHONEXECUBLE and with/without malloc checking 
environment variables (see malloc(3)).

--
Added file: http://bugs.python.org/file26958/issue15761.txt

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15761
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15761] Setting PYTHONEXECUTABLE can cause segfaults on OS X

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

I can now reproduce the isue:

env PYTHONHOME=/Library/Frameworks/Python.framework/Versions/3.3  
PYTHONEXECUTABLE=/bin/bash  MallocGuardEdges=1 MallocStackLogging=1 
MallocScribble=1 MallocStackLoggingNoCompact=1 MallocCheckHeapEach=1 arch -i386 
python3.3 -c 'import sys; print(sys.executable)'

This also fails with Python 3.2, but then it fails with a unicode error


UnicodeEncodeError: 'utf-8' codec can't encode character '\udffa' in position 
17: surrogates not allowed


The error goes away when I used a patched version of python.exe, but that's one 
was not a framework build. 

Next step: rebuild and reinstall the 3.3 framework with my patch and check that 
the problem goes away.

All of this on an OSX 10.8 box, deployment target 10.8 and archs=intel.

Other notes:
* The 'Malloc' variables aren't necessary to reproduce
* 'arch -i386' is necessary, no crash with 'arch -x86_64'

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15761
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15761] Setting PYTHONEXECUTABLE can cause segfaults on OS X

2012-08-22 Thread Ronald Oussoren

Changes by Ronald Oussoren ronaldousso...@mac.com:


--
versions: +Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15761
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk

Richard Oudkerk added the comment:

In each loop before calling read() the buffer size is recalculated based on the 
amount of space used, causing a realloc *regardless* of how much empty space is 
left in the buffer.  And each read is only producing a smallish chunk (5120 
bytes).

So assuming realloc fails to do an inplace realloc (and Windows is reputedly 
very bad at that) the amount of data copied will be O(n^2).

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk

Richard Oudkerk added the comment:

The attached patch (readall-resize.patch) makes the resizes only happen when 
the buffer is full.  It produces

amount = 1 MB; time taken = 0.02 secs; rate = 64.10 MB/s
amount = 2 MB; time taken = 0.03 secs; rate = 64.10 MB/s
amount = 4 MB; time taken = 0.06 secs; rate = 64.10 MB/s
amount = 8 MB; time taken = 0.08 secs; rate = 102.56 MB/s
amount = 16 MB; time taken = 0.17 secs; rate = 93.24 MB/s
amount = 32 MB; time taken = 0.31 secs; rate = 102.56 MB/s
amount = 64 MB; time taken = 0.70 secs; rate = 91.17 MB/s
amount = 128 MB; time taken = 1.81 secs; rate = 70.73 MB/s

--
Added file: http://bugs.python.org/file26959/readall-resize.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue11776] Constructor signatures missing in types module documentation

2012-08-22 Thread Nick Coghlan

Nick Coghlan added the comment:

Clarifying the request: the constructor signatures for internal types should be 
documented in http://docs.python.org/dev/library/types, rather than just 
listing the types.

If creation of new instances from Python is not supported, that should also be 
documented explicitly.

Some of the items are currently missing docstrings as well.

--
nosy: +ncoghlan
title: types.MethodType() params and usage is not documented - Constructor 
signatures missing in types module documentation

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11776
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk

Richard Oudkerk added the comment:

Alternative patch (readall-chunks.patch) which delegates to RawIOBase.readall() 
if the file cannot be stat-ed or appears to have size zero.

amount = 1 MB; time taken = 0.02 secs; rate = 64.10 MB/s
amount = 2 MB; time taken = 0.02 secs; rate = 128.21 MB/s
amount = 4 MB; time taken = 0.03 secs; rate = 128.20 MB/s
amount = 8 MB; time taken = 0.05 secs; rate = 170.94 MB/s
amount = 16 MB; time taken = 0.09 secs; rate = 170.94 MB/s
amount = 32 MB; time taken = 0.16 secs; rate = 205.13 MB/s
amount = 64 MB; time taken = 0.30 secs; rate = 215.92 MB/s
amount = 128 MB; time taken = 0.58 secs; rate = 221.76 MB/s

--
Added file: http://bugs.python.org/file26960/readall-chunks.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue11776] Constructor signatures missing in types module documentation

2012-08-22 Thread Nick Coghlan

Nick Coghlan added the comment:

The first easy part of this patch is to document the signatures for types in 
that module where that info is available in the docstring:

CodeType
FunctionType
LambdaType
SimpleNamespace
MethodType

The second easy part is that the following need to be documented as not 
supporting direct creation from Python code:

BuiltinFunctionType
BuiltinMethodType
FrameType
GeneratorType
GetSetDescriptorType
MemberDescriptorType
TracebackType 

This type does support direct creation and should be documented appropriately, 
but the docs should also direct readers to the preferred API in the imp module:

ModuleType (imp.new_module)


Finally, this one is missing both a docstring *and* signature documentation:
MappingProxyType

It's a simple API that accepts a single parameter (which must be a mapping) and 
returns a read-only view of the original mapping.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11776
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

 Alternative patch (readall-chunks.patch) which delegates to
 RawIOBase.readall() if the file cannot be stat-ed or appears to have
 size zero.

It seems we could do both (fix the resizing logic, and fallback on
chunks if the size is unknown).

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7741] Allow multiple statements in code.InteractiveConsole.push

2012-08-22 Thread Andrew Svetlov

Changes by Andrew Svetlov andrew.svet...@gmail.com:


--
nosy: +asvetlov

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7741
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15762] Windows 8 certification

2012-08-22 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
assignee: eric.araujo - 
components: +Windows -Distutils
nosy: +loewis
versions: +Python 3.2, Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15762
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15762] Windows 8 certification

2012-08-22 Thread Antoine Pitrou

Changes by Antoine Pitrou pit...@free.fr:


--
nosy: +brian.curtin, tim.golden

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15762
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7741] Allow multiple statements in code.InteractiveConsole.push

2012-08-22 Thread aliles

aliles added the comment:

I agree that the second patch adds little value to InteractiveConsole.

A third alternative would be to accept default grammar start symbol to be 
passed to __init__(). Although this would prevent mixing use of 'single' with 
'exec'.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue7741
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15763] email non-ASCII characters in TO or FROM field doesn't work

2012-08-22 Thread Helmut Jarausch

New submission from Helmut Jarausch:

Trying to generate an email with Latin-1 characters in the TO or FROM
field either produces an exception or produces strange values in the generated 
email:

Using  Python 3.2.3+ (3.2:481f5d9ef577+, Aug  8 2012, 10:00:28) 


#!/usr/bin/python3
#-*- coding: latin1 -*-

import smtplib
from email.message import Message
import datetime
import sys

msg= Message()
msg.set_charset('latin-1')
msg['Subject'] = *** Email Test ***

# the following gives a  UnicodeDecodeError: 'ascii' codec can't decode byte 
0xfc ..
# in File /usr/lib64/python3.2/email/header.py, line 281, in append
# msg['From'] = FromAddr = Günter Groß 
email_tes...@numa-sv.igpm.rwth-aachen.de.encode('iso-8859-1')


# The following doesn't crash Python but generates a strange From string :
# 
=?utf-8?b?R8O8bnRlciBHcm/DnyA8RW1haWxfVGVzdGVyQG51bWEtc3YuaWdwbS5yd3RoLWFhY2hlbi5kZT4=?=

msg['From'] = FromAddr = Günter Groß 
email_tes...@numa-sv.igpm.rwth-aachen.de


# The same with this one
msg['To']   = ToAddr   = Günter Weiße jarau...@igpm.rwth-aachen.de

DATE = datetime.datetime.utcnow().strftime('%m/%d/%Y %I:%M:%S %p')
msg['Date'] = datetime.datetime.utcnow().strftime('%m/%d/%Y %I:%M:%S %p')

server= smtplib.SMTP(igpm.igpm.rwth-aachen.de)
# server= smtplib.SMTP('relay.skynet.be')
server.set_debuglevel(9)

msg.set_payload(Gedanken über einen Test,iso-8859-1)
# server.send_message(msg)
server.sendmail(FromAddr,ToAddr,msg.as_string().encode(iso-8859-1))
server.quit()

--
components: email
messages: 168869
nosy: HWJ, barry, r.david.murray
priority: normal
severity: normal
status: open
title: email  non-ASCII characters in TO or FROM field doesn't work
versions: Python 3.2

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15763
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15748] Various symlink test failures in test_shutil on FreeBSD

2012-08-22 Thread Trent Nelson

Trent Nelson added the comment:

Hm... tested against other types of file systems and didn't see any issues. 
 Tested manually against ZFS again:


% ~/src/cpython/python /tmp/test_readlink.py
temp dir: /mnt/t-zfs/trent/d_6i51

path 1: /mnt/t-zfs/trent/d_6i51/qux, length 1: 27, buf 1: 
/mnt/t-zfs/trent/d_6i51/bar
path 2: /mnt/t-zfs/trent/d_6i51/qux, length 2: 27, buf 2: 
/mnt/t-zfs/trent/d_6i51/bar
dst: /mnt/t-zfs/trent/d_6i51/bar

path 1: /mnt/t-zfs/trent/d_6i51/baz, length 1: 24, buf 1: 
/mnt/t-zfs/trent/d_6i51/
path 2: /mnt/t-zfs/trent/d_6i51/baz, length 2: 24, buf 2: 
/mnt/t-zfs/trent/d_6i51/
src: /mnt/t-zfs/trent/d_6i51/
[47136 refs]


This time, src got truncated by 3 characters back down to 24.  (Instead of 
getting rounded up by 6 from 18-24 in the previous example.)

Next step: replicate with a C snippet and ping the FreeBSD developers, I guess.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15748
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue12716] Reorganize os docs for files/dirs/fds

2012-08-22 Thread Mike Hoy

Mike Hoy added the comment:

I was attempting to create a patch for this but all I have is moving fchmod() 
below chmod(). I was unable to find fchmodat() in os.rst. And I need further 
clarification on 

Also, symbolic constants should be close to the functions they are used in. 
For example, open() flags shouldn't be in their own section.

--
keywords: +patch
nosy: +mikehoy
Added file: http://bugs.python.org/file26961/issue141820-function-fchmod.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue12716
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15740] test_ssl failure when cacert.org CA cert in system keychain on OSX

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

This also affects 2.7, and the patch doesn't work there.

It does work when I add the call to os.putenv at module scope before (before 
importing ssl), but I don't really like that. 

It is probably necessary to do it like this though, the code that checks if the 
keychain integration is enabled caches its results and which means my patch 
only works accidentally (based on the order tests happen to be run in). 

I've attached a 3th version of the patch that also works with 2.7 (that is, 
after manually applying the patch). I'm not too happy about it though, the 
module now changes the environment of the entire test suite (on OSX).

Annoyingly the 3th version does *not* work with 'make test' for python 3.3 , 
even when I change os.environ. I haven't tried to debug that yet.

I'm disabling the CAcert root key in my keychain for no to be able to test 
patches without running into this issue.

--
versions: +Python 2.7
Added file: http://bugs.python.org/file26962/issue15740-3.txt

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15740
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue8256] input() doesn't catch _PyUnicode_AsString() exception; io.StringIO().encoding is None

2012-08-22 Thread aliles

aliles added the comment:

Replicated this issue on Python 3.3b2. The cause is the 'encoding' and 'errors' 
attributes on io.StringIO() being None. Doctest replaces sys.stdout with a 
StringIO subclass. The exception raised is still a TypeError.

At this point I'm unsure what the fix should be:

1. Should the exception raised be more descriptive of the problem?
2. Should io.StringIO have real values for encoding and errors?
3. Should Doctest's StingIO class provide encoding and errors?

--
nosy: +aliles

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8256
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15740] test_ssl failure when cacert.org CA cert in system keychain on OSX

2012-08-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Le mercredi 22 août 2012 à 11:57 +, Ronald Oussoren a écrit :
 I've attached a 3th version of the patch that also works with 2.7
 (that is, after manually applying the patch). I'm not too happy about
 it though, the module now changes the environment of the entire test
 suite (on OSX).

This will fail if the ssl module has already been imported by another
test.
Given the workaround is so fragile, I would recommend skipping the test
on OS X instead.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15740
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Richard Oudkerk

Richard Oudkerk added the comment:

 It seems we could do both (fix the resizing logic, and fallback on
 chunks if the size is unknown).

Combined patch attached.

--
Added file: http://bugs.python.org/file26963/readall-combined.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15740] test_ssl failure when cacert.org CA cert in system keychain on OSX

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

There is no need to unconditionally skip the test. The cacert.org root 
certificate is not present on most systems, I just happened to have imported it 
into my keychain.

I've removed the cacert root from my keychain and test_ssl now passed without a 
patch. 

I agree that is it not worthwhile to pursue this further and will therefore 
close this issue as wont fix.

--
resolution:  - wont fix
stage:  - committed/rejected
status: open - closed
type:  - behavior

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15740
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15716] Ability to specify the PYTHONPATH via a command line flag

2012-08-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 526c6262d91f by Ronald Oussoren in branch '3.2':
Fix for issue 15716: interpreter could crash when PYTHONEXECUTABLE was set on 
Mac OS X.
http://hg.python.org/cpython/rev/526c6262d91f

New changeset ae51329f9893 by Ronald Oussoren in branch 'default':
Fix for issue 15716: interpreter could crash when PYTHONEXECUTABLE was set on 
Mac OS X.
http://hg.python.org/cpython/rev/ae51329f9893

--
nosy: +python-dev

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15716
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15761] Setting PYTHONEXECUTABLE can cause segfaults on OS X

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

committed a patch in revisions 526c6262d91f and ae51329f9893. Those won't end 
up as messages in this issue due to a typo in the check-in message.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15761
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15716] Ability to specify the PYTHONPATH via a command line flag

2012-08-22 Thread Ronald Oussoren

Ronald Oussoren added the comment:

My fingers are too thick. The two changesets in msg168877 are for issue 15761, 
not this one. Sorry about the noise.

--
nosy: +ronaldoussoren

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15716
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue8256] input() doesn't catch _PyUnicode_AsString() exception; io.StringIO().encoding is None

2012-08-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

 I suggest that since PyOS_Readline() write the prompt to stderr, the
 conversion uses the encoding of stderr.

Agreed with Amaury.

--
nosy: +pitrou

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue8256
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15764] Sqlite3 performance

2012-08-22 Thread Jens Henrik Leonhard Jensen

New submission from Jens Henrik Leonhard Jensen:

The _sqlite modules uses sqlite3_prepare and not sqlite3_prepare_v2.
With sqlite3_prepare_v2 enables more optiomation.

Workaround:
Do not use parameters as the right hand argument to GLOB or LIKE.

For more documentation see http://www.sqlite.org/optoverview.html.

--
components: Extension Modules
files: db-test.py
messages: 168881
nosy: jhlj
priority: normal
severity: normal
status: open
title: Sqlite3 performance
type: performance
versions: Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3, Python 3.4
Added file: http://bugs.python.org/file26964/db-test.py

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15764
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

If new_buffersize() is only used with HAVE_FSTAT, then its code can probably be 
simplified.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS

2012-08-22 Thread Trent Nelson

Trent Nelson added the comment:

Looks like it's not specific to just FreeBSD, no ZFS.  From a new NetBSD slave 
I set up:

==
FAIL: test_futimes_ns (test.test_os.StatAttributeTests)
--
Traceback (most recent call last):
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 369, in test_futimes_ns
self._test_utime_ns(futimes_ns, test_dir=False)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 339, in _test_utime_ns
self._test_utime(self.fname, getattr_ns, set_times_ns, ten_s)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 318, in _test_utime
self.assertEqual(attr(st0, st_mtime), attr(st1, st_mtime))
AssertionError: 1345639042446725659 != 1345639042446725000

==
FAIL: test_lutimes_ns (test.test_os.StatAttributeTests)
--
Traceback (most recent call last):
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 362, in test_lutimes_ns
self._test_utime_ns(lutimes_ns)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 339, in _test_utime_ns
self._test_utime(self.fname, getattr_ns, set_times_ns, ten_s)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 318, in _test_utime
self.assertEqual(attr(st0, st_mtime), attr(st1, st_mtime))
AssertionError: 1345639042450323780 != 1345639042450323000

==
FAIL: test_utime (test.test_os.StatAttributeTests)
--
Traceback (most recent call last):
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 331, in test_utime
self._test_utime(self.fname, getattr, utime, 10)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 319, in _test_utime
self.assertEqual(attr(st0, st_atime), attr(st1, st_atime))
AssertionError: 1345639042.4583352 != 1345639042.458335

==
FAIL: test_utime_ns (test.test_os.StatAttributeTests)
--
Traceback (most recent call last):
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 346, in test_utime_ns
self._test_utime_ns(utime_ns)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 339, in _test_utime_ns
self._test_utime(self.fname, getattr_ns, set_times_ns, ten_s)
  File 
/home/cpython/buildslave/3.x.snakebite-netbsd51-x86-1/build/Lib/test/test_os.py,
 line 318, in _test_utime
self.assertEqual(attr(st0, st_mtime), attr(st1, st_mtime))
AssertionError: 1345639042463150626 != 134563904246315

--
(from 
http://buildbot.python.org/all/builders/x86%20NetBSD%205.1.2%20%5BSB%5D%203.x/builds/0/steps/test/logs/stdio)


Exact same symptoms as the original FreeBSD issue.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15745
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread STINNER Victor

Changes by STINNER Victor victor.stin...@gmail.com:


--
nosy: +haypo

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread STINNER Victor

STINNER Victor added the comment:

I'm lost, there are too much patches. Could you please remove old/useless 
patches? Patching the subprocess module is not a good solution: if there is an 
issue in the io module, the io module should be fixed, and so this patch can be 
removed.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15765] test_getcwd_long_pathnames (in test_posix) kills NetBSD

2012-08-22 Thread Trent Nelson

New submission from Trent Nelson:

The 2.7 builds of both my NetBSD slaves keep hanging on test_posix (and 
eventually time out after an hour).  Running the test manually:


netbsd51-x86-1$ pwd   
/home/cpython/2.7
netbsd51-x86-1$ b/test/regrtest.py -uall -rwW -v test_posix   
== CPython 2.7.3+ (2.7:c1c45755397b, Aug 22 2012, 14:05:02) [GCC 4.1.3 20080704 
prerelease (NetBSD nb2 20081120)]
==   NetBSD-5.1.2-i386-32bit-ELF little-endian
==   /home/cpython/2.7/build/test_python_10630
Testing with flags: sys.flags(debug=0, py3k_warning=1, division_warning=1, 
division_new=0, inspect=0, interactive=0, optimize=0, dont_write_bytecode=0, 
no_user_site=0, no_site=0, ignore_environment=1, tabcheck=2, verbose=0, 
unicode=0, bytes_warning=0, hash_randomization=1)
Using random seed 2040018
test_posix
testNoArgFunctions (test.test_posix.PosixTester) ... ok
test_access (test.test_posix.PosixTester) ... ok
test_chdir (test.test_posix.PosixTester) ... ok
test_chflags (test.test_posix.PosixTester) ... ok
test_chown (test.test_posix.PosixTester) ... ok
test_confstr (test.test_posix.PosixTester) ... ok
test_dup (test.test_posix.PosixTester) ... ok
test_dup2 (test.test_posix.PosixTester) ... ok
test_fchown (test.test_posix.PosixTester) ... ok
test_fdopen (test.test_posix.PosixTester) ... ok
test_fstat (test.test_posix.PosixTester) ... ok
test_fstatvfs (test.test_posix.PosixTester) ... ok
test_ftruncate (test.test_posix.PosixTester) ... ok
test_getcwd_long_pathnames (test.test_posix.PosixTester) ... load: 0.50  cmd: 
python 10630 [runnable] 0.27u 13.07s 46% 10976k
load: 0.87  cmd: python 10630 [runnable] 0.27u 94.24s 98% 10976k
^C^C

Placeholder issue at the moment.

although this looks pretty dodgy:


os.chdir(dirname)
try:
os.getcwd()
if current_path_length  4099:
_create_and_do_getcwd(dirname, current_path_length 
+ len(dirname) + 1)

--
assignee: trent
messages: 168885
nosy: trent
priority: normal
severity: normal
status: open
title: test_getcwd_long_pathnames (in test_posix) kills NetBSD
type: behavior
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15765
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15764] Sqlite3 performance

2012-08-22 Thread STINNER Victor

STINNER Victor added the comment:

Such change cannot be done in a version older than Python 3.4 (older versions 
only accept bugfixes, this is an improvment).

--
nosy: +haypo
versions:  -Python 2.6, Python 2.7, Python 3.1, Python 3.2, Python 3.3

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15764
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15758] 500x speed up for Popen.communicate() on Windows

2012-08-22 Thread Ralf Schmitt

Changes by Ralf Schmitt python-b...@systemexit.de:


--
nosy: +schmir

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15758
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15748] Various symlink test failures in test_shutil on FreeBSD

2012-08-22 Thread STINNER Victor

STINNER Victor added the comment:

I don't understand if the issue comes from symlink() or readlink(). Can you 
reproduce the issue using commands on the command line?

$ ln -s setup.py link
`link' - `setup.py'
$ readlink link
setup.py

(You may need to test different length for filenames.)

Do you only have the issue with ZFS, or with other file systems?

--
nosy: +haypo

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15748
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15763] email non-ASCII characters in TO or FROM field doesn't work

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

Doing non-ASCII email in python before 3.3 is a bit of a pain and not as well 
documented as it should be.  3.3 will work more like you expect, if you use the 
new provisional policies (which are intended to become standard in 3.4, after a 
the bake-in period in 3.3).

For 3.2, you need to handle encoding addresses using utils.formataddr and 
header.Header:

 h = Header(header_name='Sender')
 h.append(Éric, 'latin-1')
 h.append('e...@example.com')
 h.encode()
'=?iso-8859-1?q?=C9ric?= e...@example.com'
 m = Message()
 m['Sender'] = h
 print(m)
Sender: =?iso-8859-1?q?=C9ric?= e...@example.com

In 3.3 this will work:

 m = Message()
 m['Sender'] = formataddr(('Éric', 'e...@example.com'))
 print(m)
Sender: =?iso-8859-1?q?=C9ric?= e...@example.com

But even better, so will this:

 m = Message(policy=policy.SMTP)
 m['From'] = Günter Weiße jarau...@igpm.rwth-aachen.de
 print(m)
From: =?utf-8?q?G=C3=BCnter_Wei=C3=9Fe?= jarau...@igpm.rwth-aachen.de

--
resolution:  - works for me
stage:  - committed/rejected
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15763
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1207589] Right Click Context Menu

2012-08-22 Thread Terry J. Reedy

Changes by Terry J. Reedy tjre...@udel.edu:


--
nosy: +serwy

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1207589
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5088] optparse: inconsistent default value for append actions

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

It may or may not be too old to deserve comments, but it is too old to do 
anything about it.  This can't change for backward compatibility reasons, and 
since optparse is deprecated in favor of argparse it isn't getting any new 
features.  We still need to apply the doc patch, though...(makes note to self).

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue5088
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15764] Sqlite3 performance

2012-08-22 Thread Martin v . Löwis

Martin v. Löwis added the comment:

This is a duplicate of #9303

--
nosy: +loewis
resolution:  - duplicate
status: open - closed
superseder:  - Migrate sqlite3 module to _v2 API to enhance performance

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15764
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Jeff Knupp

Changes by Jeff Knupp jkn...@gmail.com:


--
nosy: +Jeff.Knupp

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15762] Windows 8 certification

2012-08-22 Thread Martin v . Löwis

Martin v. Löwis added the comment:

This is not an issue of Python, but py2exe; please report it to the py2exe 
maintainers.

--
resolution:  - invalid
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15762
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9334] argparse does not accept options taking arguments beginning with dash (regression from optparse)

2012-08-22 Thread Andrew McNabb

Changes by Andrew McNabb amcn...@mcnabbs.org:


--
nosy: +amcnabb

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9334
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15766] _imp.load_dynamic() does crash with non-ASCII path and uses the wrong encoding

2012-08-22 Thread STINNER Victor

New submission from STINNER Victor:

_imp.load_dynamic() use UTF-8 (PyUnicode_FromString) to decode the error 
message from dlerror(), whereas the locale encoding should be used. The path is 
decoded from UTF-8, whereas the filesystem encoding should be used.

As a result, error_ob and path can be NULL, whereas Py_DECREF() is used and so 
Python does crash (SIGSEGV).

Attached patch should avoid a crash, but I'm not sure that it is enough to 
support non-ASCII path: pathname is ./ is the path is not an absolute path.

PyOS_snprintf(pathbuf, sizeof(pathbuf), ./%-.255s, pathname);
  should maybe be replaced with
pathbytes = PyBytes_FromFormat(./%s, pathname);

--
components: Tkinter
files: imp.patch
keywords: patch
messages: 168892
nosy: brett.cannon, haypo
priority: normal
severity: normal
status: open
title: _imp.load_dynamic() does crash with non-ASCII path and uses the wrong 
encoding
type: crash
versions: Python 3.3, Python 3.4
Added file: http://bugs.python.org/file26965/imp.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15766
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15766] _imp.load_dynamic() does crash with non-ASCII path and uses the wrong encoding

2012-08-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset eaac55703796 by Victor Stinner in branch 'default':
Issue #15766: Fix a crash in imp.load_dynamic() on PyUnicode_FromString() 
failure
http://hg.python.org/cpython/rev/eaac55703796

--
nosy: +python-dev

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15766
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15642] Integrate pickle protocol version 4 GSoC work by Stefan Mihaila

2012-08-22 Thread Stefan Mihaila

Stefan Mihaila added the comment:

- I don't really like the idea of changing the semantics of the PUT and GET 
opcodes. I would prefer new opcodes if possible.

Well, the semantics of PUT and GET haven't really changed. It's just that the 
PUT opcode is not generated anymore and memoization is done in agreement 
(i.e. both the pickler and the unpickler know when to memoize so their memo 
tables stay in sync). So, in fact, it's the semantics of the other opcodes that 
has slightly changed.

- I would like to see benchmarks for this change.

I've tried the following two snippets with timeit:

./python3.3 -m timeit \
-s 'from pickle import dumps' \
-s 'd=[a]*100'
'dumps(d,3)' # replace 3 with 4 for comparison

./python3.3 -m timeit \
-s 'from pickle import dumps' \
-s 'd=list(map(chr,range(0,256)))' \
'dumps(d,3)' # replace 3 with 4 for comparison
 # you can also use loads(dumps(d,3)) here to 
benchmark both 
 # operations at once


The first one generates 99 BINGET opcodes. It generates 1 BINPUT opcode in 
pickle3 and no BINPUT opcodes in pickle4.
There appears no noticeable speed difference.

The second one generates no BINGET opcodes. It generates no BINPUT opcodes in 
v4, respectively 256 BINPUT opcodes in v3. It appears the v4 one is slightly 
faster, but I have a hard time comparing correctly, given that the measurements 
seem to have a very large standard deviation (v4 gets times somewhere between 
32.3 and 44.2, whereas v3 gets times between 37.7 and 52.2).

I'm not sure this is the best way to benchmark, so let me know what is usually 
used.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15642
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue14965] super() and property inheritance behavior

2012-08-22 Thread Torsten Landschoff

Torsten Landschoff added the comment:

I stumbled across this omission as well in 2010 and brought this up on 
python-dev:

http://mail.python.org/pipermail/python-dev/2010-April/099672.html

There were no replies, but perhaps my post adds a bit of information and also 
there is another patch linked from there. I attached my patch from 2010 for 
reference.

--
nosy: +torsten
Added file: http://bugs.python.org/file26966/44560_44559.diff

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue14965
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Brett Cannon

Brett Cannon added the comment:

It has nothing to do with runpy and __main__.py and everything to do with rev 
78619:0d52f125dd32 (which fixed issue #15715) which was done to ignore bogus 
names in fromlist. If you simply change the import line to import foo.bar 
then you get the expected result.

The options I see to solve this without invalidating issue #15715 is:

1) Parse the ImportError message to notice that it was a lookup failure and not 
some other ImportError (ewww)

2) Importlib has to tag every exception is raises because of a finder failure 
to know when an ImportError was triggered because the module wasn't found (less 
eww, but still brittle as it means only importlib or people aware of the flag 
will have the expected semantics)

3) Create a ModuleNotFoundError exception that subclasses ImportError and catch 
that (breaks doctests and introduces a new exception that people will need to 
be aware of, plus the question of whether it should just exist in importlib or 
be a builtin)

4) change importlib._bootstrap._handle_fromlist (and various other bits of 
importlib code) to call _find_module() and silently ignore when no finder is 
found as desired (probably need to add a flag to _find_and_load() to signal 
whether finder failure just returns None or raises ImportError)

While I prefer 3, I think it's a bit late in the release to try to introduce a 
new exception to begin separating the meaning of 16 different ``raise 
ImportError`` cases in importlib._bootstrap based on inheritance. My gut says 4 
is the best solution given the timeframe. I should be able to get a patch in on 
Friday if that works for people.

--
assignee:  - brett.cannon
priority: normal - release blocker
stage:  - test needed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15642] Integrate pickle protocol version 4 GSoC work by Stefan Mihaila

2012-08-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

Le mercredi 22 août 2012 à 15:49 +, Stefan Mihaila a écrit :
 I'm not sure this is the best way to benchmark, so let me know what is
 usually used.

http://hg.python.org/benchmarks/ has pickling benchmarks, you may have
to modify them to test different pickling protocols.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15642
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS

2012-08-22 Thread Antoine Pitrou

Antoine Pitrou added the comment:

 AssertionError: 1345639042446725659 != 1345639042446725000

Well, by the looks of it, some filesystems only have microsecond precision?
Would be best to confirm with a {Free,Net}BSD mailing-list, I think.

--
nosy: +pitrou

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15745
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9374] urlparse should parse query and fragment for arbitrary schemes

2012-08-22 Thread Matthias Klose

Matthias Klose added the comment:

this breaks the following upstream builds:

createrepo, linkchecker, gwibber, pegasus-wm

there is no need to remove is_hierarchical on the branches. it's not used by 
urlparse at all.

is it safe to just keep the uses_query and uses_fragment lists on the branches 
as well?

raising to a release blocker, I consider this as a regression for the 2.7 and 
3.2 release series.

--
nosy: +benjamin.peterson, doko, georg.brandl
priority: normal - release blocker
resolution: fixed - remind

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue9374
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15766] _imp.load_dynamic() does crash with non-ASCII path and uses the wrong encoding

2012-08-22 Thread Martin v . Löwis

Martin v. Löwis added the comment:

The patch is still insufficient. Any of the functions can fail because of 
memory exhaustion, so a fix should really use the standard error handling 
procedure.

--
nosy: +loewis

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15766
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue11776] Constructor signatures missing in types module documentation

2012-08-22 Thread Terry J. Reedy

Terry J. Reedy added the comment:

class types.MappingProxyType(mapping) 
Read-only proxy of a mapping. ...

is the only class in 7.11.2. Standard Interpreter Types that *does* have a 
signature given in the text. However, the extra word 'class' here and for 
SimpleNamespace confuses me (I do not understand what it is intended to convey) 
and seems unnecessary. The two entries with signatures in 7.11.1 do not have 
that.

Once parenthesized signatures are given, perhaps one statement at the top like 
Classes listed without a signature cannot be directly created from Python 
code. would be sufficient.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue11776
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15765] test_getcwd_long_pathnames (in test_posix) kills NetBSD

2012-08-22 Thread Stefan Krah

Stefan Krah added the comment:

The timeouts on NetBSD and OpenBSD are very likely related to
bugs in the user-space thread libraries. See also #8714.

I would recommend running these bots --without-threads.

--
nosy: +skrah

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15765
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Chris Jerdonek

Chris Jerdonek added the comment:

Here is a formal unit test case that passes in 3.2 but not in 3.3 (a simpler 
case not using __main__.py).

(script_helper.create_empty_file() doesn't seem to be available in 3.2.)

--
keywords: +patch
Added file: http://bugs.python.org/file26967/issue-15316-failing-test-1.patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Brett Cannon

Brett Cannon added the comment:

Thanks for the test, Chris. It can probably be simplified using the utilities 
in test_importlib (e.g. managing the cleanup of sys.path, using mocked loaders 
to raise the exception instead of having to write to the file system, etc.), 
but otherwise the idea of the test is accurate.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Chris Jerdonek

Chris Jerdonek added the comment:

You're welcome, Brett.  I'll let you or someone else recast the test using the 
latest preferred techniques.  I was just using the style of the immediately 
surrounding tests.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15767] add ModuleNotFoundError

2012-08-22 Thread Eric Snow

New submission from Eric Snow:

In issue 15316 (msg168896, Brett Cannon):

  Create a ModuleNotFoundError exception that subclasses ImportError
  and catch that (breaks doctests and introduces a new exception that
  people will need to be aware of, plus the question of whether it
  should just exist in importlib or be a builtin)

While it's too late to go into 3.3, this is a reasonable addition for 3.4.  
Perhaps other ImportError subclasses are warranted, but they can be addressed 
separately.

--
components: Interpreter Core
messages: 168906
nosy: brett.cannon, eric.snow
priority: normal
severity: normal
stage: needs patch
status: open
title: add ModuleNotFoundError
type: enhancement
versions: Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15767
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15316] runpy swallows ImportError information with relative imports

2012-08-22 Thread Eric Snow

Eric Snow added the comment:

 While I prefer 3, I think it's a bit late in the release to try to
 introduce a new exception to begin separating the meaning of 16
 different ``raise ImportError`` cases in importlib._bootstrap based on
 inheritance. My gut says 4 is the best solution given the timeframe.

Agreed.  I still think option 3 would be suitable and have created issue 15767 
to track it.

--
nosy: +eric.snow

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15316
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15767] add ModuleNotFoundError

2012-08-22 Thread Chris Jerdonek

Changes by Chris Jerdonek chris.jerdo...@gmail.com:


--
nosy: +cjerdonek

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15767
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15748] Various symlink test failures in test_shutil on FreeBSD

2012-08-22 Thread Larry Hastings

Larry Hastings added the comment:

haypo: If a series of shell commands duplicated the problem, then okay, but I 
suspect the problem has to do with persistent state in the process and will 
only be reproducible with a C program.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15748
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15768] re.sub() with re.MULTILINE not replacing all occurrences

2012-08-22 Thread Eric Cousineau

New submission from Eric Cousineau:

[Copying post I made here: 
http://stackoverflow.com/questions/12082886/bug-in-python-regex-re-sub-with-re-multiline]

I'm noticing some odd behavior in Python's Regex library, and I'm not sure if 
I'm doing something wrong.

If I run a regex on it using re.sub(), with re.MULTILINE. It seems to only 
replace the first few occurrences. It replaces all occurrences if I turn off 
re.MULTILINE, use re.subn(..., count = 0, flags = re.MULTILINE), or compile the 
regex using re.compile(..., re.MULTILINE).

I am running Python 2.7 on Ubuntu 12.04.

I've posted a random example on:

http://pastebin.com/49SU8Mm2 - Output from terminal
http://codepad.org/2RO2iS4O - Script, confirming behavior (except for 
re.subn(), which is different on 2.5)

--
components: Regular Expressions
messages: 168909
nosy: eacousineau, ezio.melotti, mrabarnett
priority: normal
severity: normal
status: open
title: re.sub() with re.MULTILINE not replacing all occurrences
type: behavior
versions: Python 2.7

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15768
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15768] re.sub() with re.MULTILINE not replacing all occurrences

2012-08-22 Thread Eric Cousineau

Eric Cousineau added the comment:

Looks like I was just writing my code incorrectly - I should have been using 
re.sub(..., flags = re.MULTILINE).
That explains it.

--
resolution:  - invalid
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15768
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15745] Numerous utime ns tests fail on FreeBSD w/ ZFS

2012-08-22 Thread Larry Hastings

Larry Hastings added the comment:

Yes, but the code should still work.  The test that's failing reads the 
atime/mtime from a file, then writes those values out to the file, then reads 
again to confirm that they're the same.  That should always work.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15745
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

I think restricting the test is fine.  If we find a platform-specific bug on 
another platform we can add a test specific to that platform when we fix the 
bug.

Can you provide the test?  I'm going to commit what I've got at this point to 
make sure I don't miss the RC.

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Alexander Belopolsky

Alexander Belopolsky added the comment:

Please commit.  I'll add the test.

On Wed, Aug 22, 2012 at 9:11 PM, R. David Murray rep...@bugs.python.org wrote:

 R. David Murray added the comment:

 I think restricting the test is fine.  If we find a platform-specific bug on 
 another platform we can add a test specific to that platform when we fix the 
 bug.

 Can you provide the test?  I'm going to commit what I've got at this point to 
 make sure I don't miss the RC.

 --

 ___
 Python tracker rep...@bugs.python.org
 http://bugs.python.org/issue665194
 ___

--
nosy: +Alexander.Belopolsky

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 71b9cca81598 by R David Murray in branch 'default':
#665194: Update email.utils.localtime to use astimezone, and fix bug.
http://hg.python.org/cpython/rev/71b9cca81598

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15769] urllib.request.urlopen with cafile or capath set overrides any previous Handlers

2012-08-22 Thread Brian Turek

New submission from Brian Turek:

Using the code snippet below:

cj = http.cookiejar.CookieJar()
opener = urllib.request.build_opener(urllib.request.HTTPCookieProcessor())
urllib.request.install_opener(opener)
request = urllib.request.Request(url, data, headers) # url is https://something
sock = urllib.request.urlopen(request, cafile = 'cacert.pem')

One would expect to establish a verified HTTPS connection to the host and the 
cookies stored in the cookie jar.  Unfortunately urllib.request.urlopen, when 
called with cafile or capath set, calls urllib.request.build_opener without 
HTTPCookieProcessor included in the chain.  This results in never being able to 
support cookies in a verified HTTPS connection.

--
components: Library (Lib)
messages: 168915
nosy: caligatio
priority: normal
severity: normal
status: open
title: urllib.request.urlopen with cafile or capath set overrides any previous 
Handlers
type: behavior
versions: Python 3.2, Python 3.3, Python 3.4

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15769
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

Leaving open until the test is committed.

--
assignee: r.david.murray - 
resolution: accepted - fixed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Alexander Belopolsky

Changes by Alexander Belopolsky alexander.belopol...@gmail.com:


--
assignee:  - belopolsky

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15769] urllib.request.urlopen with cafile or capath set overrides any previous Handlers

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

I thought that was an issue when I was looking at the code the other day, but I 
didn't get around to testing it.  Thanks for the report.

--
nosy: +orsenthil, pitrou, r.david.murray
stage:  - needs patch

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15769
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15207] mimetypes.read_windows_registry() uses the wrong regkey, creates wrong mappings

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

Unfortunately I don't feel qualified to review the patch itself since I'm not a 
windows user and don't currently even have a windows box to test on.  Hopefully 
one of the windows devs will take a look; the patch looks to be fairly 
straightforward to evaluate if one understands _winreg.

--
nosy: +terry.reedy
stage: needs patch - commit review

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15207
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset a2d83fba8fd8 by R David Murray in branch 'default':
#665194: fix variable name in exception code path.
http://hg.python.org/cpython/rev/a2d83fba8fd8

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 604222c1f8a0 by Alexander Belopolsky in branch 'default':
Added test for a bug fixed in issue #665194.
http://hg.python.org/cpython/rev/604222c1f8a0

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15570] email.header.decode_header parses differently

2012-08-22 Thread R. David Murray

R. David Murray added the comment:

Absent an argument in favor of reversion, I'm closing this.

--
stage:  - committed/rejected
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue15570
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Roundup Robot

Roundup Robot added the comment:

New changeset 4c134e6ba0df by Alexander Belopolsky in branch 'default':
Issue #665194: Added a small optimization
http://hg.python.org/cpython/rev/4c134e6ba0df

--

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue665194] datetime-RFC2822 roundtripping

2012-08-22 Thread Alexander Belopolsky

Changes by Alexander Belopolsky alexander.belopol...@gmail.com:


--
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue665194
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue1578643] various datetime methods fail in restricted mode

2012-08-22 Thread Alexander Belopolsky

Changes by Alexander Belopolsky alexander.belopol...@gmail.com:


--
resolution:  - out of date
status: open - closed

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue1578643
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue13370] test_ctypes fails when building python with clang

2012-08-22 Thread Ned Deily

Ned Deily added the comment:

I just noticed another anomaly in the patch. In x86-ffi_darwin.c there appears 
to be some bogus code duplicating ffi_prep_args.  Could you review and clean up 
the patch before we apply it?

--
stage: needs patch - commit review

___
Python tracker rep...@bugs.python.org
http://bugs.python.org/issue13370
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com