[issue33173] GzipFile's .seekable() returns True even if underlying buffer is not seekable

2018-10-06 Thread Martin Panter
Martin Panter added the comment: If a change is made, it would be nice to bring the “gzip”, “bzip” and LZMA modules closer together. The current “bzip” and LZMA modules rely on the underlying “seekable” method without a fallback implementation, but also have a check for read mode. I think

[issue26005] Denial of Service in SimpleHTTPServer and BaseHTTPServer

2018-10-04 Thread Martin Panter
Martin Panter added the comment: Issue 34576 was recently opened about adding a security warning. -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> [EASY doc] http.server, SimpleHTTPServer: warn users

[issue34576] [EASY doc] http.server, SimpleHTTPServer: warn users on security

2018-10-04 Thread Martin Panter
Martin Panter added the comment: FYI Senthil made an earlier suggestion for wording at <https://bugs.python.org/issue26005#msg257517> -- nosy: +martin.panter ___ Python tracker <https://bugs.python.org/i

[issue34711] Fix test_httpservers on AIX (trailingSlashOK)

2018-10-02 Thread Martin Panter
Martin Panter added the comment: Hi Michael, I agree with Victor that the best place to fix the problem is in the HTTP server module. In other words, the “medium fix” you mentioned in your original post. Your recent proposal to just skip the test means that AIX will continue to suffer from

[issue34785] pty.spawn -- auto-termination after child process is dead (a zombie)

2018-09-29 Thread Martin Panter
Martin Panter added the comment: Is this to get “spawn” working on a non-Linux platform like a recent Free BSD, OS X, or Solaris? If so, see Issue 26228. If not, you might have to explain your use case better. Polling for the child exiting is going to race with handling the child’s output

[issue34771] test_ctypes failing on Linux SPARC64

2018-09-28 Thread Martin Panter
Martin Panter added the comment: Seems to be a common theme on various 64-bit ABIs. There is already a fix for Python’s Windows copy of the FFI library (Issue 29565), and a “hack” for Arm and x86 Windows (again!): Issue 30353. -- nosy: +martin.panter

[issue34817] Ellipsis docs has extra dot in the markdown that makes it look like .... (four dots)

2018-09-28 Thread Martin Panter
Martin Panter added the comment: In these situations, I use quotes or brackets to mention a symbol without using it as punctuation. Using words might also help. What about: Ellipsis The same as the ellipsis literal “...”. Special value used [etc] -- nosy: +martin.panter

[issue25095] test_httpservers hangs since Python 3.5

2018-09-28 Thread Martin Panter
Martin Panter added the comment: Hi William, when I mentioned “Content-Length”, I meant adding it to the response from the server. See the second version of “do_GET” in my earlier comment <https://bugs.python.org/issue25095#msg309522>. But that is no good without also

[issue34369] kqueue.control() documentation and implementation mismatch

2018-09-28 Thread Martin Panter
Martin Panter added the comment: I think removing all mention of “None” is a step too far. The “devpoll”, “epoll”, and “poll” documentation all say that “None” is acceptable for the timeout. Only the “select” function doesn’t say this. What about adding to the text: * “timeout” in seconds

[issue34642] time.ctime() uses %3d instead of %.2d to format.

2018-09-11 Thread Martin Panter
Martin Panter added the comment: I think "ctime" and "asctime" are supposed to wrap or imitate the standard C functions: <https://port70.net/~nsz/c/c11/n1570.html#7.27.3.2>, so I think this is intended behaviour. But see Issue 13927 about improving the documentatio

[issue34600] python3 regression ElementTree.iterparse() unable to capture comments

2018-09-09 Thread Martin Hosken
Martin Hosken added the comment: Blast. Bugs. Sorry. Missing superclass init call in CommentingTb. I enclose the whole thing again to save editing. Also fixes comment output to give text. from __future__ import print_function import sys import xml.etree.ElementTree as et import

[issue34600] python3 regression ElementTree.iterparse() unable to capture comments

2018-09-09 Thread Martin Hosken
Martin Hosken added the comment: Sorry. This test is rather long because it is 3 tests: from __future__ import print_function import sys import xml.etree.ElementTree as et import xml.etree.cElementTree as cet from io import StringIO teststr = u""" Hello World

[issue34600] python3 regression ElementTree.iterparse() unable to capture comments

2018-09-07 Thread Martin Hosken
New submission from Martin Hosken : This is a regression from python2 by being forced to use cElementTree. I have code that uses iterparse to process an XML file, but I also want to process comments and so I have a comment handling function called by the parser during iterparse. Under

[issue34566] pipe read sometimes returns EOF but returncode is still None

2018-09-05 Thread Martin Panter
Martin Panter added the comment: You probably only need to call "wait" once. That blocks the thread until it gets a result, so it is more CPU-efficient than calling "poll" in a busy loop. Since you open a separate pipe for "stderr" in script.py, but don't do

[issue34566] pipe read sometimes returns EOF but returncode is still None

2018-09-03 Thread Martin Panter
Martin Panter added the comment: The "grep" process may be closing its end of the pipe before it exits. Or if Grep leaves the pipe open when it exits, the OS may close the pipe before it makes the child exit status available. Either way, I suspect "p.stdout.read()" ret

[issue5038] urrlib2/httplib doesn't reset file position between requests

2018-09-02 Thread Martin Panter
Martin Panter added the comment: Here is a demonstration script in case it helps. I haven’t tested it with versions before Python 2.6. Older versions send “Content-Length: 11”, but leave the server hanging trying to read the data. Newer versions (I presume since Issue 12319, 3.6+) send

[issue34516] httplib sets unbefitting "Host" in request header when requests an ipv6 format url.

2018-08-28 Thread Martin Panter
Martin Panter added the comment: This sounds like a duplicate of Issue 28539. My understanding of that report is that Urllib3 half parses the URL by splitting out the port number, but returns a hostname with square brackets intact. Requests then passes the hostname (string with brackets

[issue34425] :s formatting broken for objects without __format__

2018-08-17 Thread Martin Panter
Martin Panter added the comment: It looks like you are describing the result of Issue 7994. Documentation: https://docs.python.org/release/3.5.3/reference/datamodel.html#object.__format__ https://docs.python.org/release/3.5.3/whatsnew/3.4.html#api-and-feature-removals -- nosy

[issue34357] situation where urllib3 works, but urllib does not work

2018-08-13 Thread Martin Panter
Change by Martin Panter : -- superseder: -> Cannot override 'connection: close' in urllib2 headers ___ Python tracker <https://bugs.python.org/issu

[issue34357] situation where urllib3 works, but urllib does not work

2018-08-13 Thread Martin Panter
Martin Panter added the comment: I can’t get it to hang. Does your computer or Internet provider have a proxy or firewall that may be interfering? Perhaps it is worth comparing the HTTP header fields being sent and received. You can enable debug messages to see the request sent, and print

[issue34369] kqueue.control() documentation and implementation mismatch

2018-08-12 Thread Martin Panter
Martin Panter added the comment: Even in 3.8, the main documentation is not fixed: https://docs.python.org/dev/library/select.html#kqueue-objects -- ___ Python tracker <https://bugs.python.org/issue34

[issue34369] kqueue.control() documentation and implementation mismatch

2018-08-11 Thread Martin Panter
Martin Panter added the comment: I think this was an attempt to specify a positional-only parameter (by using square brackets), and include a default value in the signature. The usual approach in this situation is to use square brackets, but only mention the default value in the text

[issue33300] Bad usage example in id() DocString

2018-08-11 Thread Martin Panter
Change by Martin Panter : -- resolution: -> duplicate status: open -> pending ___ Python tracker <https://bugs.python.org/issue33300> ___ ___ Python-bugs-

[issue22852] urllib.parse wrongly strips empty #fragment, ?query, //netloc

2018-08-04 Thread Martin Panter
Martin Panter added the comment: I like this option. I suppose choosing which option to take is a compromise between compatiblity and simplicity. In the short term, the “allows_none” option requires user code to be updated. In the long term it may break compatibility. But the “has_netloc

[issue33649] asyncio docs overhaul

2018-08-04 Thread Martin Altmayer
Change by Martin Altmayer : -- nosy: +MartinAltmayer ___ Python tracker <https://bugs.python.org/issue33649> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue34256] Python treats ASCII record separator ('\x1e') as a newline

2018-08-03 Thread Martin Panter
Martin Panter added the comment: What documentation were you looking at? I remember adding 0x1E and others to the list in Issue 12855. See <https://docs.python.org/3.5/library/stdtypes.html#str.splitlines>: ‘‘‘ str.splitlines([keepends]) . . . This method splits on the followin

[issue25095] test_httpservers hangs since Python 3.5

2018-07-31 Thread Martin Panter
Martin Panter added the comment: I reproduced the problem on a Windows computer, and now understand why my "Content-Length: 0" suggestion isn't good enough on its own. It does solve the initial deadlock, but there is a further deadlock. The main thread is waiting for the server to

[issue34276] urllib.parse doesn't round-trip file URI's with multiple leading slashes

2018-07-31 Thread Martin Panter
Martin Panter added the comment: Yes urllib doesn’t distinguish a missing authority/netloc from an empty string. The same for the ?query and #fragment parts. There is Issue 22852 open about that. -- ___ Python tracker <https://bugs.python.

[issue34276] urllib.parse doesn't round-trip file URI's with multiple leading slashes

2018-07-30 Thread Martin Panter
Martin Panter added the comment: I think your URLs are valid by RFC 3986. "When authority is not present" refers to URLs without the double-slash prefix, like the "urn:example:animal:ferret:nose". The RFC treats empty authority and no authority as different cases. If

[issue32084] [Security] http.server can be abused to redirect to (almost) arbitrary URL

2018-07-30 Thread Martin Panter
Martin Panter added the comment: In Issue 34276 I suggested a fix to “urlunsplit”. In this case it would send “Location: www.python.org/%2f../", with an extra pair of slashes denoting an empty host name. This should stop a browser from seeing “www.python.org” as a host

[issue23505] Urlparse insufficient validation leads to open redirect

2018-07-30 Thread Martin Panter
Martin Panter added the comment: Issue 34276 was opened about a similar case for “file:” URLs. I believe both “file:” scheme and no-scheme cases are a regression and could be fixed by adding another pair of slashes (an empty “netloc” part): >>> urlparse("foo.com&

[issue34276] urllib.parse doesn't round-trip file URI's with multiple leading slashes

2018-07-30 Thread Martin Panter
Martin Panter added the comment: This may be a very old regression (from 2002) caused by Issue 591713 and Mercurial rev. 554f975073a0. The original check for the double slash, added in 0d6bd391acd8, “escapes” a path beginning with a double slash by prefixing it with two more slashes (empty

[issue34281] "Go to Line" broken on OS X

2018-07-30 Thread Eric Martin
New submission from Eric Martin : After entering a line number, clicking OK brings to the foreground and makes active the first hidden window (in the simplest case where we have just one window for a .py file and the Shell window, the former being in the foreground, clicking OK brings

[issue34263] asyncio: "relative *delay* or absolute *when* should not exceed one day"

2018-07-28 Thread Martin Altmayer
Martin Altmayer added the comment: Added a small PR. Shall we update the doc? With this PR there is no reason anymore to disallow timeouts greater than one day in asyncio. Greetings from the sprints @ Edinburgh! -- nosy: +MartinAltmayer

[issue34263] asyncio: "relative *delay* or absolute *when* should not exceed one day"

2018-07-28 Thread Martin Altmayer
Change by Martin Altmayer : -- keywords: +patch pull_requests: +8048 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue34263> ___ ___ Py

[issue34158] Documentation of datetime '%z' format code is odd

2018-07-22 Thread Martin Panter
Martin Panter added the comment: FWIW more oddities with this paragraph could be fixed by: * removing the first “and” from “HH is . . ., [and] MM is . . ., SS is . . . and uu is”, * changing the condition for omitting “uu” from “a whole number of [minutes]” to “seconds

[issue31935] subprocess.run() timeout not working with grandchildren and stdout=PIPE

2018-07-22 Thread Martin Panter
Martin Panter added the comment: Closing in faviour of Issue 30154, which suggests documentation or adjusting the timeout implementation. There is also Issue 26534 proposing a new “kill_group” option when using the timeout feature. -- resolution: -> duplicate stage: -> re

[issue33154] subprocess.Popen ResourceWarning should have activation-deactivation flags

2018-07-22 Thread Martin Panter
Martin Panter added the comment: Can’t you use Python’s existing CLI <https://docs.python.org/3.6/using/cmdline.html#cmdoption-w> and environment variable <https://docs.python.org/3.6/using/cmdline.html#envvar-PYTHONWARNINGS> to control the ResourceWarning messages? Warnings w

[issue29253] Fix test_asyncore tests on Cygwin

2018-07-19 Thread Martin Panter
Change by Martin Panter : -- superseder: -> Cygwin: asyncio and asyncore test suites hang indefinitely due to bug in Cygwin ___ Python tracker <https://bugs.python.org/issu

[issue29253] Fix test_asyncore tests on Cygwin

2018-07-19 Thread Martin Panter
Martin Panter added the comment: Similar to Issue 31882 -- nosy: +martin.panter ___ Python tracker <https://bugs.python.org/issue29253> ___ ___ Python-bug

[issue18397] Python with MinGW

2018-07-19 Thread Martin Panter
Change by Martin Panter : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> mingw-meta: build interpeter core ___ Python tracker <https://bugs.python

[issue34128] Release GIL periodically in _pickle module

2018-07-17 Thread Martin Bammer
Martin Bammer added the comment: Maybe an optional parameter with the desired interval would be good idea. So that the coder can decide if he wants/needs that feature and which interval he needs for his application. Otherwise it is hard to define a specific interval which fits for everyone

[issue34128] Do not block threads when pickle/unpickle

2018-07-16 Thread Martin Bammer
New submission from Martin Bammer : Hi, the old and slow python implementation of pickle didn't block background thread. But the newer C-implementation blocks other threads while dump/load is running. Wouldn't it be possible to allow other threads during this time? Especially could load/loads

[issue34091] REPL does not work in msys2, ConEmu terminals on windows

2018-07-11 Thread Martin Panter
Martin Panter added the comment: The problem as I understand it is that Msys uses a pipe, but Python by default limits interactive REPL mode to terminals only. The same thing happens if you start Python on a pipe some other way, for instance “cat | python” vs “cat | python -i”. I would

[issue31652] make install fails: no module _ctypes

2018-07-07 Thread Martin Panter
Martin Panter added the comment: In <https://bugs.python.org/issue32401#msg308926> Chi-Hsuan suggests “configure --without-ensurepip” as a workaround. -- nosy: +martin.panter ___ Python tracker <https://bugs.python.org/i

[issue34036] ModuleNotFoundError: No module named '_ctypes' when install Python 3.7 on Linux

2018-07-07 Thread Martin Panter
Martin Panter added the comment: Ctypes is meant to be (at least it used to be) an optional module. If you don’t actually care about building ctypes, this might be the same as Issue 31652. Using “configure --without-ensurepip” was suggested as a workaround. If you do want ctypes to be built

[issue32401] No module named '_ctypes'

2018-07-07 Thread Martin Panter
Change by Martin Panter : -- superseder: -> make install fails: no module _ctypes ___ Python tracker <https://bugs.python.org/issue32401> ___ ___ Python-

[issue31839] datetime: add method to parse isoformat() output

2018-07-06 Thread Martin Panter
Change by Martin Panter : -- resolution: -> duplicate stage: -> resolved status: open -> closed superseder: -> datetime: add ability to parse RFC 3339 dates and times ___ Python tracker <https://bugs.python

[issue24935] LDSHARED is not set according when CC is set.

2018-06-25 Thread Martin Scherer
Change by Martin Scherer : -- keywords: +patch pull_requests: +7517 stage: -> patch review ___ Python tracker <https://bugs.python.org/issue24935> ___ ___ Py

[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-06-16 Thread Martin Panter
Martin Panter added the comment: I think it is okay to leave out the options for the unpacking case. But I think it is worth clarifying that the single-target case also applies without parentheses, but that it doesn’t apply if there is a trailing comma. So: ‘‘‘ If the target list is a single

[issue33878] Doc: Assignment statement to tuple or list: case missing.

2018-06-16 Thread Martin Panter
Martin Panter added the comment: I think I intended the third option to include all comma-separated lists, including: a, b, c = x # No brackets (a, b, c) = x # Round brackets [a, b, c] = x # Square brackets a, = x # Single target with comma Perhaps something like this would be clearer

[issue33630] test_posix: TestPosixSpawn fails on PPC64 Fedora 3.x

2018-06-16 Thread Martin Panter
Martin Panter added the comment: I doubt it is a race condition. “Waitpid” only returns after the child has terminated, and the file should be created as the child starts, before it terminates. Surely it is just the buggy glibc opening the DBDBDB file, when the test case expects it to create

[issue11380] Improve reporting of broken stdout pipe during interpreter shutdown

2018-06-16 Thread Martin Panter
Martin Panter added the comment: Issue 33550 was opened about Mike’s case of ignoring broken pipe conditions. BTW a side effect of closing sys.stderr is that error messages reported by interpreter shutdown will be missing (even if there was no broken pipe). For example, exception messages

[issue24415] SIGINT always reset to SIG_DFL by Py_Finalize()

2018-06-15 Thread Martin Panter
Martin Panter added the comment: It is worth checking if at least the first half of the report was fixed by Issue 30654 -- nosy: +martin.panter superseder: -> signal module always overwrites SIGINT on interpreter shutdown ___ Python trac

[issue33837] Closing asyncio.Server on asyncio.ProactorEventLoop causes all active servers to stop listening

2018-06-11 Thread Martin Liska
New submission from Martin Liska : When calling asyncio.Server.close, the method calls asyncio.AbstractEventLoop._stop_serving for each of its sockets in turn. The implementation of this method in asyncio.ProactorEventLoop calls the _stop_accept_futures method which seems to cancel "a

[issue33830] example output error

2018-06-11 Thread Martin Panter
Martin Panter added the comment: Looks like poor application of a Python 3 patch in Issue 24118. The second request was meant to be for /parrot.spam. -- nosy: +benjamin.peterson, martin.panter ___ Python tracker <https://bugs.python.

[issue33687] uu.py calls os.path.chmod which doesn't exist

2018-06-10 Thread Martin Panter
Martin Panter added the comment: What is your use case, Poul-Henning? It looks like the module has never set the file mode, at least since it was added to Python in 1994. I suggest just remove the dead code and fix the documentation. At least you shouldn’t make this change in bug fix

[issue33762] temp file isn't IOBase

2018-06-09 Thread Martin Panter
Martin Panter added the comment: I think it is an implementation detail whether the result subclasses IOBase or just implements its API. Why do you want to check the base class, and why IOBase in particular, rather than BufferedIOBase, RawIOBase, or TextIOBase

[issue26175] Fully implement IOBase abstract on SpooledTemporaryFile

2018-06-09 Thread Martin Panter
Martin Panter added the comment: I was making suggestions, not demanding anything. Except for the quirk with __del__, Gary’s changes (revision fb28362) look okay to add on their own as a bug fix. I wouldn’t claim that IOBase is “fully implemented” however, until the return values for “seek

[issue33693] test test_webbrowser failed

2018-05-30 Thread Martin Panter
Martin Panter added the comment: This sounds like the existing bug Issue 31014 -- nosy: +martin.panter superseder: -> webbrowser._synthesize uses outdated calling signature for webbrowser.register ___ Python tracker <https://bugs.pyth

[issue33632] undefined behaviour: signed integer overflow in threadmodule.c

2018-05-24 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Looks like this is what my thread.patch was fixing in <https://bugs.python.org/issue1621#msg271057>. You’re welcome to use my patch, but I won’t have time to work on it myself. -- nosy: +m

[issue33579] calendar.timegm not always an inverse of time.gmtime

2018-05-19 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: According to Wikipedia, there were 24 leap seconds before Feb 2009. So my guess is Eitan’s “gmtime” implementation is calculating the date as if the timestamp (1234567899) includes leap seconds, as in <https://en.wikipedia

[issue33342] urllib IPv6 parsing fails with special characters in passwords

2018-05-19 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: I presume this is about parsing a URL like >>> urlsplit("//user:[@host") Traceback (most recent call last): File "", line 1, in File "/home/proj/python/cpython/Lib/urllib/parse.py", line 4

[issue33384] Build does not work with closed stdin

2018-05-19 Thread Martin Husemann
Martin Husemann <mar...@netbsd.org> added the comment: You need to exit the parent shell, to get the original stdin revoke(2)'d. That is: the Ctrl-D in the original descritpion is not line noise. Sorry, should have been more explicit (or used "exit" or s

[issue20941] pytime.c:184 and pytime.c:218: runtime error, outside the range of representable values of type 'long'

2018-05-18 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: I don’t know; I haven’t tested it. I was anticipating that it is fixed, but perhaps I should leave the resolution alone instead? -- ___ Python tracker <rep...@bugs.python.or

[issue20941] pytime.c:184 and pytime.c:218: runtime error, outside the range of representable values of type 'long'

2018-05-18 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Maybe worth checking if this is fixed due to the changes in Issue 31373 for 3.6+. -- nosy: +martin.panter resolution: -> out of date superseder: -> demoting floating float values to unrepresentable types is undefi

[issue33321] Add a Linux clang ubsan undefined behavior sanitizer buildbot

2018-05-18 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Perhaps your “ctypes” problems may be helped by my ctypes_v2.patch in Issue 1621. Or perhaps they are already documented in Issue 15119 and/or Issue 28169. -- nosy: +martin.panter ___

[issue1621] Do not assume signed integer overflow behavior

2018-05-18 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Sorry I haven’t made a PR for ctypes_v2.patch, but I don’t mind if someone else takes over. I understand the HAVE_LONG_LONG check may no longer necessary for newer Python ve

[issue12486] tokenize module should have a unicode API

2018-05-18 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Don’t forget about updating __all__. -- ___ Python tracker <rep...@bugs.python.org> <https://bugs.python

[issue33341] python3 fails to build if directory or sysroot contains "*icc*" string

2018-05-17 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Maybe this is the same as Issue 28584, about the ${CC} variable rather than “sysroot”. In any case, the patch looks unrelated. -- nosy: +martin.panter ___ Python tracker <rep...@bugs.p

[issue33481] configparser.write() does not save comments.

2018-05-14 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Looks like Issue 1410680 has a new function to merge comments with new config values (among other things). -- nosy: +martin.panter ___ Python tracker <rep...@bugs.python.or

[issue32393] nav menu jitter in old documentation

2018-05-14 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Maybe related to Issue 24712? -- nosy: +martin.panter ___ Python tracker <rep...@bugs.python.org> <https://bugs.python

[issue20104] expose posix_spawn(p)

2018-05-14 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: I suggested the “scheduler” tuple to bring the two related parameters (scheduling policy and sched_param) together, similar to how they are paired as the second and third parameters to “os.sched_setscheduler”, and because I t

[issue33413] asyncio.gather should not use special Future

2018-05-10 Thread Martin Teichmann
Martin Teichmann <martin.teichm...@gmail.com> added the comment: I looked a bit into the details, and found that bpo-30048 created the described weird behavior. There they fixed the problem that a cancel is ignored if a coroutine manages to cancel its own task and return immediately. As

[issue33294] Support complex expressions for py-print command.

2018-05-09 Thread Martin Liška
Martin Liška <marxin.li...@gmail.com> added the comment: May I please ping patch review.. -- ___ Python tracker <rep...@bugs.python.org> <https://bugs.python

[issue20104] expose posix_spawn(p)

2018-05-06 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Can you use the existing sched_param class? https://docs.python.org/3/library/os.html#os.sched_param -- ___ Python tracker <rep...@bugs.python.org> <https://bugs.python

[issue20104] expose posix_spawn(p)

2018-05-06 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: To wrap “posix_spawnattr_setschedparam” perhaps you could combine it with the scheduler policy: # Inherit current policy and parameters: posix_spawn(..., scheduler=None) # Set new policy with parameters: posix_spawn(..., sch

[issue33411] All console message are in the error output in bash interpretor

2018-05-05 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: The exception message and stack trace is documented to go to stderr: <https://docs.python.org/2/library/sys.html#sys.excepthook>. Whether the prompt “>>>” goes to stderr or stdout depends on quirks of the en

[issue33413] asyncio.gather should not use special Future

2018-05-02 Thread Martin Teichmann
Change by Martin Teichmann <martin.teichm...@gmail.com>: -- keywords: +patch pull_requests: +6388 stage: -> patch review ___ Python tracker <rep...@bugs.python.org> <https://bugs.pyt

[issue33413] asyncio.gather should not use special Future

2018-05-02 Thread Martin Teichmann
New submission from Martin Teichmann <martin.teichm...@gmail.com>: asyncio.gather() returns a _GatheringFuture, which inherits from asyncio.Future. This is weird in current asyncio, as futures are supposed to be created with loop.create_future(). So I tried to reimplement gather() w

[issue33384] Build does not work with closed stdin

2018-04-29 Thread Martin Husemann
New submission from Martin Husemann <mar...@netbsd.org>: When building python extensions in the background w/o stdin (and stderr and stdout redirected to a log file), the invocation of setup.py fails. Normal build in a shell: Example from pyexpat: > /usr/pkg/bin/python3.6 setup.

[issue28627] [alpine] shutil.copytree fail to copy a direcotry with broken symlinks

2018-04-20 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: This looks like it may be covered by Issue 31940, about the “shutil.copystat” API. See Anthony’s initial proposal at <https://bugs.python.org/issue31940#msg305528>. Max: I think you need the “else” branch to reraise t

[issue33300] Bad usage example in id() DocString

2018-04-17 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: It is supposed to be a function signature, similar to the syntax when you define your own function, rather than a usage example of calling the function. In this case, the slash notation is described by PEP 457. It is supposed to in

[issue33294] Support complex expressions for py-print command.

2018-04-17 Thread Martin Liška
New submission from Martin Liška <marxin.li...@gmail.com>: The patch is based on a blog post: http://kouk.surukle.me/2014/09/25/debugging-python-objects-and-fields-with-gdb/. Adding him: @kouk Purpose of the pull request is to support more complex expressions for py-print command.

[issue33239] tempfile module: functions with the 'buffering' option are incorrectly documented

2018-04-08 Thread Martin Falatic
Martin Falatic <mar...@falatic.com> added the comment: The correction of `buffering=None` --> `buffering=-1` for the defaults definitely needs to happen. A reference to `open()` is already present in the 3.x documentation: "buffering, encoding and newline are interpret

[issue33241] Tooltip not display with macOS 64-bit installer 3.6.5 but work with macOS 64-bit/32-bit installer

2018-04-08 Thread Louis Martin
New submission from Louis Martin <louis.martin.u...@gmail.com>: Tested with : from appJar import gui with gui() as app: app.label('hello world', tip="help me") app.addLabel("l1", "text")

[issue33241] Tooltip not display with macOS 64-bit installer 3.6.5 but work with macOS 64-bit/32-bit installer

2018-04-08 Thread Louis Martin
Change by Louis Martin <louis.martin.u...@gmail.com>: -- components: Tkinter nosy: louis-martin priority: normal severity: normal status: open title: Tooltip not display with macOS 64-bit installer 3.6.5 but work with macOS 64-bit/32-bit installer versions: Pyth

[issue33239] tempfile module: functions with the 'buffering' option are incorrectly documented

2018-04-07 Thread Martin Falatic
New submission from Martin Falatic <mar...@falatic.com>: The documentation for the tempfile module in Python 3.x for the `buffering` option is incorrect: https://docs.python.org/3/library/tempfile.html TemporaryFile, NamedTemporaryFile, and SpooledTemporaryFile all take the `buf

[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-04-04 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Sorry, I realize there is a problem remaining with the pointer types for "Noddy_name" (Noddy vs PyObject pointers), so you can't remove the cast there. But my suggestion should still apply to other places, for instance

[issue33012] Invalid function cast warnings with gcc 8 for METH_NOARGS

2018-04-01 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Siddhesh, it looks like your fixes make the C function signatures match the signature expected in the PyMethodDef structure. If so, I suggest to remove the (PyCFunction) casts from those structure definitions as well. For instanc

[issue22781] ctypes: Differing results between Python and C.

2018-04-01 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Eryk Sun’s explanation makes this sound like a duplicate of Issue 15453, which shows GCC on Linux packing structures into a single byte, and ctypes using the size of the expanded integer type. -- nosy: +martin.panter reso

[issue33079] subprocess: document the interaction between subprocess.Popen and os.set_inheritable

2018-03-25 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: There is no “open_fds” parameter as far as I know. I presume you meant heritable descriptors are still closed with close_fds=True (not open_fds=False). Are you sure about the second part? In my experiments on Linux, unless

[issue31823] Opaque default value for close_fds argument in Popen.__init__

2018-03-25 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: The close_fds= in that signature seems fine to me. If you read the documentation, it says the default mode depends on the platform, and on other parameters. However I think the signature at <https://docs.python.org/release/3.6.

[issue32270] subprocess closes redirected fds even if they are in pass_fds

2018-03-25 Thread Martin Panter
Change by Martin Panter <vadmium...@gmail.com>: -- nosy: +martin.panter ___ Python tracker <rep...@bugs.python.org> <https://bugs.python.org/issue32270> ___

[issue33112] SequenceMatcher bug

2018-03-20 Thread Martin
New submission from Martin <ma...@dtu.dk>: difflib.SequenceMatcher fails to make a proper alignment between 2 sequences with only 3 single letter changes. Its performance is completely off with a similarity ratio of 0.16, in stead of the more accurate 0.99. Here is a snippet to rep

[issue33110] Adding a done callback to a concurrent.futures Future once it has already completed, may raise an exception, contrary to docs

2018-03-20 Thread Sam Martin
New submission from Sam Martin <nivek...@gmail.com>: Whilst working with concurrent.futures and ThreadPoolExecutors, my colleague and I have noted some undocumented behaviour. When adding a done_callback to a future that has already completed, we note that that callback is executed di

[issue27069] webbrowser creates zombi processes in the background mode

2018-03-17 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: It does look similar. They probably could be merged. The main difference is in Issue 5993 Eivind suggested to somehow use a “wait” system call, while here Victor suggested “fork” (perhaps to orphan a grandchild p

[issue33062] ssl_renegotiate() doesn't seem to be exposed

2018-03-13 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: I have also wanted to force renegotation for testing with Python. As a workaround, I have used the "openssl s_server" program, which I described at <https://bugs.python.org/issue25919#msg257508> (use the lower-ca

[issue32993] urllib and webbrowser.open() can open w/ file: protocol

2018-03-11 Thread Martin Panter
Martin Panter <vadmium...@gmail.com> added the comment: Hi Yao, I tend to agree with Ned. The support for “file:” URLs is by design. I don’t see any security problems. I suggest to close this. In Issue 11662, it was decided that a web server redirecting to a “file:” URL was a security p

[issue32732] LoggingAdapter ignores extra kwargs of Logger#log()

2018-03-01 Thread Cyril Martin
Cyril Martin <mcool...@gmail.com> added the comment: Hello Vinay, I strongly disagree with you. In the Python documentation (https://docs.python.org/3/library/logging.html), we can read the following for the debug function: > The third keyword argument is extra which can be use

<    1   2   3   4   5   6   7   8   9   10   >