[issue9880] Python 2.7 Won't Build: SystemError: unknown opcode

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: You're welcome. Please join a link to the gcc bug when you have one. -- resolution: - invalid status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue9872] `a.b.my_function is not b.my_function` when `a` and `b` are both on `sys.path`

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I suggest to report this to the Django team. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9872

[issue6627] threading.local() does not work with C-created threads

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: One more thing: in the sample code, the thread initializes no PyThreadState. So the ctypes callback creates a temporary PyThreadState just for the duration of the call. This explains the difference between threading.local

[issue1744752] Newline skipped in for line in file for huge file

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I think there's actually a bug in the MSVCRT read() function, which was not too hard to spot (see explanation below). In short, a CRLF file opened in text mode may skip a newline after 4GB. I'm re-closing the issue as won't fix

[issue1142] code sample showing errors reading large files with py 2.5/3.0

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: issue1744752 describes why it's probably a bug in the C library. possible workarounds are to open the files in universal mode, to use io.open(), or to switch to python 3! -- nosy: +amaury.forgeotdarc resolution: - wont fix

[issue1672853] Error reading files larger than 4GB

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: issue1744752 describes why it's probably a bug in the C library. possible workarounds are to open the files in universal mode, to use io.open(), or to switch to python 3! -- nosy: +amaury.forgeotdarc resolution: - wont fix

[issue1451466] reading very large files

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: issue1744752 describes why it's probably a bug in the C library. possible workarounds are to open the files in universal mode, to use io.open(), or to switch to python 3! -- nosy: +amaury.forgeotdarc resolution: - wont fix

[issue6627] threading.local() does not work with C-created threads

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: ctypes performs the initializations in a way that break the threading.local functionality. Not quite. ctypes (or more exactly: the PyGILState_Ensure() and PyGILState_Release() functions, which are the standard API to do

[issue6627] threading.local() does not work with C-created threads

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: This is not specific to ctypes. Please read http://docs.python.org/c-api/init.html#thread-state-and-the-global-interpreter-lock specially the paragraph that says ...when threads are created from C Is it explicit enough? How would

[issue1706323] Updated ASTVisitor Classes

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Indeed, this module has little value now that ast.py is in stdlib. -- nosy: +amaury.forgeotdarc resolution: - out of date status: open - closed ___ Python tracker rep...@bugs.python.org http

[issue1730136] tkFont.__eq__ gives type error

2010-09-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Fixed in r84865. -- nosy: +amaury.forgeotdarc resolution: - fixed status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1730136

[issue9880] Python 2.7 Won't Build: SystemError: unknown opcode

2010-09-16 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Maybe a corrupted .pyc file? Can you please attach the file /usr/local/src/python-2.7-maint-svn/Lib/os.pyc -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http

[issue9835] ZipFile unix external attributes incorrect for entry written with writestr

2010-09-14 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: This has already been corrected by issue3394, and is at least present in python 2.6. -- nosy: +amaury.forgeotdarc resolution: - out of date status: open - closed superseder: - zipfile.writestr doesn't set external attributes

[issue6839] zipfile can't extract file

2010-09-14 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I agree with the change, but the code should be factorized in a function (normalize_filename for example) -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http

[issue1294232] Error in metaclass search order

2010-09-13 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: What also worries me is the difference between the class statement and the type() function. class M_A(type): def __new__(mcls, name, bases, ns): print('M_A.__new__', mcls, name, bases) return super().__new__(mcls

[issue9210] remove --with-wctype-functions configure option

2010-09-12 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- assignee: - amaury.forgeotdarc resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9210

[issue9210] remove --with-wctype-functions configure option

2010-09-12 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Applied in r84752. -- resolution: accepted - fixed stage: - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9210

[issue9503] print statement hangs Windows service

2010-09-10 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Closing as a duplicate of issue706263. Instead of changing all print statements, you could set sys.stdout to another file, for example: sys.stdout=StringIO() or another object that simply discards written data. -- nosy

[issue9819] TESTFN_UNICODE and TESTFN_UNDECODABLE

2010-09-10 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- assignee: - haypo nosy: +haypo ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9819

[issue4617] SyntaxError when free variable name is also an exception target

2010-09-10 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- assignee: - amaury.forgeotdarc resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue4617

[issue9769] PyUnicode_FromFormatV() doesn't handle non-ascii text correctly

2010-09-10 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Yes, let's be conservative and reject non-ascii bytes in the format string. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9769

[issue4617] SyntaxError when free variable name is also an exception target

2010-09-10 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Fixed in r84685, with tests and doc updates. -- resolution: accepted - fixed stage: unit test needed - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http

[issue9812] cPickle segfault with nested dicts in threaded env

2010-09-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Python has several known crashers, they are not considered as security holes. It seems that FreeBSD has a small stack size for threads (64k); did you try to increase it with thread.stack_size(10**6)? -- nosy

[issue9807] deriving configuration information for different builds with the same prefix

2010-09-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: IMO there should not be any need to fetch information from config.h or the Makefile. What about a sys.build_config dictionary containing all the necessary data? -- nosy: +amaury.forgeotdarc

[issue9804] ascii() does not always join surrogate pairs

2010-09-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I agree with the feature and the patch, with two minor nits: - Py_UCS4 should be used in place of unsigned long - *p = 0xD800 is the most selective test and should be the first -- nosy: +amaury.forgeotdarc

[issue9807] deriving configuration information for different builds with the same prefix

2010-09-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: You are right; but the data could not be appended to sysconfig.py, because this file is shared by the different builds. A new built-in C module is probably necessary. -- ___ Python tracker

[issue9752] MSVC Compiler warning in Python\import.c

2010-09-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The patch is good, and fixes an incorrect call to the mkdir function. -- nosy: +amaury.forgeotdarc resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue9752] MSVC Compiler warning in Python\import.c

2010-09-09 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: BTW: should I be using the .patch extension or .diff extension? Both extensions are fine and handled the same way -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue9797] wrong assumption in pystate.c

2010-09-08 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Couldn't the patch use autoInterpreterState instead? It is already modified at the same times as autoTLSkey. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9797

[issue9786] Native TLS support for pthreads

2010-09-07 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The patch looks good. Apart from PyGILState_Ensure(), are there other parts of the code that use these functions? -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http

[issue9748] .inputrc magic-space breaks interactive mode

2010-09-07 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9748 ___ ___ Python

[issue9784] _msi.c warnings under 64-bit Windows

2010-09-07 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: FNFCIREAD co are macros to help the definition of callback functions: http://msdn.microsoft.com/en-us/library/ff797940.aspx hf is defined as INT_PTR, but the value it receives is the result of FNFCIOPEN(), which fits in int. It is safe

[issue6394] getppid support in os module on Windows

2010-09-07 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I'm currently working on it. I'll certainly commit it shortly with a few changes: - no need to say that a function fails with WindowsError, at least in the docstring. - return error sooner to reduce indentation. - in tests, use

[issue6394] getppid support in os module on Windows

2010-09-07 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Committed r84601. Thanks for the patch and your perseverance! -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6394

[issue6394] getppid support in os module on Windows

2010-09-07 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue6394

[issue9769] PyUnicode_FromFormatV() doesn't handle non-ascii text correctly

2010-09-07 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: PyUnicode_FromFormat(%s, text) expects a utf-8 buffer. Really? The *format* looks more like latin-1, right. But the payload of a %s item is decoded as utf-8. I don't think that a C file calls PyErr_Format

[issue9748] .inputrc magic-space breaks interactive mode

2010-09-05 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I didn't know what magic space is. But a quick google search shows that it is specific to Bash. in http://www.ukuug.org/events/linux2003/papers/bash_tips/#S16 There are other readline-based programs without this feature, so make

[issue9769] PyUnicode_FromFormatV() doesn't handle non-ascii text correctly

2010-09-04 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: 2 remarks: - PyUnicode_FromFormat(%s, text) expects a utf-8 buffer. - Very recently (r84472, r84485), some C files of CPython source code were converted to utf-8. And most of the time, the format given to PyUnicode_FromFormat

[issue9630] Reencode filenames when setting the filesystem encoding

2010-09-04 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Python is installed in a directory called b'py3k\xc3\xa9' and your locale is C Do we really want to support this kind of configuration? -- ___ Python tracker rep...@bugs.python.org http

[issue9753] test_socket.testDup, testFromFd fail on Windows

2010-09-03 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: test_socket.py passes here. I run: python_d.exe -m test.regrtest -v test_socket -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9753

[issue9753] test_socket.testDup, testFromFd fail on Windows

2010-09-03 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The documentation of WSASocket(), and the code of PyBluez http://code.google.com/p/pybluez/source/browse/trunk/msbt/_msbt.c#374 both suggest to use the FROM_PROTOCOL_INFO constant. Otherwise, the patch looks good

[issue9759] GzipFile object should raise ValueError on .read() after .close()

2010-09-03 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- stage: - needs patch ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9759 ___ ___ Python

[issue9761] stale .pyc files aren't cleaned out

2010-09-03 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Does your version control system let the files read-only by default? In this case, see issue6074. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue6074] .pyc files created readonly if .py file is readonly, python won't overwrite

2010-09-03 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: This is still the case: on Windows, if foo.py is readonly, python -c import foo generates foo.pyc with the readonly attribute. Tested with 3.1 and current py3k (where the file is named __pycache__\foo.cpython-32.pyc

[issue9739] Output of help(...) is wider than 80 characters

2010-09-02 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Aren't there tools that extract only the first line of help? -- assignee: - d...@python components: +Documentation -Extension Modules nosy: +amaury.forgeotdarc, d...@python ___ Python

[issue9740] Support for HTTP 1.1 persistent connections throughout the standard library

2010-09-02 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: It seems that httplib is exactly what you need: http://docs.python.org/library/httplib.html#examples -- nosy: +amaury.forgeotdarc resolution: - works for me status: open - pending ___ Python

[issue9743] __call__.__call__ chain cause crash when long enough

2010-09-02 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: On Windows, a stack overflow often causes the program to silently exit. Try to add some print statement at the end and see if it executes. -- nosy: +amaury.forgeotdarc ___ Python tracker rep

[issue9722] PyObject_Print with Visual Studio 2010

2010-08-31 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: You really should use the same version of Visual Studio than the one used to compile python. stdout points to a FILE object created by your version of the compiler (VS2010); it cannot be passed to PyObject_Print(), which uses

[issue9695] Return from generators in Python 3.2

2010-08-27 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Why is a run-time exception better than a SyntaxError in this case? And your patch now allows: x = None return x What's the rationale of this change? -- nosy: +amaury.forgeotdarc

[issue9624] 2755

2010-08-27 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Jay, is one of these links relevant to your case: http://www.appdeploy.com/msierrors/detail.asp?id=130 http://blog.colinmackay.net/archive/2007/06/21/36.aspx -- ___ Python tracker rep

[issue9683] Dead code in py3k inspect module

2010-08-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Indeed, with 3.1: def f(x, y): pass ... inspect.formatargspec(inspect.getargspec(f)) TypeError: object of type 'map' has no len() -- nosy: +amaury.forgeotdarc type: - behavior ___ Python

[issue9692] UnicodeDecodeError in ElementTree.tostring()

2010-08-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: IMO the code is not correct: how does ElementTree know which encoding is used for the attribute value? Even 2.5 prints a different content when the script is saved with a different encoding. The line should look like: oDoc.set

[issue9692] UnicodeDecodeError in ElementTree.tostring()

2010-08-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Testing with python 2.5: oDoc.set(ATTR, ÄÖÜ) uses the encoding used by the source code (with # -*- coding:;) If I use utf-8 instead, the output is: ROOT ATTR=#195;#132;#195;#150;#195;#156; / which contains the numbers of the 3 pairs

[issue9613] Python considers pid longs under 64-bit Windows

2010-08-26 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The spawn* functions return intptr_t, because it's the process handle. But _getpid() returns an int. Both seem to be correctly handled. Which part do you suspect to truncate data? -- nosy: +amaury.forgeotdarc

[issue9665] Buid issues on Cygwin - _curses, _curses_panel, and _io

2010-08-23 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The _io module appears both in setup.py and Modules/Setup.dist. Is it normal? IMO if the _io module is built-in, it should not be built as an extension module. -- nosy: +amaury.forgeotdarc

[issue9655] urllib2 fails to retrieve a url which is handled correctly by urllib

2010-08-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Hmm, it looks like a web server problem to me. urllib2 uses the HTTP/1.1 protocol, and sends the Connection: close header. I hacked urllib2: when this header is not sent, the content is retrieved normally. This page: http://www.mail

[issue9651] ctypes crash when writing zerolength string buffer to file

2010-08-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Confirmed on all versions since 2.6. Patch attached. -- keywords: +patch nosy: +amaury.forgeotdarc stage: - patch review Added file: http://bugs.python.org/file18595/ctypes-buffer.patch

[issue1182788] ZipFile __del__/close problem with longint/long files

2010-08-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: At the time, zipfile.py did not support the ZIP64 format... -- nosy: +amaury.forgeotdarc resolution: - out of date status: open - closed ___ Python tracker rep...@bugs.python.org http

[issue1597850] Cross compiling patches for MINGW

2010-08-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: the changes are small which patch are you referring to? They look quite large to me. -- nosy: +amaury.forgeotdarc ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue843590] 'macintosh' encoding alias for 'mac_roman'

2010-08-20 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- keywords: +easy resolution: - accepted ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue843590

[issue9654] merge PC/getpathp.c into Modules/getpath.c

2010-08-20 Thread Amaury Forgeot d'Arc
New submission from Amaury Forgeot d'Arc amaur...@gmail.com: The file Modules/getpath.c computes sys.prefix and the initial sys.path. The Windows version uses its own copy of this file, with a lot of similarities, but also non-obvious differences. I propose to merge both files, this would ease

[issue706263] print raises exception when no console available

2010-08-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I use Windows XP. Note that nothing is displayed on screen. there is just a error.txt file in the current directory. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue9630] Reencode filenames when setting the filesystem encoding

2010-08-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I would rename the feature to something like redecode-modules: the filenames were decoded with the wrong encoding, and must be decoded again. -- nosy: +amaury.forgeotdarc ___ Python tracker

[issue9630] Reencode filenames when setting the filesystem encoding

2010-08-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Some thoughts: since the modules were successfully imported, surely it means that their filenames where correctly computed and encoded? So why is the __filename__ attribute wrong

[issue9642] #ifdef and mbcs: don't check for defined(HAVE_USABLE_WCHAR_T)

2010-08-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: It's true that for now, MS_WINDOWS implies HAVE_USABLE_WCHAR_T and PyUnicodeObject directly used as a WCHAR array. I'd prefer a new symbol though. Why not something like HAVE_MBCS_CODEC? -- nosy: +amaury.forgeotdarc

[issue5127] Use Py_UCS4 instead of Py_UNICODE in unicodectype.c

2010-08-19 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Committed with r84177. -- resolution: - fixed stage: patch review - committed/rejected status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue5127

[issue5215] change value of local variable in debug

2010-08-18 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Ah, the patch is buggy; it was corrected with r71019 which indeed fixes up and down. You could try to apply this change to your local copy. Also consider upgrading to 2.7, where everything works as expected

[issue5215] change value of local variable in debug

2010-08-18 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Right, this last problem still exists with 2.7 or 3.1. Please open a new tracker item for it, and let's close this one. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org

[issue706263] print raises exception when no console available

2010-08-18 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: No, nothing changed in this aspect since python 2.2. With 2.7, I get the same error.txt file containing the Bad file descriptor message. -- resolution: out of date - status: closed - open

[issue5215] change value of local variable in debug

2010-08-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: In the meantime I have switched to Python 2.6.5, but the problem that I described above is still there. The fix was made for 2.7, and not backported to 2.6. Another problem that brought the patch is, that when I move a frame up

[issue9614] _pickle is not entirely 64-bit safe

2010-08-17 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The warnings at lines 284, 301, 461, 647 are benign. The attached patch fixes them. The others (lines 628, 1320, 1558, 1806) are real issues: pickle will fail when given a list, a tuple or a dict larger than INT_MAX, or when the memo

[issue9257] cElementTree iterparse requires events as bytes; ElementTree uses strings

2010-08-16 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: No, apparently, r78942 was not included in 3.1.2. -- ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue9257

[issue9445] Fix undefined symbol errors on VS8.0 build

2010-08-16 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Can someone explain why among the 6 calls to Py_GetFinalPathNameByHandle, 5 of them use VOLUME_NAME_DOS and only one uses VOLUME_NAME_NT? -- nosy: +amaury.forgeotdarc status: closed - pending

[issue9445] Fix undefined symbol errors on VS8.0 build

2010-08-16 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The calls to Py_GetFinalPathNameByHandle come in pairs: one to get the length, the other to retrieve the value. They should at least be consistent. There are two other issues: - in all three places, it's possible for the function

[issue9624] 2755

2010-08-16 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Please be more descriptive about the problem you have. What were you trying to do? On which operating system? How could we try to reproduce the problem? -- nosy: +amaury.forgeotdarc

[issue1776674] glob.glob inconsistent

2010-07-31 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Here is a test + patch, to preserve the separator. Of course this changes the current behaviour, like: glob.glob('/tmp/foo*') ['/tmp/foo1', '/tmp/foo2'] -- keywords: +patch nosy: +amaury.forgeotdarc Added file

[issue7977] I found Python 3.1 xmlrpc lib use param not properly. and i have fixed it.

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: But what if I want to pass a tuple through xmlrpc? The function in the test case: +def execute(server, methodname, *args): +r = getattr(server, methodname)(args) # params become a tuple +return r looks

[issue1152248] Enhance file.readlines by making line separator selectable

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: This fileLineIter function looks like a good recipe to me. Can we close the issue then? -- nosy: +amaury.forgeotdarc resolution: - works for me status: open - pending ___ Python tracker rep

[issue8297] AttributeError message text should include module name

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I also like the idea; 3 remarks though: - the patch introduces a new function that returns a PyObject*, but returns NULL when the attribute is not found, and the caller should raise AttributeError. This convention is not standard

[issue8376] Tutorial offers dangerous advice about iterator s: “__iter__() can just return self”

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The two example classes are used exactly the same way, and don't show the differences between them. How about a simple change like: Replace: If the class defines :meth:`next`, then :meth:`__iter__` can just return ``self`` with It may

[issue1578269] Add os.symlink() and os.path.islink() support for Windows

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: All patches seems already applied. Should we close this issue? -- status: open - pending ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1578269

[issue5131] pprint doesn't know how to print a defaultdict

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Patch looks good to me. (Some day the pprint module should grow some way to register repr for user types, so we can stop adding special cases; but defaultdict() is a builtin) -- nosy: +amaury.forgeotdarc resolution: - accepted

[issue1723038] Curses Menu

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The patch should be amended for python3, then: - PyType_Ready() should be used instead of ob_type = PyType_Type; - The demo contains Option choisie : which should be translated :-) - the call:: PyErr_SetString(PyExc_RuntimeError

[issue3591] elementtree tests do not include bytes handling

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: test_xml_etree.py has some tests about bytes input (check_issue6233) but these are only working cases. Tests with wrong encodings should be added. -- nosy: +amaury.forgeotdarc ___ Python

[issue9154] Parser module doesn't understand function annotations.

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The extra space in Grammar was already removed in r82624. The remaining part of the patch looks good to me. The lambda thing is not important, if you get an error when trying to compile the resulting st. -- nosy

[issue5978] cProfile and profile don't work with pygtk/pyqt and sys.exit(0)

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Profiling only works on functions that actually return; maybe we could add something about this fact in the documentation -- nosy: +amaury.forgeotdarc ___ Python tracker rep

[issue5774] _winreg.OpenKey() is documented with keyword arguments, but doesn't take them

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Please rename sam to something readable, access for example. And the reserved parameter should really go, at least not be documented. -- nosy: +amaury.forgeotdarc ___ Python tracker rep

[issue1506122] Add compose function to the functools

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The proposed code may be useful sometimes, but is not generic enough for the standard library. For example, the f() function can only take one argument, when g() can accept any number. Implementations of this kind are so easy

[issue1506122] Add compose function to the functools

2010-07-22 Thread Amaury Forgeot d'Arc
Changes by Amaury Forgeot d'Arc amaur...@gmail.com: -- resolution: - works for me status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue1506122

[issue1718574] build_clib --build-clib/--build-temp option bugs

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Confirmed here: python setup.py build_clib -b/some/dir returns error: option -/ not recognized All other files (build_ext.py, clean.py) have a '=' after these options names. Patch is inlined: Index: Lib/distutils/command/build_clib.py

[issue8376] Tutorial offers dangerous advice about iterator s: “__iter__() can just return self”

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Why do you call this dangerous? because the object can be iterated only once? But reversed() does the same thing. And all iterators objects must also implement the __iter__ method that return themselves, otherwise they cannot be used

[issue9193] Versioned .so files

2010-07-22 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Should the change also apply to Windows? on Windows, there is no configure phase, but the file PC/pyconfig.h is maintained manually. -- nosy: +amaury.forgeotdarc ___ Python tracker rep

[issue5804] Add an 'offset' argument to zlib.decompress

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The function returns different kind of data depending on the value of the last parameter. I don't like it at all. Why is decompressobj not enough? -- nosy: +amaury.forgeotdarc ___ Python

[issue1635741] Interpreter seems to leak references after finalization

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: Yes, some objects are not cleaned in finalization. This is not a problem in usual cases though, when the interpreter is started only once. -- nosy: +amaury.forgeotdarc ___ Python tracker rep

[issue8258] Multiple Python Interpreter Memory Leak

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: It's actually the same issue as issue1635741 -- nosy: +amaury.forgeotdarc resolution: - duplicate status: open - closed superseder: - Interpreter seems to leak references after finalization

[issue9320] os.environ is global for threads

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: I'm not sure where you'd put this. The defining characteristic of threads is that _all_ objects are shared among them. Where is this defining characteristic of threads is described? in http://docs.python.org/library/thread.html

[issue4926] putenv() accepts names containing '=', return value of unsetenv() not checked

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The patch actually does 2 things: - it prevents the usage of '=' in putenv, which is is good because the putenv() system call handles this badly. - it will raise an error when unsetting a nonexistent variable. This is a change

[issue5758] fileinput.hook_compressed returning bytes from gz file

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: gzip.open() only implements the rb mode, and returns bytes. fileinput could certainly wrap it with a io.TextIOWrapper. Then the encoding issue arises. fileinput.FileInput should grow an encoding parameter instead of always relying

[issue6751] Default return value in ConfigParser

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The idea is fine (dict.get also has a 'default' parameter) but this patch is very incomplete: - the enhancement should be applied to the three Parsers - it needs unit tests. -- nosy: +amaury.forgeotdarc

[issue1104] msilib.SummaryInfo.GetProperty() truncates the string by one character

2010-07-21 Thread Amaury Forgeot d'Arc
Amaury Forgeot d'Arc amaur...@gmail.com added the comment: The patch looks correct, it's now a matter of unit tests. for example, I'd test the case where the length is around 1000.. -- nosy: +amaury.forgeotdarc ___ Python tracker rep

<    5   6   7   8   9   10   11   12   13   14   >