Martin Panter added the comment:
The new “finditer” behaviour seems to contradict the documentation about
excluding empty matches if they touch the start of another match.
>>> list(re.finditer(r"\b|:+", "a::bc"))
[, , , , ]
An empty match at (1, 1) is incl
Martin Panter added the comment:
FWIW I find Mark’s suggestion pretty good:
“Each bitwise operation has the same result as though carried out in two's
complement using a bit-width that's large enough to represent the inputs.”
--
___
Pyth
Martin Panter added the comment:
P-ganssle seems to be proposing to limit parsing to exactly what
“datetime.isoformat” produces; i.e. whole number of seconds, milliseconds or
microseconds. Personally I would prefer it without this limitation, like in
Mathieu’s patches. But P-ganssle has done
Martin Panter added the comment:
The other difference is Mattieu guarantees ValueError for invalid input
strings, which I think is good.
--
___
Python tracker
<https://bugs.python.org/issue15
Martin Panter added the comment:
Similar changes were made in Issue 32150 and PR 3892 (tabs) and Mercurial
revision 98d1788c905c (trailing space and indentation). All the other tabs in
these patches appear to have been removed with other work: #29524, #31891,
#30747, #31373, PR 4275, #25658
Change by Martin Panter :
--
superseder: -> add exist_ok to shutil.copytree
___
Python tracker
<https://bugs.python.org/issue32247>
___
___
Python-bugs-lis
Change by Martin Panter :
--
dependencies: +Online doc does not include inspect.classify_class_attrs
___
Python tracker
<https://bugs.python.org/issue17
Martin Panter added the comment:
Regarding Matthieu’s RFC 3339 parser, Victor wanted to use the
round-half-to-even rule to get a whole number of microseconds. But considering
the “time” class cannot represent 24:00, how do you round up in the extreme
case past 23:59?
time.fromisoformat(&qu
Martin Panter added the comment:
Not if the time is associated with a particular day. Imagine implementing
datetime.fromisoformat by separately calling date.fromisoformat and
time.fromisoformat. The date will be off by one day if you naively rounded
2017-12-18 23:59 “up” to 2017-12-18 00:00
Martin Panter added the comment:
This was documented for the “getfullargspec” function in Issue 7422 (long
before “signature” existed). The error message was also clarified in Issue
6905. However IMO the term “Python function” is too subtle and ambiguous.
--
nosy: +martin.panter
Martin Panter added the comment:
My guess is there is no message because in Python 3, errors are encoded
according to PYTHONIOENCODING. Perhaps it works as you expect if you bypass
sys.excepthook:
$ PYTHONIOENCODING=undefined python -c 'import sys, os; sys.excepthook = lambda
*exc: os.
Martin Panter added the comment:
FWIW a few years ago I wrote a patch for Issue 17546 that documents three
personalities of “locals”, including:
* At the module level, the dictionary returned is the global symbol table, also
returned by :func:`globals`.
--
nosy: +martin.panter
Martin Panter added the comment:
I wrote an incremental base-64 decoder for the "codecs" module in Issue 27799,
which you could use. It just does some preprocessing using a regular expression
to pick four-character chunks before passing the data to a2b_base64. Or maybe
imple
Martin Panter added the comment:
In the server, the send_header("Connection", "close") call sets the
“close_connection” flag. This shuts down the connection once “do_GET” returns.
Without the flag set, the server will wait and read another request.
If you want th
Martin Panter added the comment:
Sorry William, I forgot the client was waiting to read. But I don’t understand
why your Connection field (which comes after the status line) allows the Python
client to read the status line. Perhaps there is some malware scanner,
firewall, or other proxy that
Martin Panter added the comment:
Thanks, although the fact that “Content-Length: 0” doesn’t work kills my theory
about the proxy.
The “close_connection” flag is also a documented public API of Python:
<https://docs.python.org/3/library/http.server.h
Martin Panter added the comment:
FWIW there was documentation in the README about the Setup files, removed in
Subversion r57681 (= Git revision 1c896e3). It looks like it still survives in
the 2.7 version.
--
nosy: +martin.panter
___
Python
Martin Panter added the comment:
Perhaps this can be treated as a duplicate of Issue 31639.
--
nosy: +martin.panter
___
Python tracker
<https://bugs.python.org/issue32
Change by Martin Panter :
--
superseder: HTTPServer can't deal with persistent connection properly ->
http.server and SimpleHTTPServer hang after a few requests
___
Python tracker
<https://bugs.python.org
Martin Panter added the comment:
Looks like you want to use a "readinto" method to reduce data copying.
One problem is that it is not specified exactly what kind of object
"copyfileobj" supports reading from. The documentation only says "file-like".
Accordi
Martin Panter 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
<https://bugs.python.org/issue33
Martin Panter added the comment:
Don’t forget about updating __all__.
--
___
Python tracker
<https://bugs.python.org/issue12486>
___
___
Python-bugs-list mailin
Martin Panter 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 versions.
--
___
Python tracker
<ht
Martin Panter 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
___
Python tracker
<ht
Martin Panter 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
undefined be
Martin Panter 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
<https://bugs.python.org/issue20
Martin Panter 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 431, in urlsplit
raise Va
Martin Panter 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.org/wiki/Unix_time#TAI-based_vari
Martin Panter 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: +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
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
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
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
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.
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
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
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
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
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
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
Change by Martin Panter :
--
superseder: -> make install fails: no module _ctypes
___
Python tracker
<https://bugs.python.org/issue32401>
___
___
Python-
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
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
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
Change by Martin Panter :
--
resolution: -> duplicate
stage: -> resolved
status: open -> closed
superseder: -> mingw-meta: build interpeter core
___
Python tracker
<https://bugs.python
Martin Panter added the comment:
Similar to Issue 31882
--
nosy: +martin.panter
___
Python tracker
<https://bugs.python.org/issue29253>
___
___
Python-bug
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
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
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
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”, and
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
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&
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
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
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.
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 serv
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
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
Change by Martin Panter :
--
resolution: -> duplicate
status: open -> pending
___
Python tracker
<https://bugs.python.org/issue33300>
___
___
Python-bugs-
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
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
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
Change by Martin Panter :
--
superseder: -> Cannot override 'connection: close' in urllib2 headers
___
Python tracker
<https://bugs.pytho
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
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) and
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 a
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
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 d
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
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
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 addi
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
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
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
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
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
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
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
Martin Panter added the comment:
Déjà vu. Maybe duplicate of Issue 34624?
--
nosy: +martin.panter
superseder: -> -W option does not accept module regexes
___
Python tracker
<https://bugs.python.org/issu
Martin Panter added the comment:
Have you seen
<https://docs.python.org/3/faq/design.html#why-are-floating-point-calculations-so-inaccurate>?
It already links to the tutorial.
--
nosy: +martin.panter
___
Python tracker
<https://bugs.p
Martin Panter added the comment:
RFC 6265 says that only the first three letters of the month are significant,
and the rest of the token should be ignored. See
<https://tools.ietf.org/html/rfc6265#section-5.1.1>:
month = ( "jan" / "feb" / "mar" / &quo
Change by Martin Panter :
--
resolution: -> duplicate
stage: -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.org/issue34920>
___
___
Change by Martin Panter :
--
assignee: -> docs@python
components: +Documentation
nosy: +docs@python
title: StreamIO truncate behavior of current position -> StringIO module
truncate behavior of current position
___
Python tracker
Change by Martin Panter :
--
Removed message: https://bugs.python.org/msg328245
___
Python tracker
<https://bugs.python.org/issue28960>
___
___
Python-bugs-list m
Martin Panter added the comment:
There seem to be at least two different issues raised here (and in Issue 34547):
1. Double exceptions due to “self.environ” and “self.status” being None when
the error handler is called. This problem was specifically raised in Issue
29183.
2. What to do
Martin Panter added the comment:
Looks like the error handling is broken by Issue 16220, which calls the
“BaseHandler.close” method before the exception is caught for the error
handler. Perhaps it is better to just close the iterator without messing with
the other attributes in the exception
Martin Panter added the comment:
Looks like this is about about making “RawIOBase.read” delegate to “readinto”
with a “bytes” object. If so, there’s more discussion in Issue 15903.
--
nosy: +martin.panter
___
Python tracker
<ht
Martin Panter added the comment:
There are actually two “close” methods in the WSGI package: ServerHandler’s
implementation extends the BaseHandler implementation. Making the “close”
methods do nothing if called a second time would avoid the error about
“self.status” being None, but won’t
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue8402>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue15955>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue16043>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue17005>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue16901>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue9740>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue6181>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue15125>
___
___
Python-bugs-list mailing list
Unsubscribe:
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue17974>
___
___
Python-bugs-list mailing list
Unsubscribe:
Martin Panter added the comment:
I was surprised to discover that “option straddling” doesn’t work this way with
nargs="*". It seems to work fine with most other kinds of positional arguments
I have tried, and I imagine that this was by design rather than accident. Many
Gnu CLI pro
Martin Panter added the comment:
It sounds like this bug might cover Issue 15112, which is only concerned with
options between different positional parameters.
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue14
Changes by Martin Panter :
--
nosy: +vadmium
___
Python tracker
<http://bugs.python.org/issue1944>
___
___
Python-bugs-list mailing list
Unsubscribe:
401 - 500 of 4320 matches
Mail list logo