[issue17703] Trash can mechanism segfault during interpreter finalization in Python 2.7.4

2013-04-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I think a solution to the problem would be to check _tstate for NULL and only use it if it is non-NULL - without threads you don't need to keep track of them ;-) -- ___ Python tracker <http://bugs.py

[issue17703] Trash can mechanism segfault during interpreter finalization in Python 2.7.4

2013-04-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 12.04.2013 16:00, Amaury Forgeot d'Arc wrote: > > Amaury Forgeot d'Arc added the comment: > >> At the time the Py_AtExit functions are called, the thread state is NULL > > I'd say this is the root cause. It'

[issue17703] Trash can mechanism segfault during interpreter finalization in Python 2.7.4

2013-04-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 12.04.2013 17:32, Antoine Pitrou wrote: > > Judging by the fact that the Py_AtExit funcs are called at the very end of > Py_Finalize (after absolutely everything has been cleaned up), I think you > shouldn't use any Python facilities a

[issue17703] Trash can mechanism segfault during interpreter finalization in Python 2.7.4

2013-04-14 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 12.04.2013 20:00, Antoine Pitrou wrote: > > Marc-André, does this patch work for you? > > Added file: http://bugs.python.org/file29791/tstate_trashcan.patch Thanks, Antoine. I can try t

[issue17703] Trash can mechanism segfault during interpreter finalization in Python 2.7.4

2013-04-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Checked the patch: it fixes the problem. Thanks. Will this go into Python 2.7.5 ? I'm asking because we need to issue a patch level release of egenix-mx-base and if Python 2.7.5 will fix the problem, we'll just add the work-around for Pyt

[issue17703] Trashcan mechanism segfault during interpreter finalization in Python 2.7.4

2013-04-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 15.04.2013 21:21, Antoine Pitrou wrote: > > Committed! Cool, thanks for the quick turnaround. -- ___ Python tracker <http://bugs.python.org/i

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

2013-04-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I think it's important to stick to established standards for MIME types and to make sure that Python returns the same values on all platforms using the default settings. Apache comes with a mime.types file which includes both the official IANA type

[issue7475] codecs missing: base64 bz2 hex zlib hex_codec ...

2013-04-24 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Just copying some details here about codecs.encode() and codec.decode() from python-dev: """ Just as reminder: we have the general purpose encode()/decode() functions in the codecs module: import codecs r13 = codecs.encode('hello worl

[issue17823] 2to3 fixers for missing codecs

2013-04-25 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 25.04.2013 10:14, Nick Coghlan wrote: > > Nick Coghlan added the comment: > > A more consistent alternative conversion: > > "...".encode("base64") => codecs.encode("...", "base64_codec&q

[issue17857] sqlite modules doesn't build on 2.7.4 with Mac OS X 10.4

2013-04-27 Thread Marc-Andre Lemburg
New submission from Marc-Andre Lemburg: This is essentially the same issue as http://bugs.python.org/issue14572. The following addition in Python 2.7.4 (compared to 2.7.3) reintroduced the same problem in a different place: --- Python-2.7.3/Modules/_sqlite/util.h 2012-04-10 01:07:33.0

[issue17857] sqlite modules doesn't build on 2.7.4 with Mac OS X 10.4

2013-04-27 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Adding the same people to the nosy list as on issue #14572. -- nosy: +Joakim.Sernbrant, Marc.Abramowitz, dmalcolm, ned.deily, petri.lehtinen, python-dev type: -> compile error ___ Python tracker &l

[issue17857] sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4

2013-04-27 Thread Marc-Andre Lemburg
Changes by Marc-Andre Lemburg : -- title: sqlite modules doesn't build on 2.7.4 with Mac OS X 10.4 -> sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4 ___ Python tracker <http://bugs.pytho

[issue17857] sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4

2013-04-27 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 27.04.2013 22:27, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > Here is a patch for 2.7. Please test. Should it be fixed on 3.x? Thanks, Serhiy. I can confirm that the patch fixes the problem with 2.7.4 on Mac OS X (

[issue17857] sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4

2013-04-28 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 28.04.2013 05:20, Ned Deily wrote: > > Ned Deily added the comment: > > Marc-Andre, can you elaborate on why you think Python 3 is not affected? The > changes for Issue17073 also added sqlite3_int64 to 3.2, 3.3, and default and, &

[issue17857] sqlite modules doesn't build with 2.7.4 on Mac OS X 10.4

2013-04-29 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Thanks, Serhiy. -- ___ Python tracker <http://bugs.python.org/issue17857> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue17878] There is no way to get a list of available codecs

2013-05-01 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.05.2013 01:59, Dmi Baranov wrote: > > Dmi Baranov added the comment: > > I think its not possible while codecs registry contains search callbacks > (stateless-registry) It is possible: we'd just need to invent a way to ask sear

[issue17878] There is no way to get a list of available codecs

2013-05-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.05.2013 16:41, Nick Coghlan wrote: > > Nick Coghlan added the comment: > > This is actually similar to the problem with getting the list of modules an > importer provides (that is, we don't currently have an officially defi

[issue17878] There is no way to get a list of available codecs

2013-05-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.05.2013 16:45, Walter Dörwald wrote: > ... > The search function can't return a list of codec names in this case, as the > list is infinite. True. The search object will have to be allowed to raise a NotImplementedError or some othe

[issue17878] There is no way to get a list of available codecs

2013-05-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.05.2013 16:53, Marc-Andre Lemburg wrote: > > Marc-Andre Lemburg added the comment: > > On 02.05.2013 16:45, Walter Dörwald wrote: >> ... >> The search function can't return a list of codec names in this case, as the &

[issue17978] Python crashes if Py_Initialize/Py_Finalize are called multiple times

2013-05-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 15.05.2013 01:28, Amaury Forgeot d'Arc wrote: > > Amaury Forgeot d'Arc added the comment: > > The official way to build without unicode is > ./configure --enable-unicode=no > But see issue17979. The official way

[issue17979] Cannot build 2.7 with --enable-unicode=no

2013-05-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Please note that the official way to build Python without Unicode support is (see http://bugs.python.org/issue445762): ./configure --disable-unicode See http://bugs.python.org/issue8767 for the most recent set of fixes that were supplied to make it work

[issue17980] CVE-2013-2099 ssl.match_hostname() trips over crafted wildcard names

2013-05-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: SSL certificate hostname matching is defined in RFC 2818: * http://www.ietf.org/rfc/rfc2818.txt It's not very verbose on how exactly matching should be done: """ Names may contain the wildcard character * which is considered

[issue17980] CVE-2013-2099 ssl.match_hostname() trips over crafted wildcard names

2013-05-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Here's another long discussions about SSL hostname matching that may provide some useful insights: * https://bugzilla.mozilla.org/show_bug.cgi?id=159483 Note how RFC 2595 doesn't even allow sub-string matching. It only allows '*' to

[issue17979] Cannot build 2.7 with --enable-unicode=no

2013-05-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 17.05.2013 13:11, Serhiy Storchaka wrote: > > Serhiy Storchaka added the comment: > > Ubuntu 32-bit, gcc 4.6.3. The bug requires 64 bit. > > This patch should fix it. int and long are the same size on Linux 64-bit platforms. You pr

[issue17979] Cannot build 2.7 with --enable-unicode=no

2013-05-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 17.05.2013 13:42, Marc-Andre Lemburg wrote: > > Marc-Andre Lemburg added the comment: > > On 17.05.2013 13:11, Serhiy Storchaka wrote: >> >> Serhiy Storchaka added the comment: >> >> Ubuntu 32-bit, gcc 4.6.3. The b

[issue17844] Add link to alternatives for bytes-to-bytes codecs

2013-05-19 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Not a bad idea. More information is always better when it comes to documentation :-) -- ___ Python tracker <http://bugs.python.org/issue17

[issue21081] missing vietnamese codec TCVN 5712:1993 in Python

2014-10-29 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Jean Christophe: Please have a look at the patch for ticket http://bugs.python.org/issue22681 as example of the doc patch. Thanks. -- ___ Python tracker <http://bugs.python.org/issue21

[issue22789] Compress the marshalled data in PYC files

2014-11-04 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 04.11.2014 10:41, Antoine Pitrou wrote: > > Antoine Pitrou added the comment: > > This is similar to the idea of loading the stdlib from a zip file (but less > intrusive and more debugging-friendly). The time savings will depend on

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Even though it may have been considered a private API (*), users certainly won't understand that their application just broke because of a Python patch level release upgrade, so if possible, I think the API should be added back and flagged as &qu

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 07.11.2014 11:12, Arfrever Frehtes Taifersar Arahesis wrote: > > Arfrever Frehtes Taifersar Arahesis added the comment: > > _ssl has leading underscore. > Privateness is "inherited", so both A._B.C and A._B._D are private. No,

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 07.11.2014 11:52, Arfrever Frehtes Taifersar Arahesis wrote: > > Arfrever Frehtes Taifersar Arahesis added the comment: > >> No, the use of the underscore in _ssl is per convention that C >> implementation part of stdlib modules a

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 07.11.2014 11:30, Marc-Andre Lemburg wrote: > BTW: The sslwrap_simple() API was also removed in 2.7.9. Scratch that. I was in the wrong work dir :-) -- ___ Python tracker <http://bugs.python.org/issu

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 07.11.2014 12:49, Marc-Andre Lemburg wrote: >> BTW: The sslwrap_simple() API was also removed in 2.7.9. > > Scratch that. I was in the wrong work dir :-) Hmm, even though the API is still there, it uses _ssl.sslwrap() as well, so it won&#x

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 07.11.2014 13:12, Antoine Pitrou wrote: > > It's not a mere matter of putting back the code... The 3.x ssl implementation > which was backported uses a slightly different approach from the 2.x > implementation, so it's not obvi

[issue22438] eventlet broke by python 2.7.x

2014-11-07 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Looking at recent comments on the gevent ticket, the 2.7.9 changes are already causing problems for people since apparently the changes were backported to 2.7.8 by some vendors. https://github.com/gevent/gevent/issues/477

[issue22789] Compress the marshalled data in PYC files

2014-11-08 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 08.11.2014 10:28, Serhiy Storchaka wrote: > Compressing pyc files one by one wouldn't save much space because disk space > is allocated by blocks (up to 32 KiB on FAT32). If the size of pyc file is > less than block size, we will not gain

[issue22846] distutils needlessly fails to build apsw

2014-11-11 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Shouldn't this be fixed in the APSW setup.py ? The patch is you are proposing looks harmless, but it can also mask programming errors in setup.py. -- nosy: +lemburg ___ Python tracker <http://bugs.py

[issue22863] https://docs.python.org/ should make a true 2.7.8 version available

2014-11-13 Thread Marc-Andre Lemburg
New submission from Marc-Andre Lemburg: The documentation shown for Python 2.7.8 currently includes 2.7.9 parts, e.g. for the ssl modules (https://docs.python.org/2.7/library/ssl.html). Since there were so many changes to the ssl module for 2.7.9 which are not available in 2.7.8, I think it

[issue22866] ssl module in 2.7.9 should provide a way to configure default context options

2014-11-13 Thread Marc-Andre Lemburg
New submission from Marc-Andre Lemburg: With the backport of the Python 3 ssl module, the default context options of the ssl module were changed. While this provides better security in many cases, it also causes breakage with servers or clients which do not support TLSv1 and later. The ssl

[issue22866] ssl module in 2.7.9 should provide a way to configure default context options

2014-11-13 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 13.11.2014 22:03, Benjamin Peterson wrote: > > Benjamin Peterson added the comment: > > Per http://legacy.python.org/dev/peps/pep-0476/#opting-out the only way to do > these things is horrednously ugly because it's hardly (if eve

[issue22866] ssl module in 2.7.9 should provide a way to configure default context options

2014-11-13 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 14.11.2014 01:29, Benjamin Peterson wrote: > > But you can reenable SSLv3 by alerting the context and monkeypatching as > described in the PEP. Well, I can monkeypatch the ssl module of course, but that's not really the point here. I

[issue22866] ssl module in 2.7.9 should provide a way to configure default context options

2014-11-13 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Hmm, since neither create_default_context() nor _create_stdlib_context() are used by any other stdlib modules, I guess the removal of SSLv3 doesn't really make much difference for existing Python 2.7 applications. I was irritated by the function

[issue22863] https://docs.python.org/ should make a true 2.7.8 version available

2014-11-14 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 14.11.2014 22:35, Terry J. Reedy wrote: > New stuff is marked "New in version 2.7.9.", etc. The Idle chapter > (reletively new in the Library Reference itself) has the same problem if new > or quasi-new features in micro-releases a

[issue22929] cp874 encoding almost empty

2014-11-24 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I'm not sure I understand the bug report. What's the problem ? :-) The codec is a charmap codec generated from the file MAPPINGS/VENDORS/MICSFT/WINDOWS/CP874.TXT (http://ftp.unicode.org/Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP874.TXT) This ma

[issue22929] cp874 encoding almost empty

2014-11-24 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: BTW: The table on the wiki page shows the same undefined chars. -- ___ Python tracker <http://bugs.python.org/issue22

[issue19676] Add the "namereplace" error handler

2014-11-25 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: The patch looks good. One nit: the name buffer length should be NAME_MAXLEN instead of 100. -- ___ Python tracker <http://bugs.python.org/issue19

[issue22980] C extension naming doesn't take bitness into account

2014-12-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Note that there's a difference between the platform's architecture (which is what get_platform() returns) and the pointer size of the currently running Python executable. On 64-bit Linux, it's rather rare to have an application built as 32-

[issue22980] C extension naming doesn't take bitness into account

2014-12-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.12.2014 19:02, Antoine Pitrou wrote: > Sticking to bitness should be easy (although I wonder if it would be > desirable for platforms with fat binaries - Ned?). If we can go the extra > mile and include platform identification all the b

[issue22980] C extension naming doesn't take bitness into account

2014-12-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.12.2014 19:40, Steve Dower wrote: > > I was more interested in source file resolution than bytecode caching. If > Python 3.5 would prefer "spam.cpython-35.py" or "spam.cpython-3.py" over > "spam.py" and Pyt

[issue22980] C extension naming doesn't take bitness into account

2014-12-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.12.2014 19:46, Antoine Pitrou wrote: > >> Note that on Linux, 32-bit and 64-bit versions are typically placed >> into different directory trees > > By whom? Our standard installer doesn't (it uses ../lib/python-X.Y for all

[issue22980] C extension naming doesn't take bitness into account

2014-12-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.12.2014 20:10, Antoine Pitrou wrote: > > Antoine Pitrou added the comment: > > Le 02/12/2014 19:59, Marc-Andre Lemburg a écrit : >> >> My main point was that we shouldn't start adding tags for e.g. >> PPC, Intel, A

[issue23023] ./Modules/ld_so_aix not found on AIX during test_distutils

2014-12-10 Thread Marc-Andre Lemburg
New submission from Marc-Andre Lemburg: Here's the traceback from one of the AIX buildbots: [ 32/400] test_distutils unable to execute './Modules/ld_so_aix': No such file or directory [22429 refs] test test_distutils failed -- Traceback (most recent call last): File "

[issue23023] ./Modules/ld_so_aix not found on AIX during test_distutils

2014-12-10 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: The problem also still exists on Python 3.4 (and probably 3.3 and 3.5 as well), even though these should have the patch from issue18235 applied: * http://buildbot.python.org/all/builders/PPC64%20AIX%203.4/builds/707 * http://buildbot.python.org/all

[issue23023] ./Modules/ld_so_aix not found on AIX during test_distutils

2014-12-10 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Note that the helper Modules/ld_so_aix is created during configure. Just the path to the helper in the sysconfig data is wrong (relative to the current dir, which will most likely always be wrong except for a few special situations such as when building

[issue22866] ssl module in 2.7 should provide a way to configure default context options

2014-12-11 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Reopening the ticket, since I apparently missed the two important uses in the Python 2.7.9 stdlib: urllib2.py: -- context = ssl._create_stdlib_context(cert_reqs=ssl.CERT_REQUIRED, httplib.py: -- context = ssl

[issue22866] ssl module in 2.7 should provide a way to configure default context options

2014-12-11 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 11.12.2014 20:42, Benjamin Peterson wrote: > > Usually you can pass your own context. Yes, in new code, but not in existing Python 2.7 code that wasn't written for the newly added SSL context feature. BTW: Having a way to change the

[issue22866] ssl module in 2.7 should provide a way to configure default context options

2014-12-11 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: > Benjamin Peterson added the comment: > > On Thu, Dec 11, 2014, at 15:24, Marc-Andre Lemburg wrote: >> >> Marc-Andre Lemburg added the comment: >> >> On 11.12.2014 20:42, Benjamin Peterson wrote: >>> >>> U

[issue22935] Disabling SSLv3 support

2014-12-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Please always use PROTOCOL_SSLv23 since this is the only forward compatible way of telling OpenSSL to use the best protocol available. Any of the other options such as PROTOCOL_TLSv1 will fix the protocol version to that one protocol version, whereas

[issue22935] Disabling SSLv3 support

2014-12-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: > STINNER Victor added the comment: > >> Any of the other options such as PROTOCOL_TLSv1 will fix the protocol >> version to that one protocol version, whereas PROTOCOL_SSLv23 means to use >> any protocol starting with SSLv2. In

[issue23042] Python 2.7.9 ctypes module doesn't build on FreeBSD x86

2014-12-12 Thread Marc-Andre Lemburg
New submission from Marc-Andre Lemburg: With Python 2.7.8, ctypes builds fine on FreeBSD x86, but with Python 2.7.9, the build fails with: *** WARNING: renaming "_ctypes" since importing it failed: build/lib.freebsd-8.3-RELEASE-p3-i386-2.7/_ctypes.so: Undefined symbol "ffi_cal

[issue23042] Python 2.7.9 ctypes module doesn't build on FreeBSD x86

2014-12-12 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: The cause seems to be these changes of the file (diff between the 2.7.8 and 2.7.9 version): @@ -368,14 +374,21 @@ void ffi_call(ffi_cif *cif, void (*fn)(v #ifdef X86_WIN64 case FFI_WIN64: ffi_call_win64(ffi_prep_args, &ecif, cif-&g

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 16.12.2014 05:54, Steve Dower wrote: > Nobody seemed too bothered by it, so I committed a slightly simpler change > that only includes the most specific tag (that is, ".cp35-win32.pyd" or > ".pyd"). We can always add an

[issue22980] C extension naming doesn't take bitness into account

2014-12-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 16.12.2014 14:38, Steve Dower wrote: > > Steve Dower added the comment: > > I justified leaving out the ABI tag in an earlier post as well as in an email > to distutils-sig, where two of the PEPs you mention were developed, and &

[issue20121] quopri_codec newline handling

2014-12-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I agree with Vajrasky: a patch for the documentation would probably be a good idea. Note that mixing line end conventions in a single text is never a good idea. If you stick to one line end convention, there's no problem with the codec, A

[issue23071] codecs.__all__ incomplete

2014-12-18 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: +1 -- nosy: +lemburg ___ Python tracker <http://bugs.python.org/issue23071> ___ ___ Python-bugs-list mailing list Unsub

[issue23085] update internal libffi copy to 3.2.1

2014-12-18 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Will this also fix http://bugs.python.org/issue23042 ? -- nosy: +lemburg ___ Python tracker <http://bugs.python.org/issue23

[issue23103] ipaddress should be Flyweight

2014-12-23 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Josh, you might want to have a look at the lightning talk on this page and the associated slides... http://www.egenix.com/library/presentations/PyCon-UK-2014-When-performance-matters/ After having done the tests, using __slots__ is what I consider the

[issue23119] Remove unicode specialization from set objects

2015-01-08 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I'm not sure I follow: Sets of strings are very common when trying to create a unique set of strings or optimizing "name in set_of_names" lookups. Regarding your benchmark numbers: I have a hard time following how they work. A

[issue23119] Remove unicode specialization from set objects

2015-01-08 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 08.01.2015 15:46, Serhiy Storchaka wrote: > >> Sets of strings are very common when trying to create a unique set of >> strings or optimizing "name in set_of_names" lookups. > > This is not nearly so common as attribute

[issue23119] Remove unicode specialization from set objects

2015-01-09 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 09.01.2015 09:33, Raymond Hettinger wrote: > > I'm withdrawing this one. After more work trying many timings on multiple > compilers and various sizes and kinds of datasets, it appears that the > unicode specialization is still wor

[issue14014] codecs.StreamWriter.reset contract not fulfilled

2015-01-14 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 14.01.2015 02:21, Martin Panter wrote: > > Martin Panter added the comment: > > I don’t think this is appropriate. If you want to flush the underlying > stream, then call its flush() method after calling reset(). The docstring > on

[issue20132] Many incremental codecs don’t handle fragmented data

2015-01-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 15.01.2015 23:46, Martin Panter wrote: > > I opened Issue 23231 about fixing iterencode() and iterdecode() in the > general case. I added a patch to Issue 13881 to fix StreamWriter for zlib and > bz2, and to fix StreamWriter.writelines(

[issue20132] Many incremental codecs don’t handle fragmented data

2015-01-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: This addition is wrong as well: The *stream* argument must be a file-like object open for reading - text or binary data, as appropriate for the specific codec. + text or binary data, as appropriate for the specific codec. This stream is + assumed

[issue19143] Finding the Windows version getting messier (detect windows 8.1?)

2015-02-09 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 09.02.2015 15:14, Steve Dower wrote: > > Steve Dower added the comment: > > (Was reminded about this by #23417) > > Any word on the back compat issues in platform.py? Can we make the version in > 3.5 only work with Vista+, or do I

[issue19143] Finding the Windows version getting messier (detect windows 8.1?)

2015-02-09 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 09.02.2015 16:17, Steve Dower wrote: > > Steve Dower added the comment: > > Including the one shipped in the stdlib? Python 3.5 no longer supports XP. We normally have the platform.py module support multiple Python versions (at least that&

[issue23474] Enhance locale testing

2015-02-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 17.02.2015 19:34, Serhiy Storchaka wrote: > > Proposed patch enhance locale testing. test__locale is converted to support > unittest discovery. When there are no suitable locales (e.g. there is only > POSIX locale) tests are reported as ski

[issue23574] datetime: support leap seconds

2015-05-27 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Here's what mxDateTime uses: >>> import mx.DateTime >>> >>> t1 = mx.DateTime.DateTime(2012,6,30,23,59,60) >>> t2 = mx.DateTime.DateTime(2012,7,1,0,0,0) >>> >>> t1 >>> t2 >>&g

[issue23970] Update distutils.msvccompiler for VC14

2015-05-27 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I was away the last few days, so just found the changes now. IMO, it's a good idea to use a new module for the new compiler, but don't think it's a good idea to make the whole module private, since this implicitly disallows sub-classing the

[issue24534] disable executing code in .pth files

2015-06-29 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 29.06.2015 21:30, Min RK wrote: > > .pth files currently allow execution of arbitrary code, triggered by lines > starting with `import`. This is a rarely understood, and often misbehaving > feature. easy_install has used this feature to ens

[issue24534] disable executing code in .pth files

2015-06-30 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 30.06.2015 20:52, Min RK wrote: > > Thanks for the feedback, I thought it might be a long shot. I will go back to > removing the *use* of the feature everywhere I can find it, since it is so > problematic and rarely, if ever, desirable

[issue24534] disable executing code in .pth files

2015-06-30 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 30.06.2015 22:49, Min RK wrote: > >> Could you please post an example of where the feature is problematic ? > > setuptools/easy_install is the major one, which effectively does > `sys.path[:0] = pth_contents`, breaking import prior

[issue23574] datetime: support leap seconds

2015-07-31 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 21.07.2015 22:15, dlroo wrote: > > dlroo added the comment: > > If you are using mx.DateTime make certain you do not use the .strftime > method. If you use .strftime method and have a 60th second in your DateTime > object it will cr

[issue24824] Pydoc fails with codecs

2015-08-08 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Please use encoding='utf-8' as definition for codecs.encode() and codecs.decode(). There is no adjustable default encoding in Python 3 anymore. For Python 3.6 this should probably be fixed

[issue24872] Add /NODEFAULTLIB:MSVCRT to _msvccompiler

2015-08-15 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: What effect does this static linking of the VC runtime have on libraries that extension modules link at dynamically ? E.g. say I have an extension which links against an ODBC driver DLL using a different VC runtime than the one used to build Python. In

[issue24872] Add /NODEFAULTLIB:MSVCRT to _msvccompiler

2015-08-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: If I understand you correctly, the only advantage of using /MT is not require admin privileges for installation of the VC2015 runtime libs. Since VC2015 will be used by a lot of applications in a few months, and it's likely that MS will ship the runti

[issue24872] Add /NODEFAULTLIB:MSVCRT to _msvccompiler

2015-08-17 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 17.08.2015 18:24, Steve Dower wrote: > > We can't have Python run VCredist because it requires administrative > privileges and installing Python does not require those. This is actually one > of the biggest complaints about the curre

[issue24912] The type of cached objects is mutable

2015-08-31 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: I agree with Mark. This feature opens up a security hole large enough to drive a train through. Looking at the python-dev thread, the only motivation appears to be making module look more like classes. I'd suggest to propose a PEP for making change

[issue24912] The type of cached objects is mutable

2015-08-31 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 31.08.2015 10:44, Nathaniel Smith wrote: > Before anyone panics about security issues, do keep in mind that the patch > you're talking about reverting fixed a buffer overflow which I strongly suspect could be used to accomplish arbitrary cod

[issue24912] The type of cached objects is mutable

2015-08-31 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 31.08.2015 11:55, Antoine Pitrou wrote: > > __class__ assignment can definitely be useful for monkey-patching, or other, > purposes. The feature certainly has its place for user defined types (see the unpickle example), but I don't t

[issue24912] The type of cached objects is mutable

2015-09-01 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 01.09.2015 04:38, Nathaniel Smith wrote: > Mark Lemburg wrote: >> Python code will generally assume that it can trust >> builtin types. It doesn't expect 42 + 2 to clear out the root dir, >> just because some package installed fr

[issue24912] The type of cached objects is mutable

2015-09-01 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: FWIW: I still think that allowing to change .__class__ on instances of static types if wrong and should be undone. If we want to make this a feature of the language we should have a PEP and the associated discussion to be able to judge and document the

[issue22798] time.mktime doesn't update time.tzname

2015-09-01 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: mktime() does change several global C runtime variables on Linux. See the man page on http://linux.die.net/man/3/mktime However, the Python documentation does not mention anything about having time.tzname being tied to the C lib global: https

[issue22798] time.mktime doesn't update time.tzname

2015-09-01 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: BTW: The most portable way to access the timezone name of a given local time is to use strftime() with %Z as format character. -- ___ Python tracker <http://bugs.python.org/issue22

[issue7175] Define a standard location and API for configuration files

2015-09-02 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: The XDG standard seems to focus on desktop GUI applications and that's also where it's mostly used. Python has it's own installation scheme, which is documented at the top of sysconfig.py and which we've had ever since distutils becam

[issue7175] Define a standard location and API for configuration files

2015-09-03 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 02.09.2015 16:37, flying sheep wrote: > > hi mark, i’ve just lengthily replied to you on python-ideas. > > in short: nope! many command line tools that are relatively new (among them > your examples git and pip) honor the specs, my ~/.c

[issue7175] Define a standard location and API for configuration files

2015-09-03 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 03.09.2015 13:37, flying sheep wrote: > all three OSs have stable, widely followed standards in place, and the idea > of providing a python stdlib API for them received an almost unanimously > positive response – with the sole exception being

[issue24917] time_strftime() Buffer Over-read

2015-09-05 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 05.09.2015 03:49, Alexander Belopolsky wrote: > > Alexander Belopolsky added the comment: > > Hmm, on Mac OSX "%" and "A%" are valid format strings: > >>>> time.strftime("%") > '%'

[issue25140] platform.platform() incorrectly identifies Windows 10 as 'Windows-8-6.2.9200'

2015-09-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: On 16.09.2015 13:22, Serhiy Storchaka wrote: > > A duplicate of issue19143? I guess so. -- ___ Python tracker <http://bugs.python.org/i

[issue25140] platform.platform() incorrectly identifies Windows 10 as 'Windows-8-6.2.9200'

2015-09-16 Thread Marc-Andre Lemburg
Changes by Marc-Andre Lemburg : -- resolution: -> duplicate status: open -> closed ___ Python tracker <http://bugs.python.org/issue25140> ___ ___ Pyth

[issue19143] Finding the Windows version getting messier (detect windows 8.1?)

2015-09-16 Thread Marc-Andre Lemburg
Marc-Andre Lemburg added the comment: Steve: Could you please merge your changes into platform.py ? I think it should go into Python 2.7. -- ___ Python tracker <http://bugs.python.org/issue19

<    13   14   15   16   17   18   19   20   >