New submission from Daniel Draper :
Hi,
According to
https://peps.python.org/pep-0544/#explicitly-declaring-implementation it should
be possible to explicitly inherit from Protocols. This however breaks the
dataclass constructor when using the @property decorator in the protocol, see
this
Daniel Hillier added the comment:
Related to issue https://bugs.python.org/issue28080 which has a patch that
covers a bit of this issue
--
___
Python tracker
<https://bugs.python.org/issue40
Change by Daniel :
--
keywords: +patch
pull_requests: +29873
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/31762
___
Python tracker
<https://bugs.python.org/issu
Change by Daniel :
--
components: Library (Lib)
nosy: Entirity
priority: normal
severity: normal
status: open
title: json dump/dumps prints each array element on a new line (bad for
readability)
type: enhancement
versions: Python 3.11
___
Python
New submission from Daniel Schulte :
When calling ArgumentParser.parse_args(list_of_things_to_parse) sys.exit gets
called even though the parser was constructed with exit_on_error=False. It
doesn't matter if the parser has any subparsers added or not.
The docs say
> Normally, when
Daniel Carpenter added the comment:
I'm not sure if this is an issue or by design, but this DeprecationWarning
behaves differently to other DeprecationWarnings.
A normal DeprecationWarning triggered by code in __main__ is printed by default:
$ python -c 'import warnings; warnings.
Change by Daniel Lenski :
--
keywords: +patch
pull_requests: +28748
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/30548
___
Python tracker
<https://bugs.python.org/issu
New submission from Daniel McCarney :
Hi there,
This is my first Python bug, hope I haven't missed anything important.
I noticed that the PyFunction_GetAnnotations function from the C API is
returning a PyTuple when I link Python 3.10 where historically it returned a
PyDict.
Daniel Lenski added the comment:
Due to this bug, any user of this function in Python 3.0+ *already* has to be
able to handle all of the following outputs in order to use it reliably:
decode_header(...) -> [(str, None)]
or decode_header(...) -> [(bytes, str)]
or decode_
Daniel Lenski added the comment:
I recently ran into this bug as well.
For those looking for a reliable workaround, here's an implementation of a
'decode_header_to_string' function which should Just Work™ in all possible
cases:
#!/usr/bin/python3
impo
Change by Daniel Diniz :
--
versions: +Python 3.11 -Python 3.4, Python 3.5, Python 3.6
___
Python tracker
<https://bugs.python.org/issue25044>
___
___
Python-bug
Change by Daniel Diniz :
--
versions: +Python 3.10, Python 3.11
___
Python tracker
<https://bugs.python.org/issue7687>
___
___
Python-bugs-list mailing list
Unsub
Daniel Diniz added the comment:
Now that a PR has landed in #28806 to improve shlex, we need to check whether
this issue can/needs to move forward.
--
nosy: +ajaksu2, asvetlov
type: -> behavior
versions: +Python 3.10, Python 3.11, Python 3.9 -Python
Change by Daniel Diniz :
--
keywords: -easy
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 3.3
___
Python tracker
<https://bugs.python.org/issue1438
Daniel Diniz added the comment:
Confirmed on Python 3.11.0a3+, assuming older versions also affected. This
issue has different versions of tests to confirm it, but I think not in a test
suite-friendly format yet.
There's also a patch and detailed analysis by gpolo indicating that it
Change by Daniel Diniz :
--
nosy: +belopolsky
___
Python tracker
<https://bugs.python.org/issue46169>
___
___
Python-bugs-list mailing list
Unsubscribe:
Daniel Diniz added the comment:
Confirmed for 3.11 in Windows.
The C datetime code can be trivially fixed so your equality test returns True,
but there are two Python tests that depend on current behavior so it might not
be so easy. They were added with current code in issue 24773, to
Change by Daniel Diniz :
--
nosy: +ajaksu2
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 2.7, Python 3.3, Python
3.4
___
Python tracker
<https://bugs.python.org/issue504
Daniel Diniz added the comment:
This example was added in issue 43047. It only seems to affect 3.10+ docs. Ian,
is this something you'd like to tackle?
--
keywords: +easy
nosy: +ajaksu2, iwienand
stage: -> needs patch
versions: +Python 3.10, Python 3.11 -Py
Daniel McDonald added the comment:
Sounds good, thank you, Terry
--
type: enhancement -> behavior
___
Python tracker
<https://bugs.python.org/issu
Daniel McDonald added the comment:
A definitive assessment was obtained by Aurelien with Debian:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1001774
In brief, the OverflowError is expected and correct.
Two factors contribute to the difference in observed behavior. First, the
New submission from Daniel Frey :
Hi
I found a strange behavior with lists. When I want to save the list {3,1,8}, it
saves the 8 at the first entry. Only when I add the integers 7 and 9, the 8 is
placed correctly. (See the attached picture)
Can anyone help me understand what is going on
Change by Daniel Diniz :
--
versions: +Python 3.10, Python 3.11 -Python 3.7, Python 3.8
___
Python tracker
<https://bugs.python.org/issue23224>
___
___
Python-bug
Daniel Diniz added the comment:
That happens because EncodingWarning isn't highlighted as an Exception by
Pygments[0]. The doc page gets its exceptions diagram by:
".. literalinclude:: ../../Lib/test/exception_hierarchy.txt"
and all other entries are recognized by Pygments, so
Change by daniel hahler :
--
versions: +Python 3.11
___
Python tracker
<https://bugs.python.org/issue41033>
___
___
Python-bugs-list mailing list
Unsubscribe:
daniel hahler added the comment:
Yes, the example also does not segfault for me either (also with Python 3.8.12
I have now as `python3.8`), so this was likely only happening in the more
complex setup, and/or maybe with some specific version of readline back then.
--
title
Change by Daniel Diniz :
--
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 2.7, Python 3.4, Python
3.5
___
Python tracker
<https://bugs.python.org/issue678
Change by Daniel Diniz :
--
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 2.7, Python 3.4, Python
3.5
___
Python tracker
<https://bugs.python.org/issue9
Change by Daniel Diniz :
--
versions: +Python 3.11 -Python 3.5
___
Python tracker
<https://bugs.python.org/issue1062277>
___
___
Python-bugs-list mailin
Daniel Diniz added the comment:
I have tried to add this. The PR adds:
- PrettyPrinter._pprint_dict_view to handle dict_keys and dict_values (sorted
with _safe_key).
= PrettyPrinter._pprint_dict_items_view to handle dict_items (sorted using
_safe_tuple).
- Tests.
Would a NEWS entry or other
Change by Daniel Diniz :
--
keywords: +patch
nosy: +ajaksu2
nosy_count: 4.0 -> 5.0
pull_requests: +28355
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/30135
___
Python tracker
<https://bugs.python.org/i
Daniel McDonald added the comment:
For reference, the bug reports with Debian and Ubuntu are at the following URLs:
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1001774
https://bugs.launchpad.net/ubuntu/+source/glibc/+bug/1954963
Daniel McDonald added the comment:
Thank you, Christian, I apologize for missing your reply. That is great advice,
and I will do so.
--
___
Python tracker
<https://bugs.python.org/issue44
Daniel McDonald added the comment:
The use of tm_isdst=1 appears to trigger the overflow, and occurs when varying
other aspects of the timetuple.
Python's mktime wrapper can throw OverflowError in two places. The thrown error
is the second location, following the call to glibc
Daniel McDonald added the comment:
Thank you, Terry. I'm currently exploring modifications to the test Andrei made
within a fork of CPython using Github Actions (ubuntu-latest). These
modifications include debug prints in the CPython mktime call, and some
parameter exploration. I expe
Daniel McDonald added the comment:
I'd like to politely request this issue be reopened.
We recently observed a similar, if not the same, OverflowError during
continuous integration using Github Actions on ubuntu-latest (20.04). We can
produce the error using pure Python without pytz
Change by Daniel Diniz :
--
nosy: +ajaksu2
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 2.7, Python 3.7
___
Python tracker
<https://bugs.python.org/issue766
Change by Daniel Diniz :
--
nosy: +iritkatriel
___
Python tracker
<https://bugs.python.org/issue1182143>
___
___
Python-bugs-list mailing list
Unsubscribe:
Daniel Diniz added the comment:
As Victor notes, this is a controversial issue. And I'll add that the need for
this feature seems not to have been brought up up in over a decade. So I'm
closing this.
--
resolution: -> rejected
stage: patch review -> resolved
status
New submission from Daniel :
The documentation
(https://docs.python.org/3/c-api/init.html#c.Py_NewInterpreter) states:
For modules using single-phase initialization, e.g. PyModule_Create(), the
first time a particular extension is imported, it is initialized normally, and
a (shallow) copy
Daniel Hillier added the comment:
Handling different character sets is not completely supported yet. There are a
couple of open issues relating to this: https://bugs.python.org/issue40407
(reading file names), https://bugs.python.org/issue41928 (support for reading
and writing filenames
New submission from Daniel :
Hello,
When embedding Python into a C application and not using Py_RunMain it is not
possible to remove a module added to PyImport_Inittab even if the interpreter
is finalized and a new is created.
One reason for not using Py_RunMain is to use python as a
Change by Daniel <3dan...@hotmail.com>:
--
type: -> enhancement
___
Python tracker
<https://bugs.python.org/issue45737>
___
___
Python-bugs-li
Change by Daniel <3dan...@hotmail.com>:
--
components: +Library (Lib)
versions: +Python 3.11
___
Python tracker
<https://bugs.python.org/issue45737>
___
___
New submission from Daniel <3dan...@hotmail.com>:
At the moment, assertLogs removes the handlers attached to the logger.
In general this is good, because it reduces message spamming in the test logs.
However, if the code being tested is relying on a handler to do something, then
the test
Daniel Lenski added the comment:
Why was this closed?
As I wrote in a previous comment, this situation can be automatically
identified and addressed via static analysis in the vastly-predominant case,
where the Exception object is assigned via an `exception ... as exc:` clause
Change by daniel hahler :
--
versions: +Python 3.10
___
Python tracker
<https://bugs.python.org/issue45249>
___
___
Python-bugs-list mailing list
Unsubscribe:
daniel hahler added the comment:
I've noticed a regression/change with the code change for this issue.
When not catching the exception from `compile("invalid(", "", "single")`
it has a caret below the opening parenthesis:
```
Traceback (most recent
Change by Daniel Fortunov :
--
nosy: +dfortunov
___
Python tracker
<https://bugs.python.org/issue45347>
___
___
Python-bugs-list mailing list
Unsubscribe:
Daniel Hillier added the comment:
I agree it is bad form but I would accidentally do it when I couldn't remember
the proper API and took a stab in the dark without looking up the docs. I
unfortunately used it in an example in the docs for pyzipper and started
getting a few bug reports
Daniel Hillier added the comment:
Thanks Łukasz!
--
___
Python tracker
<https://bugs.python.org/issue39359>
___
___
Python-bugs-list mailing list
Unsubscribe:
daniel capelle added the comment:
An ASCII representation is shown instead of the hexadecimal value, if there is
any.
I was not aware this is an intended behaviour.
--
___
Python tracker
<https://bugs.python.org/issue45
daniel capelle added the comment:
for example check:
(6500).to_bytes(2, 'big')
result is:
b'\x19d'
but was expected to be:
b'\x19\x64'
since
ord('d') is 100 = 0x64 there seems to be hex and char representation mixed up.
--
__
New submission from daniel capelle :
for example check:
(6500).to_bytes(2, 'big')
result is:
b'\x19d'
but was expected to be:
b'\x1964'
since
ord('d') is 100 = 0x64 there seems to be hex and char representation mixed up.
--
messages: 401571
no
daniel hahler added the comment:
Given code like the following the try/except handling of Pdb (via `Cmd.onecmd`,
see https://github.com/python/cpython/pull/4666) will mess with
`sys.exc_info()`, which could be avoided:
```
try:
raise ValueError()
except Exception as exc:
e = exc
New submission from Daniel Pope :
The anext_awaitable object returned by anext(..., default) does not support
.send()/.throw(). It only supports __next__().
So we can pass messages from the suspending coroutine to the event loop but not
from the event loop to the suspending coroutine.
trio
Daniel Fleischman added the comment:
Hey Raymond,
> "Changing the dict implementation to a linked list would make your case
perform better but would make most users worse off."
Is there any standard benchmark? I would like to implement my idea, as I
think that it is very unlike
Daniel Fleischman added the comment:
Thank you for your reply. I didn't know that this was the expected behavior
(found it at https://wiki.python.org/moin/TimeComplexity):
"For these operations, the worst case n is the maximum size the container ever
achieved, rather than just t
Daniel Fleischman added the comment:
Thank you again, Dennis.
I would disagree with your conclusion for mainly 3 reasons:
1. The linked list proposal would increase the memory usage by 2 Py_ssize_t per
entry, plus another 2 for the whole dictionary. I don't think this is an
overwhe
Daniel Fleischman added the comment:
I think the idea of augmenting the struts to maintain a linked list of elements
together with periodically shrinking on removal would solve both time and space
issues, right?
Space will be always linear, and operations would still be constant amortized
Daniel Fleischman added the comment:
Please find attached a more complete example of the issue I am reporting.
tl;dr: I can make `sum(d.values())` run in O(maximum_size_in_d's_history)
instead of O(len(d)), even when len(d) == 1.
The linked list approach would work in terms of maki
Daniel Fleischman added the comment:
Thank you for your message!
I'm not particularly looking for an implementation, I was just surprised by
this behavior.
It can get even worse. Consider this example:
```
d = large_dict()
# remove all but one element of d, runs in quadratic ti
Daniel Fleischman added the comment:
The linked list solution is not as easy to implement as I expected, because of
insertions. :(
--
___
Python tracker
<https://bugs.python.org/issue44
New submission from Daniel Fleischman :
The following code takes quadratic time on the size of the dictionary passed,
regardless of the dictionary (explanation below):
```
def slow_dictionary(d):
while len(d) > 0:
# Remove first element
key = next(iter(d))
de
Daniel Lenski added the comment:
> There is no way to know through static analysis that the subscript is on an
> object of type exception. I think this should be closed as won't fix.
In almost all cases, the variable in question will receive its value via
`except ... as e
New submission from Daniel Andersson :
Dear maintainers,
I discovered an unexpected behavior when the `side_effect` of an `AsyncMock`
includes an exception. The test case below fails but I expected it to pass:
```
import sys
import unittest
from unittest.mock import AsyncMock
class A
Ricardo Daniel Fuentes added the comment:
Hi Steve,
I am attaching the latest log files I see on temp.
This is the first version of python I have installed on this server, we do
install and uninstall SW on this machine all the time. As we run the
operations and need to update sw there often
Daniel Hillier added the comment:
Looking into this more and it appears that while Appendix D of
https://pkware.cachefly.net/webdocs/casestudies/APPNOTE.TXT says "If general
purpose bit 11 is unset, the file name and comment SHOULD conform to the
original ZIP character encoding"
Change by Ricardo Daniel Fuentes :
--
type: -> behavior
___
Python tracker
<https://bugs.python.org/issue44238>
___
___
Python-bugs-list mailing list
Un
New submission from Ricardo Daniel Fuentes :
Hi,
I am Admin of a Windows Server 2012 R2, I have installed successfully Python
3.9.5 (64-bit) however I cannot uninstall it, I get the error: "0x80070659 -
The installation is forbidden by system policy. Contact your system
administrato
Daniel Hillier added the comment:
zipfile decodes filenames using cp437 or unicode and encodes using ascii or
unicode. It seems like zipfile has a preference for writing filenames in
unicode rather than cp437. Is zipfile's preference for writing filenames in
unicode rather than
Daniel Urban added the comment:
@habnabit I believe I've already signed some contributor form some years ago.
If there is a new one, I can sign that one too.
--
___
Python tracker
<https://bugs.python.org/is
Change by Daniel Hillier :
--
keywords: +patch
pull_requests: +24763
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/26118
___
Python tracker
<https://bugs.python.org/issu
New submission from Daniel Hillier :
In the zipfile module, masking of bit flags is done against hex numbers eg. if
flags & 0x800...
To increase readability I suggest we replace these with global variables named
for the purpose of the flag. From the example above:
if flags & 0x800
Change by Daniel Hillier :
--
keywords: +patch
pull_requests: +24761
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/26116
___
Python tracker
<https://bugs.python.org/issu
New submission from Daniel Hillier :
Integrating a refactor suggested in https://bugs.python.org/issue38334
The logic for preparing a ZipExtFile for reading (setting CRC state, read
positions, etc) is currently in two locations: first initialisation and when
seeking back to the start of a
Daniel Watkins added the comment:
(Accidentally dropped Ned from nosy list; apologies!)
--
nosy: +ned.deily
___
Python tracker
<https://bugs.python.org/issue43
Daniel Watkins added the comment:
Hey folks,
Thanks for all the work on this: I really appreciate the efforts to keep Python
as secure as possible!
This change _is_ causing us problems in the cloud-init codebase, which
thankfully have been caught by our testing in Ubuntu's develo
Change by daniel hahler :
--
versions: -Python 3.9
___
Python tracker
<https://bugs.python.org/issue43798>
___
___
Python-bugs-list mailing list
Unsubscribe:
daniel hahler added the comment:
@Pablo: the problem (referenced in the pytest issue) is that `ast.alias` has
new required arguments now (see also the adjusted test in
https://github.com/python/cpython/commit/75a06f067bd0a2687312e5f8e78f9075be76ad3a#diff
Change by Daniel Torres :
--
title: Descriptor Documentation - Reference to Py_MethodType is not up to date
-> Descriptor.rst - Reference to Py_MethodType is not up to date
___
Python tracker
<https://bugs.python.org/issu
Change by Daniel Torres :
--
title: Documentation -> Descriptor Documentation - Reference to Py_MethodType
is not up to date
___
Python tracker
<https://bugs.python.org/issu
New submission from Daniel Torres :
https://github.com/python/cpython/blob/master/Doc/howto/descriptor.rst
Section 'Functions and methods'
The provided example contains comment 'Emulate Py_MethodType in
Objects/classobject.c'
But Py_MethodType is nowhere to be
Change by Daniel Moisset :
--
pull_requests: +23450
pull_request: https://github.com/python/cpython/pull/24664
___
Python tracker
<https://bugs.python.org/issue42
DANIEL VILLENEUVE added the comment:
I'll let you do so if it's ok for you, since I'm not equipped with Python dev
tools.
Regards
--
___
Python tracker
<https://bugs.pyt
Daniel Moisset added the comment:
Thanks @xtreak, I'll make some changes in these sections too.
The docs are coming along well, there's still some refinement to do in the
compound statements section (it's there, but looks to big), I'll submit a draft
PR during the w
New submission from DANIEL VILLENEUVE :
gcc 4.4.7 does not accept #pragma's inside functions.
I made the following patch, inspired by code found in other Python source files.
diff -r U/Python-3.9.2/Modules/_ctypes/callbacks.c
V/Python-3.9.2/Modules/_ctypes/callbacks.c
433c433
< #if
Daniel Moisset added the comment:
Note: I will NOT write something for "What's New in 3.10" seeing that's in
progress
--
___
Python tracker
<https://bug
Daniel Moisset added the comment:
Fyi, I'm looking into the documentation. I think I can have something basic for
the middle of this week, so it should be ok for March 1st.
--
___
Python tracker
<https://bugs.python.org/is
Daniel Engel added the comment:
It reproduced on a windows machine
--
___
Python tracker
<https://bugs.python.org/issue43253>
___
___
Python-bugs-list mailin
New submission from Daniel Engel :
Python 3.9.0 (tags/v3.9.0:9cf6752, Oct 5 2020, 15:34:40) [MSC v.1927 64 bit
(AMD64)]
Type 'copyright', 'credits' or 'license' for more information
IPython 7.18.1 -- An enhanced Interactive Python. Type '?' for hel
Daniel Moisset added the comment:
@Ken: I've invited you to the repo. For tracking the WIP,
https://github.com/dmoisset/cpython/tree/patma-docs
Do you want to see if you can base the reference/compound_stmts.rst changes in
PEP 634? I'll try to fit a variant of the Appendix A of PE
Daniel Moisset added the comment:
Hey Ken, I was about to take on this myself, but I wouldn't mind a bit of help.
Your list seems ok, I would add to it a section about PM in the python tutorial
(which was explicitly mentioned in the SC acceptance notice).
Regarding the grammar, I be
New submission from Daniel Colascione :
The ensurepip module in the Python distribution bootstraps the pip package
manager. The Python build system runs this module during installation so that
the resulting Python installation is ready to install packages. Right now, the
pip command that
Daniel Romberg added the comment:
Sorry, I meant an exception. I changed the type to "behavior", thanks for the
hint.
--
type: crash -> behavior
___
Python tracker
<https://bugs.pytho
New submission from Daniel Romberg :
The copy operation is not safe to use during iteration. The following test case
raises a "RuntimeError: dictionary changed size during iteration":
import weakref
class Class:
pass
def TEST_weakValue():
d = weakref.WeakValueDictionary()
Daniel Romberg added the comment:
I think this issue needs to be reopened. The problem has not been solved
completely. We experience a lot fewer crashes in weakref than before this fix,
however, there are recursive situations in which copy() is invoked while
iterating the
Daniel Lenski added the comment:
Like many others here, I've run into this issue because I'm trying to parse
timestamps from JSON.
(Specifically, I'm trying to parse timestamps from JSON serialization of Java
POJOs and/or Kotlin data classes, as serialized by the Jackso
Change by Daniel Lenski :
--
nosy: +dlenski
___
Python tracker
<https://bugs.python.org/issue35829>
___
___
Python-bugs-list mailing list
Unsubscribe:
Daniel Grunwald added the comment:
Fix idea: get_spawning_popen().pid could be used to directly copy the handle
into the child process, thus avoiding the temporary copy in the main process.
This would help at least in our case (where we pass all connections during
startup).
I don't kn
1 - 100 of 3335 matches
Mail list logo