[issue36735] minimize disk size of cross-compiled python3.6

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Make sure you use CFLAGS that limit the amount of debug data in the binaries. "-g1" in gcc should be enough to get stack traces on crashes, while reducing the binaries quite considerably compared to the default. "-g0" will give another visible reduction but r

[issue36741] Variable about function and list

2019-04-27 Thread 張晨韜
New submission from 張晨韜 : Hello,I'm a Taiwanese student. First,I will say sorry because of my poor English.If I have an offense,please forgive me. Then,look at the picture about program.I declare a list "cards" to the function "Flush",and divide them by 13 in the function.The function Flash wil

[issue36735] minimize disk size of cross-compiled python3.6

2019-04-27 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +xdegaye ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:

[issue21536] extension built with a shared python cannot be loaded with a static python

2019-04-27 Thread STINNER Victor
STINNER Victor added the comment: I reopen the issue for the Android case. I am fine with having a different linking policy per platform. For example, Windows has a different policy than Linux. We can continue to link C extensions to libpython on Android. The ability to load release C extens

[issue9521] xml.etree.ElementTree skips processing instructions when parsing

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Ticket 24287 is a duplicate of this one and has some additional discussion. -- ___ Python tracker ___ _

[issue28460] Minidom, order of attributes, datachars

2019-04-27 Thread Stefan Behnel
Change by Stefan Behnel : -- resolution: -> duplicate stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-

[issue24287] Let ElementTree prolog include comments and processing instructions

2019-04-27 Thread Stefan Behnel
Change by Stefan Behnel : -- superseder: -> xml.etree.ElementTree skips processing instructions when parsing ___ Python tracker ___ ___

[issue36737] Warnings operate out of global runtime state.

2019-04-27 Thread Steve Dower
Steve Dower added the comment: > I could also see use cases for *also* configuring warnings process-wide but > that could be handled separately if actually desired. Beyond "warning configuration is inherited by new interpreters", I don't see any reason to have process wide configuration. Peo

[issue36736] Python crashes when calling win32file.LockFileEx

2019-04-27 Thread Eryk Sun
Eryk Sun added the comment: > win32file.LockFileEx(h, win32con.LOCKFILE_EXCLUSIVE_LOCK, 5, 5, None) This is a third-party issue in the PyWin32 package. win32file.LockFileEx shouldn't allow passing None for the required 5th parameter `ol` (i.e. the lpOverlapped parameter of WINAPI LockFileEx

[issue18304] ElementTree -- provide a way to ignore namespace in tags and searches

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: I was referring to issue 28238 and issue 30485. -- ___ Python tracker ___ ___ Python-bugs-list mai

[issue5166] ElementTree and minidom don't prevent creation of not well-formed XML

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: This is a tricky decision. lxml, for example, validates user input, but that's because it has to process it anyway and does it along the way directly on input (and very efficiently in C code). ET, on the other hand, is rather lenient about what it allows user

[issue1776160] Buffer overflow when listing deeply nested directory

2019-04-27 Thread Eryk Sun
Eryk Sun added the comment: In Windows 7, FindFirstFileA uses a per-thread static buffer to decode the input bytes path to Unicode. This buffer limits the length to 259 characters (MAX_PATH - 1), even if a "\\?\" device path is used. Windows 8+ uses a dynamic buffer, but I don't see the poin

[issue36739] "4.6. Defining Functions" should mention nonlocal

2019-04-27 Thread Peter Bauer
Peter Bauer added the comment: ok, will try to create a pull-request for that, although i'm not a natural englishman... -- ___ Python tracker ___

[issue35360] Update SQLite to 3.26 in Windows and macOS installer builds

2019-04-27 Thread Big Stone
Big Stone added the comment: sqlite-3.28.0 now available, with extended window functio support: EXCLUDE clause, GROUPS frame types, window chaining, and support for " PRECEDING" and " FOLLOWING" boundaries in RANGE frames. -- nosy: +Big Stone ___

[issue24287] Let ElementTree prolog include comments and processing instructions

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: This is a duplicate of 9521, but it's difficult to say which ticket is better. -- ___ Python tracker ___ _

[issue36710] Pass _PyRuntimeState as an argument rather than using the _PyRuntime global variable

2019-04-27 Thread Jeroen Demeyer
Jeroen Demeyer added the comment: Changing *every* C API function to include a state parameter looks very cumbersome. Another alternative would be to store the interpreter state in every Python object (or every class, that would be sufficient). That way, you would only need to pass context t

[issue18675] Daemon Threads can seg fault

2019-04-27 Thread Andrew Svetlov
Change by Andrew Svetlov : -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-

[issue14149] argparse: Document how to use argument names that are not Python identifiers

2019-04-27 Thread Fred L. Drake, Jr.
Change by Fred L. Drake, Jr. : -- versions: +Python 3.7, Python 3.8, Python 3.9 -Python 3.2, Python 3.3 ___ Python tracker ___ ___ P

[issue36739] "4.6. Defining Functions" should mention nonlocal

2019-04-27 Thread Peter Bauer
Change by Peter Bauer : -- keywords: +patch pull_requests: +12908 stage: needs patch -> patch review ___ Python tracker ___ ___ Pyth

[issue18304] ElementTree -- provide a way to ignore namespace in tags and searches

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Coming back to this issue after a while, I think it's still a relevant problem in some use cases. However, it's not currently clear what an improved solution would look like. The fully qualified tag names in Clark notation are long, sure, but also extremely c

[issue35502] Memory leak in xml.etree.ElementTree.iterparse

2019-04-27 Thread Stefan Behnel
Change by Stefan Behnel : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed versions: -Python 3.6 ___ Python tracker ___

[issue9521] xml.etree.ElementTree skips processing instructions when parsing

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Issue 24287 is a duplicate of this one and has some additional discussion. -- ___ Python tracker ___ __

[issue32235] test_xml_etree test_xml_etree_c failures with 2.7 and 3.6 branches 20171205

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Closing as outdated / third-party. -- nosy: +scoder stage: -> resolved status: open -> closed ___ Python tracker ___

[issue1613500] Write mode option for fileinput module.

2019-04-27 Thread Berker Peksag
Change by Berker Peksag : -- pull_requests: +12909 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://

[issue36710] Pass _PyRuntimeState as an argument rather than using the _PyRuntime global variable

2019-04-27 Thread Eric Snow
Eric Snow added the comment: FWIW, I don't mean to side-track this issue. If we want to have any further discussion about broader solutions then let's take this to capi-sig. In fact, I've started a thread there. I'd post the link, but I think it got stuck in moderation. :) -- __

[issue36743] Docs: Descript __get__ signature defined differently across the docs

2019-04-27 Thread Karthikeyan Singaravelan
Change by Karthikeyan Singaravelan : -- nosy: +rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue36743] Docs: Descript __get__ signature defined differently across the docs

2019-04-27 Thread Jon Dufresne
New submission from Jon Dufresne : Here: https://docs.python.org/3/reference/datamodel.html#object.__get__ The __get__ signature is defined as: object.__get__(self, instance, owner) But here: https://docs.python.org/3/howto/descriptor.html#descriptor-protocol It is defined as: descr.__get__

[issue9521] xml.etree.ElementTree skips processing instructions when parsing

2019-04-27 Thread Stefan Behnel
Change by Stefan Behnel : -- Removed message: https://bugs.python.org/msg340994 ___ Python tracker ___ ___ Python-bugs-list mailing l

[issue36741] Variable about function and list

2019-04-27 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: You are passing a reference to the list so changes in Flash are made to the actual variable. Using cards.copy() instead of cards passes a copy of the list and hence modifications inside the function won't affect the original list. This is not a bug

[issue28460] Minidom, order of attributes, datachars

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: I'll close this as a duplicate of issue 34160. I'm aware that you also proposed to reduce the text escaping, but it's still needed for attribute values. Not sure if it's really worth having two different escape functions. Feel free to provide a PR and create

[issue36737] Warnings operate out of global runtime state.

2019-04-27 Thread Eric Snow
Eric Snow added the comment: Good point. Also, the whole idea of inheriting things (settings, some copied objects, etc.) into subinterpreters is interesting. My initial reaction is that folks would appreciate that feature, at least for a handful of things. It's not critical, but is worth

[issue35502] Memory leak in xml.etree.ElementTree.iterparse

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: This ticket looks like it's done for 3.7/8. Can it be closed? I guess 3.6 isn't relevant anymore, right? -- ___ Python tracker ___ ___

[issue25707] Add the close method for ElementTree.iterparse() object

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: I don't think there is a need for a close() method. Instead, the iterator should close the file first thing when it's done with it, but only if it owns it. Therefore, the fix in issue 25688 seems correct. Closing can also be done explicitly in a finaliser of

[issue35502] Memory leak in xml.etree.ElementTree.iterparse

2019-04-27 Thread STINNER Victor
STINNER Victor added the comment: The 3.6 branch no longer accept bugfixes. -- ___ Python tracker ___ ___ Python-bugs-list mailing

[issue8583] Hardcoded namespace_separator in the cElementTree.XMLParser

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Closing as a duplicate of the more general issue 18304. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> ElementTree -- provide a way to ignore namespace in tags and searches _

[issue2091] file accepts 'rU+' as a mode

2019-04-27 Thread Berker Peksag
Change by Berker Peksag : -- pull_requests: +12910 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mai

[issue36742] urlsplit doesn't accept a NFKD hostname with a port number

2019-04-27 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: This could be due to issue36216. -- nosy: +steve.dower, xtreak ___ Python tracker ___ _

[issue15388] SAX parse (ExpatParser) leaks file handle when given filename input

2019-04-27 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: Is this fixed with d81f9e24ea89c0aaded1e0d3f8d8076bbd58c19a ? -- nosy: +scoder, serhiy.storchaka, xtreak ___ Python tracker ___ ___

[issue33303] ElementTree Comment text isn't escaped

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Yes, comment text should be escaped internally like all other text, not by the user. The same applies to processing instructions. This suggests that it's probably also untested currently. Could you provide a PR for that changes both and adds tests? -

[issue21403] cElementTree's Element creation handles attrib argument different from ET

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: Let's not change this in Py2 anymore. -- resolution: -> wont fix stage: -> resolved status: open -> closed ___ Python tracker ___ __

[issue36722] In debug build, load also C extensions compiled in release mode or compiled using the stable ABI

2019-04-27 Thread STINNER Victor
STINNER Victor added the comment: New changeset 5c403b203510549a3f89d138d3265c5cc0cc12af by Victor Stinner (Paul Ganssle) in branch 'master': bpo-36722: Style and grammar edits for ABI news entries (GH-12979) https://github.com/python/cpython/commit/5c403b203510549a3f89d138d3265c5cc0cc12af

[issue36025] Breaking change in PyDate_FromTimeStamp API

2019-04-27 Thread Berker Peksag
Berker Peksag added the comment: New changeset 4d8c8c0ad6163c24136d3419eb04f310b31f7e64 by Berker Peksag (Paul Ganssle) in branch 'master': bpo-36025: Fix PyDate_FromTimestamp API (GH-11922) https://github.com/python/cpython/commit/4d8c8c0ad6163c24136d3419eb04f310b31f7e64 -- nosy: +

[issue2091] file accepts 'rU+' as a mode

2019-04-27 Thread Berker Peksag
Berker Peksag added the comment: New changeset 21a9ba1992775b5a833da28bfa0a9f028d1b6761 by Berker Peksag in branch 'master': bpo-2091: Fix typo in exception message (GH-12987) https://github.com/python/cpython/commit/21a9ba1992775b5a833da28bfa0a9f028d1b6761 -- nosy: +berker.peksag

[issue2091] file accepts 'rU+' as a mode

2019-04-27 Thread miss-islington
Change by miss-islington : -- pull_requests: +12911 ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://ma

[issue36741] Variable about function and list

2019-04-27 Thread 張晨韜
張晨韜 added the comment: Sorry. This is my first time to use this.Next time I'll notice. Thanks a lot for your fast and patient answer. -- ___ Python tracker ___

[issue36741] Variable about function and list

2019-04-27 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: No problem, closing this as not a bug. -- resolution: -> not a bug stage: -> resolved status: open -> closed type: compile error -> behavior ___ Python tracker _

[issue36025] Breaking change in PyDate_FromTimeStamp API

2019-04-27 Thread Berker Peksag
Change by Berker Peksag : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed type: -> behavior ___ Python tracker ___

[issue21536] extension built with a shared python cannot be loaded with a static python

2019-04-27 Thread Xavier de Gaye
Change by Xavier de Gaye : -- pull_requests: +12912 stage: resolved -> patch review ___ Python tracker ___ ___ Python-bugs-list mail

[issue2091] file accepts 'rU+' as a mode

2019-04-27 Thread Berker Peksag
Berker Peksag added the comment: New changeset f5972cc0c9a8e3315207e2d67534f330d619af4e by Berker Peksag (Miss Islington (bot)) in branch '3.7': bpo-2091: Fix typo in exception message (GH-12987) https://github.com/python/cpython/commit/f5972cc0c9a8e3315207e2d67534f330d619af4e -- _

[issue21536] extension built with a shared python cannot be loaded with a static python

2019-04-27 Thread Xavier de Gaye
Xavier de Gaye added the comment: PR 12989 fixes the Android issue and has been checked on the Android emulator at API 24. Python is cross-compiled with '--enable-shared' and the python-config scripts give the expected result: generic_x86_64:/data/local/tmp/python/bin $ python -c "from sysc

[issue22640] Add silent mode for py_compile

2019-04-27 Thread Joannah Nanjekye
Change by Joannah Nanjekye : -- nosy: +nanjekyejoannah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:

[issue15388] SAX parse (ExpatParser) leaks file handle when given filename input

2019-04-27 Thread Berker Peksag
Berker Peksag added the comment: I just tested the snippet in msg165779 under Windows with Python 2.7.16. I didn't get WindowsError after I called os.unlink(path) and verified that path is removed from the file system. I think we can close this issue as 'out of date'. -- nosy: +berk

[issue36744] functools.singledispatch: Shouldn't require a positional argument if there is only one keyword argument

2019-04-27 Thread Kevin
New submission from Kevin : Passing a single argument as a keyword argument to a function decorated with @functools.singledispatch results in an error: $ python Python 3.7.2 (default, Feb 12 2019, 08:15:36) [Clang 10.0.0 (clang-1000.11.45.5)] on darwin Type "help", "copyright", "credits" or "

[issue26978] Implement pathlib.Path.link (Using os.link)

2019-04-27 Thread Joannah Nanjekye
Change by Joannah Nanjekye : -- keywords: +patch pull_requests: +12913 stage: -> patch review ___ Python tracker ___ ___ Python-bug

[issue26835] Add file-sealing ops to fcntl

2019-04-27 Thread Joannah Nanjekye
Change by Joannah Nanjekye : -- nosy: +nanjekyejoannah ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https:

[issue36744] functools.singledispatch: Shouldn't require a positional argument if there is only one keyword argument

2019-04-27 Thread Karthikeyan Singaravelan
Karthikeyan Singaravelan added the comment: This was introduced as part of issue33967. -- nosy: +doerwalter, inada.naoki, lukasz.langa, xtreak ___ Python tracker ___ _

[issue26978] Implement pathlib.Path.link (Using os.link)

2019-04-27 Thread Karthikeyan Singaravelan
New submission from Karthikeyan Singaravelan : This looks same as https://bugs.python.org/issue28608 -- nosy: +xtreak versions: +Python 3.8 -Python 3.6 ___ Python tracker ___ _

[issue36744] functools.singledispatch: Shouldn't require a positional argument if there is only one keyword argument

2019-04-27 Thread Kevin
Kevin added the comment: I have read issue33967 before posting this one. The error message was introduced there, but the behavior hasn't changed. The problem that issue33967 solves is that while singledispatch requires at least one positional argument, there was no explicit error message tha

[issue35070] test_posix fails on macOS 10.14 Mojave

2019-04-27 Thread Jeffrey Kintscher
Jeffrey Kintscher added the comment: My mistake. It still failed with gcc 8.3.0. -- ___ Python tracker ___ ___ Python-bugs-list mai

[issue32424] Synchronize copy methods between Python and C implementations of xml.etree.ElementTree.Element

2019-04-27 Thread Stefan Behnel
Stefan Behnel added the comment: New changeset 50fed0b64faa305338ef5607b570fe209de6 by Stefan Behnel (Gordon P. Hemsley) in branch 'master': bpo-32424: Improve test coverage for xml.etree.ElementTree (GH-12891) https://github.com/python/cpython/commit/50fed0b64faa305338ef5607b570fe209

[issue24758] unittest.mock.Mock's new "unsafe" feature needs a better error message

2019-04-27 Thread Zackery Spytz
Change by Zackery Spytz : -- keywords: +patch pull_requests: +12914 stage: needs patch -> patch review ___ Python tracker ___ ___ Py

[issue24758] unittest.mock.Mock's new "unsafe" feature needs a better error message

2019-04-27 Thread Zackery Spytz
Zackery Spytz added the comment: I've created a PR for this issue. -- nosy: +ZackerySpytz versions: +Python 3.8 -Python 3.5 ___ Python tracker ___

<    1   2