[issue31772] SourceLoader uses stale bytecode in case of equal mtime seconds

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

No, sorry it wasn't merged. Should it be?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32696] Fix pickling exceptions with multiple arguments

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

This is still the same in 3.11:

>>> import pickle
>>> class CustomException(Exception):
... def __init__(self, arg1, arg2):
... msg = "Custom message {} {}".format(arg1, arg2)
... super().__init__(msg)
...
>>> obj_dump = pickle.dumps(CustomException("arg1", "arg2"))
>>> obj = pickle.loads(obj_dump)
Traceback (most recent call last):
  File "", line 1, in 
TypeError: CustomException.__init__() missing 1 required positional argument: 
'arg2'
>>>

--
nosy: +iritkatriel
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32465] [urllib] proxy_bypass_registry - extra error handling required for ProxyOverride, Windows under proxy environment

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

There are currently no unit tests for proxy_bypass_registry, proxy_bypass, and 
nothing much for proxy_open. Those should be added as part of this work.

--
keywords: +easy
nosy: +iritkatriel
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20803] doc: clarify that struct.pack_into writes 0x00 for pad bytes

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
assignee:  -> docs@python
components: +Documentation -Interpreter Core
keywords: +easy
nosy: +docs@python
title: struct.pack_into writes 0x00 for pad bytes -> doc: clarify that 
struct.pack_into writes 0x00 for pad bytes
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44032] Function locals and evaluation stack should be stored in a contiguous, per-thread stack

2021-06-18 Thread Mark Shannon


Mark Shannon  added the comment:


New changeset 0982ded179f280176868c1c4eccf77bf70687816 by Mark Shannon in 
branch 'main':
bpo-44032: Move pointer to code object from frame-object to frame specials 
array. (GH-26771)
https://github.com/python/cpython/commit/0982ded179f280176868c1c4eccf77bf70687816


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue15066] make install error: ImportError: No module named _struct

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Lib/site.py has changed a lot in the meantime compared to the patch that 
Antonio mentioned.

Unless you are currently seeing this issue with 3.9+ I suggest we close this 
and let a new issue be opened if someone does see this problem on a current 
version.

--
nosy: +iritkatriel
resolution:  -> out of date
status: open -> pending

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue17246] inspect.getargvalues fails if arg name is not bound to a value

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Still the same in 3.11:

>>> import inspect
>>> def fun(x):
... del x
... return inspect.currentframe()
...
>>> inspect.formatargvalues(*inspect.getargvalues(fun(10)))
Traceback (most recent call last):
  File "", line 1, in 
  File "C:\Users\User\src\cpython-dev\lib\inspect.py", line 1444, in 
formatargvalues
specs.append(convert(args[i]))
  File "C:\Users\User\src\cpython-dev\lib\inspect.py", line 1441, in convert
return formatarg(name) + formatvalue(locals[name])
KeyError: 'x'
>>>

--
nosy: +iritkatriel
title: cgitb fails when frame arguments are deleted (due to inspect bug I 
think) -> inspect.getargvalues fails if arg name is not bound to a value
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32696] Fix pickling exceptions with multiple arguments

2021-06-18 Thread Henk-Jaap Wagenaar


Henk-Jaap Wagenaar  added the comment:

It seems like the example in the OP now works (persist both arguments), but 
Irit's/Kirill's (create a msg) fails (I am running 3.9).

--
nosy: +cryvate

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19214] shutil.make_archive should recognize extensions in filenames

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

I agree with William that it is better to do this in a helper function than to 
further complicate make_archive.

--
nosy: +iritkatriel
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44449] Segfault in _PyTrash_begin when faulthandler tries to dump thread stacks

2021-06-18 Thread Duncan Grisby


New submission from Duncan Grisby :

I am using Python 3.9.4 on CentOS 7. faulthandler is registered with SIGUSR1:

faulthandler.register(signal.SIGUSR1)

Sending SIGUSR1 normally correctly dumps the thread stacks, but occasionally it 
segfaults from the main thread instead:

Thread 1 (Thread 0x7efe15e69740 (LWP 15201)):
#0  _PyTrash_begin (tstate=tstate@entry=0x0, op=op@entry=0x757ece0) at 
Objects/object.c:2125
#1  0x7efe156f05e5 in frame_dealloc (f=0x757ece0) at 
Objects/frameobject.c:578
#2  0x7efe15898f88 in _Py_DECREF (op=0x757ece0) at Include/object.h:430
#3  dump_traceback (write_header=0, tstate=0x757e1a0, fd=2) at 
Python/traceback.c:821
#4  _Py_DumpTracebackThreads (fd=fd@entry=2, interp=, 
interp@entry=0x0, current_tstate=0xbe6a70) at Python/traceback.c:921
#5  0x7efe1590be7d in faulthandler_dump_traceback (interp=, 
all_threads=1, fd=2) at Modules/faulthandler.c:243
#6  faulthandler_user (signum=10) at Modules/faulthandler.c:839
#7  
#8  0x7efe15243d2f in do_futex_wait () from /lib64/libpthread.so.0
#9  0x7efe15243e07 in __new_sem_wait_slow () from /lib64/libpthread.so.0
#10 0x7efe15243ea5 in sem_timedwait () from /lib64/libpthread.so.0
#11 0x7efe15896d11 in PyThread_acquire_lock_timed 
(lock=lock@entry=0x7ea7080, microseconds=microseconds@entry=500, 
intr_flag=intr_flag@entry=1) at Python/thread_pthread.h
:457
#12 0x7efe158f35a4 in acquire_timed (timeout=50, lock=0x7ea7080) at 
Modules/_threadmodule.c:63
#13 lock_PyThread_acquire_lock (self=0x7efdf4518750, args=, 
kwds=) at Modules/_threadmodule.c:146
#14 0x7efe15749916 in method_vectorcall_VARARGS_KEYWORDS 
(func=0x7efe15e1b310, args=0x186d208, nargsf=, 
kwnames=) at Objects/descrobject.c:346
...


It has failed because tstate is null. tstate came from 
Py_TRASHCAN_BEGIN_CONDITION that calls PyThreadState_GET(), assuming it returns 
a valid pointer, but the comment on the _PyThreadState_GET macro says:

   Efficient macro reading directly the 'gilstate.tstate_current' atomic
   variable. The macro is unsafe: it does not check for error and it can
   return NULL.

The only place I can see that tstate_current would be set to NULL is in 
_PyThreadState_DeleteCurrent(). I suspect that there has been a race with a 
thread exit.

I'm not sure quite what to do about this. Perhaps faulthandler should check if 
tstate_current is NULL and set it suitably if so?

--
components: Library (Lib)
messages: 396042
nosy: dgrisby
priority: normal
severity: normal
status: open
title: Segfault in _PyTrash_begin when faulthandler tries to dump thread stacks
type: crash
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue9419] RUNSHARED needs LDFLAGS

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Closing as 2.7 is past EOL and distutils is deprecated. Please create a new 
issue, and include complete reproduction instructions, if you are seeing this 
problem on an up to date version (3.9+).

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19832] XML version is ignored

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Reproduced in 3.11:

>>> xml.sax.parseString(">> encoding='UTF-8'?>blah", xml.sax.ContentHandler())
>>>

--
nosy: +iritkatriel
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44448] Suggestion: change existing error message for invalid function name

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Unfortunately these are tokenizer errors and the tokenizer had no idea of 
what's a function, so introducing syntactic structure in the error is going to 
be quite error prone, as the tokenizer still sees whitespace and other stuff 
that the parser doesn't.

--
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44448] Suggestion: change existing error message for invalid function name

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

But thanks a lot for the proposal!

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue7464] circular reference in HTTPResponse by urllib2

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

> It doesn't appear to be an issue in py3k.

I agree, I can't find this code anywhere. Closing.

--
nosy: +iritkatriel
resolution:  -> out of date
stage: test needed -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19832] XML version is ignored

2021-06-18 Thread Stefan Behnel


Stefan Behnel  added the comment:

After reading up a bit, version "X" should probably be rejected, whereas 
"1.[0-9]+" is meant to be allowed also by a 1.0 parser, according to the spec:

https://www.w3.org/TR/REC-xml/#sec-prolog-dtd

"""
When an XML 1.0 processor encounters a document that specifies a 1.x version 
number other than '1.0', it will process it as a 1.0 document. This means that 
an XML 1.0 processor will accept 1.x documents provided they do not use any 
non-1.0 features.
"""

However, this is not so much an issue with the SAX framework but with the 
underlying parser, which would be expat. Not sure why that doesn't care about 
the version.

Personally, I don't really care. There are only two XML versions, 1.0 and 1.1, 
and an XML 1.x parser is supposed to deal with both of them nicely. Anyone who 
writes something different in their XML version probably does so deliberately 
and wrongly. As long as the rest is XML, I don't see a reason to reject such an 
input document.

I'll close this as "won't fix", since there is no practical effect, it would 
need effort, and it doesn't look like anyone cared in almost 8 years.

--
resolution:  -> wont fix
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue25946] configure should pick /usr/bin/g++ automatically if present

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Closing as 2.7 is past EOL and distutils is deprecated. Please create a new 
issue if you have a current problem with this.

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44450] Generator expressions trace differently on Windows than on Mac

2021-06-18 Thread Ned Batchelder


New submission from Ned Batchelder :

Here is a trace involving generator expressions.  Using 3.10.0b3 on Mac, there 
are "line" events within the expression.  Those events are missing on Windows.

--- 8< ---
import linecache, sys

def trace(frame, event, arg):
# The weird globals here is to avoid a NameError on shutdown...
if frame.f_code.co_filename == globals().get("__file__"):
lineno = frame.f_lineno
print("{} {}: {}".format(event[:4], lineno, linecache.getline(__file__, 
lineno).rstrip()))
return trace

def doit():
o = ((1,2), (3,4))
o = (a for a in o)
for tup in o:
x = tup[0]
y = tup[1]

print(sys.version)
sys.settrace(trace)
doit()
---

When run on Mac, it produces this output:


3.10.0b3 (default, Jun 18 2021, 06:43:38) [Clang 12.0.0 (clang-1200.0.32.29)]
call 10: def doit():
line 11: o = ((1,2), (3,4))
line 12: o = (a for a in o)
line 13: for tup in o:
call 12: o = (a for a in o)
line 12: o = (a for a in o)
retu 12: o = (a for a in o)
line 14: x = tup[0]
line 15: y = tup[1]
line 13: for tup in o:
call 12: o = (a for a in o)
line 12: o = (a for a in o)
retu 12: o = (a for a in o)
line 14: x = tup[0]
line 15: y = tup[1]
line 13: for tup in o:
call 12: o = (a for a in o)
retu 12: o = (a for a in o)
retu 13: for tup in o:


When run on Windows, it produces this output:

3.10.0b3 (tags/v3.10.0b3:865714a, Jun 17 2021, 20:39:25) [MSC v.1929 64 bit 
(AMD64)]
call 10: def doit():
line 11: o = ((1,2), (3,4))
line 12: o = (a for a in o)
line 13: for tup in o:
call 12: o = (a for a in o)
retu 12: o = (a for a in o)
line 14: x = tup[0]
line 15: y = tup[1]
line 13: for tup in o:
call 12: o = (a for a in o)
retu 12: o = (a for a in o)
line 14: x = tup[0]
line 15: y = tup[1]
line 13: for tup in o:
call 12: o = (a for a in o)
retu 12: o = (a for a in o)
retu 13: for tup in o:

On Windows, the "line 12" events are missing.

--
components: Interpreter Core
keywords: 3.10regression
messages: 396050
nosy: Mark.Shannon, nedbat
priority: normal
severity: normal
status: open
title: Generator expressions trace differently on Windows than on Mac
versions: Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44426] Docs fail to build with Sphinx 4 due to Invalid C declaration

2021-06-18 Thread Mark Dickinson


Change by Mark Dickinson :


--
assignee: docs@python -> mark.dickinson

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

New submission from Miro Hrončok :

Hello.

When we attempted to upgrade to Python 3.10.0b3 on Fedora 33 and 34, we see the 
following test failure:



==
ERROR: test_entry_points_by_index 
(test.test_importlib.test_metadata_api.APITests)
Prior versions of Distribution.entry_points would return a
--
Traceback (most recent call last):
  File 
"/builddir/build/BUILD/Python-3.10.0b3/Lib/test/test_importlib/test_metadata_api.py",
 line 145, in test_entry_points_by_index
expected = next(iter(caught))
StopIteration
--
Ran 1402 tests in 2.125s
FAILED (errors=1, skipped=18, expected failures=1)


I've reproduced it without any Fedora's patches:

$ cd cpython
$ git switch -d v3.10.0b3  # or the tip of 3.10 today, 77eaf14d27

$ ./configure --enable-shared && make

$ LD_LIBRARY_PATH=. ./python -m test test_importlib
0:00:00 load avg: 13.59 Run tests sequentially
0:00:00 load avg: 13.59 [1/1] test_importlib
test test_importlib failed -- Traceback (most recent call last):
  File 
"/home/churchyard/Dokumenty/RedHat/cpython/Lib/test/test_importlib/test_metadata_api.py",
 line 145, in test_entry_points_by_index
expected = next(iter(caught))
StopIteration

test_importlib failed

== Tests result: FAILURE ==

1 test failed:
test_importlib

Total duration: 11.0 sec
Tests result: FAILURE

--
components: Library (Lib)
messages: 396051
nosy: hroncok, jaraco
priority: normal
severity: normal
status: open
title: test_entry_points_by_index 
(test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34
type: behavior
versions: Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40928] OS X: malloc(): set default diagnostics to DEBUG_WRITE_ON_CRASH

2021-06-18 Thread Jack DeVries


Change by Jack DeVries :


--
keywords: +patch
nosy: +jack__d
nosy_count: 4.0 -> 5.0
pull_requests: +25368
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26783

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

Also reproduced on the main branch.

--
versions: +Python 3.11

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40928] OS X: malloc(): set default diagnostics to DEBUG_WRITE_ON_CRASH

2021-06-18 Thread Jack DeVries


Jack DeVries  added the comment:

>From my pr, "This is a bandaid to help people save time debugging this 
>non-bug. I don't think this solution is very strong; I'm just hoping to move 
>the discussion forward on the bpo, and hoping for a hint on how to suppress 
>these warnings all together or come up with some other optimal solution.

I applied the function in test_decimal because that test consistently generates 
these malloc warnings on my system."

I'm still trying to find a true solution. Can anyone help to point me in a 
better direction?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

This seems to have been reported also at 
https://bugs.python.org/issue44246#msg395202

--
nosy: +xtreak

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

Also reproducible without --enable-shared.

[cpython (main)]$ ./configure && make
[cpython (main)]$ ./python --version
Python 3.11.0a0

[cpython (main)]$ ./python -m test test_importlib
0:00:00 load avg: 5.40 Run tests sequentially
0:00:00 load avg: 5.40 [1/1] test_importlib
test test_importlib failed -- Traceback (most recent call last):
  File 
"/home/churchyard/Dokumenty/RedHat/cpython/Lib/test/test_importlib/test_metadata_api.py",
 line 145, in test_entry_points_by_index
expected = next(iter(caught))
StopIteration

test_importlib failed

== Tests result: FAILURE ==

1 test failed:
test_importlib

Total duration: 3.5 sec
Tests result: FAILURE

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44246] 3.10 beta 1: breaking change in importlib.metadata entry points

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

The test_entry_points_by_index test also fails on Fedora. See issue44451.

--
nosy: +hroncok

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

I get the DeprecationWarning the tests assumes when not running via the test:

$ cat distinfo_pkg-1.0.0.dist-info/entry_points.txt 
[entries]
main = mod:main
ns:sub = mod:main

$ ./python
Python 3.11.0a0 (heads/main:0982ded179, Jun 18 2021, 14:14:16) [GCC 10.3.1 
20210422 (Red Hat 10.3.1-1)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import os, sys
>>> sys.path.insert(0, os.path.abspath('.'))
>>> from importlib.metadata import distribution
>>> distribution('distinfo-pkg')

>>> eps = distribution('distinfo-pkg').entry_points
>>> eps[0]
:1: DeprecationWarning: Accessing entry points by index is deprecated. 
Cast to tuple if needed.
EntryPoint(name='main', value='mod:main', group='entries')


Not sure why I don't get it in the test yet.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44452] Allow paths to be joined without worrying about a leading slash

2021-06-18 Thread Zbyszek Jędrzejewski-Szmek

New submission from Zbyszek Jędrzejewski-Szmek :

pathlib.Path.__truediv__(), i.e. pathlib.Path.joinpath() is surprising when the 
second argument starts with a slash.

>>> pathlib.Path('/foo') / '/bar'
>>> PosixPath('/bar')

I know that this follows the precedent set by os.path.join(), and
probably makes sense in some scenarios. But for the general operation
of "concatenating paths", it doesn't fit very well. In particular,
when concatenating multiple components this becomes even stranger:

>>> pathlib.Path('/var/tmp/instroot') / '/some/path' / '/suffix'
>>> PosixPath('/suffix')

In my particular use case, I'm concatenating some user specified paths
relative to some root. The paths may or may not be absolute.
 
To avoid this pitfall, something like this is necessary:

>>> pathlib.Path('/var/tmp/instroot') / p.lstrip('/') / q.lstrip('/')

Please provide a way to do this natively. I think it'd be nice to
use // or + for this:

>>> pathlib.Path('/var/tmp/instroot') // '/some/path' // '/suffix'
>>> PosixPath('/var/tmp/instroot/some/path/suffix')

--
components: Library (Lib)
messages: 396058
nosy: zbysz
priority: normal
severity: normal
status: open
title: Allow paths to be joined without worrying about a leading slash
type: behavior
versions: Python 3.11

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

I've added warnings.resetwarnings() to the test. it makes it pass.

It says:


Warning -- warnings.filters was modified by test_importlib
  Before: (140568295281984, [('default', None, , 
'__main__', 0), ('ignore', None, , None, 0), 
('ignore', None, , None, 0), ('ignore', 
None, , None, 0), ('ignore', None, , None, 0)], [('default', None, , 
'__main__', 0), ('ignore', None, , None, 0), 
('ignore', None, , None, 0), ('ignore', 
None, , None, 0), ('ignore', None, , None, 0)])
  After:  (140568295281984, [('default', None, , 
'__main__', 0), ('ignore', None, , None, 0), 
('ignore', None, , None, 0), ('ignore', 
None, , None, 0), ('ignore', None, , None, 0)], []) 
test_importlib failed (env changed)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

Adding the reset to the context manager:

with warnings.catch_warnings(record=True) as caught:
warnings.resetwarnings()
eps[0]

Or even better explicitly:

with warnings.catch_warnings(record=True) as caught:
warnings.filterwarnings("default", category=DeprecationWarning)
eps[0]

Makes it pass and makes the tests framework happy. I still don't understand why 
it is filtered, but other tests in the file (e.g. 
test_entry_points_dict_construction) already o this, so I will submit a pull 
request.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19402] AbstractBasicAuthHandler

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

I think Perry means HTTPBasicAuthHandler.http_error_401, which seems to still 
be missing a reset_retry_count() call.

https://github.com/python/cpython/blob/0982ded179f280176868c1c4eccf77bf70687816/Lib/urllib/request.py#L1050

--
nosy: +iritkatriel
versions: +Python 3.10, Python 3.11, Python 3.9 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Change by Miro Hrončok :


--
components: +Tests -Library (Lib)

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Change by Miro Hrončok :


--
keywords: +patch
pull_requests: +25369
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26784

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Jason R. Coombs

Jason R. Coombs  added the comment:

Other tests reset the filters? Good observation. I’d missed that detail. If 
it’s easier to submit a PR to importlib_metadata, feel free to do that as I’ll 
want the change in both places.

--
components: +Library (Lib) -Tests
stage: patch review -> 

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Miro Hrončok

Miro Hrončok  added the comment:

Submitted to both.

https://github.com/python/cpython/pull/26784
https://github.com/python/importlib_metadata/pull/325

--
components: +Tests -Library (Lib)

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26231] HTTPResponse.close() should consume all remaining data in body if any

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

> If close() does not consume the remaining data, the user would have to do it 
> after invoking close(), regardless of how large the data is.


Martin's point was that you can abandon the connection and create a new one if 
you choose not to consume all the data.

>  But how do do it, the HTTPResponse has been closed. 

Right, if you want to consume the data you should do it before calling close().

--
nosy: +iritkatriel
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44453] Documented return type of sysconfig.get_path() is wrong

2021-06-18 Thread Jelle Zijlstra


New submission from Jelle Zijlstra :

https://docs.python.org/3/library/sysconfig.html#sysconfig.get_path says it 
returns None if the name is not found, but the implementation 
(https://github.com/python/cpython/blame/main/Lib/sysconfig.py) uses [] and 
will raise KeyError instead.

Noticed by @srittau in https://github.com/python/typeshed/pull/5659. I will 
submit a PR.

--
assignee: Jelle Zijlstra
components: Documentation
messages: 396065
nosy: Jelle Zijlstra
priority: normal
severity: normal
status: open
title: Documented return type of sysconfig.get_path() is wrong
versions: Python 3.10, Python 3.11, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44453] Documented return type of sysconfig.get_path() is wrong

2021-06-18 Thread Jelle Zijlstra


Change by Jelle Zijlstra :


--
keywords: +patch
pull_requests: +25370
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26785

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40928] OS X: malloc(): set default diagnostics to DEBUG_WRITE_ON_CRASH

2021-06-18 Thread Jack DeVries


Change by Jack DeVries :


--
pull_requests: +25371
pull_request: https://github.com/python/cpython/pull/26786

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26236] urllib2 initiate irregular call to gethostbyaddr

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40928] OS X: malloc(): set default diagnostics to DEBUG_WRITE_ON_CRASH

2021-06-18 Thread Jack DeVries


Jack DeVries  added the comment:

Alternatively, my latest PR implements what @ronaldoussoren suggested: capping 
OS X memory allocations at 4TB.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27824] update ConfigParser docs regarding in-line comments

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

This is explained in the example now, just above
https://docs.python.org/3.10/library/configparser.html#interpolation-of-values


It was changed here:
https://github.com/python/cpython/commit/b25a791802a1915097e02bfba04e27a41ae55ebf

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue26608] RLock undocumented behavior in case of multiple acquire

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

The RLock documentation is a bit more verbose than it needs to be (for 
instance, there is no reason to specify the "no args" case separately from the 
"blocking=True" case (since True is the default value of blocking).

The issue of balancing acquire/release calls is mentioned as Josh says, but 
could perhaps be stated more simply as well.

--
keywords: +easy
nosy: +iritkatriel
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32536] ast and tokenize disagree about line number

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue32581] A bug of the write funtion of ConfigParser.py

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

I trued this on 3.11/Windows and 3.10/Linux and could not reproduce the issue. 
The Password remained "" in both cases.

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28412] os.path.splitdrive documentation out of date

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

This was updated in the Python 3 docs:
https://docs.python.org/3/library/os.path.html#os.path.splitdrive

The 2.7 docs are no longer maintained.

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34773] sqlite3 module inconsistently returning only some rows from a table

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

The python bug tracker is not the right place to ask for help debugging your 
application, it's for reporting bugs in python.

If you have evidence of an issue in python, please create a new issue with full 
reproduction instructions so that we can look into it.

--
nosy: +iritkatriel
resolution:  -> third party
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31398] TypeError: gdbm key must be string, not unicode

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

This seems like a python 2-only issue, if nobody objects I will close it in a 
couple of weeks.

--
nosy: +iritkatriel
resolution:  -> out of date
status: open -> pending

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27752] [doc] CSV DictReader default dialect name 'excel' is misleading, as MS Excel doesn't actually use ', ' as a separator.

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
assignee:  -> docs@python
components: +Documentation
nosy: +docs@python
title: CSV DictReader default dialect name 'excel' is misleading, as MS Excel 
doesn't actually use ',' as a separator. -> [doc] CSV DictReader default 
dialect name 'excel' is misleading, as MS Excel doesn't actually use ',' as a 
separator.
versions: +Python 3.11 -Python 2.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue28877] Cannot compile _ssl.o on HP-UX

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Python 2.7 is past EOL. Please create a new issue if you are still having this 
problem on 3.9+.

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31398] TypeError: gdbm key must be string, not unicode

2021-06-18 Thread STINNER Victor


STINNER Victor  added the comment:

IMO you can close it immediately. Fixing Python 2.7 is not going to happen ever.

--
status: pending -> open

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30563] [Cygwin] multiprocessing module with pool object issue

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
resolution:  -> third party
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31398] TypeError: gdbm key must be string, not unicode

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue33367] Multiprocessing Pool workers initiated with maxtasksperchild do not execute when sharing logging

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

Closing as this is a Python 2.7-only issue and 2.7 is no longer maintained.

--
nosy: +iritkatriel
resolution:  -> out of date
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34371] File reading gets stuck if you read at eof on macos

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
stage:  -> resolved
status: pending -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31743] Proportional Width Font on Generated Python Docs PDFs

2021-06-18 Thread Paul Du Bois


Paul Du Bois  added the comment:

For what it's worth, I also see proportional-width fonts when looking at the 
docs in Android Chrome. For example, the binary tree in 
https://docs.python.org/3/library/heapq.html is mangled.

--
nosy: +paul.dubois

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31743] Proportional Width Font on Generated Python Docs PDFs and in mobile browser

2021-06-18 Thread Paul Du Bois


Change by Paul Du Bois :


--
title: Proportional Width Font on Generated Python Docs PDFs -> Proportional 
Width Font on Generated Python Docs PDFs and in mobile browser

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44447] Syntax Error not as detailed as shown

2021-06-18 Thread Jelle Zijlstra


Change by Jelle Zijlstra :


--
components: +Parser -Regular Expressions
nosy: +lys.nikolaou, pablogsal
type: performance -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44454] How to find canon printer default wifi password

2021-06-18 Thread fix offline printers


New submission from fix offline printers :

You cannot use the Canon Printer for printing purpose until and unless you do 
not have Canon Printer Password. However, Canon Printer password 
troubleshooting can be done in short span of time by following technical steps. 
Therefore, Canon Printer Default Password setup steps mentioned below and if 
you cannot fix it yourself then feel free to ask for help through our chat 
window and get help from experts.
https://fixofflineprinters.com/how-to-find-canon-printer-default-wifi-password/

--
messages: 396077
nosy: fixofflineprinters
priority: normal
severity: normal
status: open
title: How to find canon printer default wifi password

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44454] Spam

2021-06-18 Thread Zachary Ware


Change by Zachary Ware :


--
nosy:  -fixofflineprinters
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed
title: How to find canon printer default wifi password -> Spam

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44454] Spam

2021-06-18 Thread Zachary Ware


Change by Zachary Ware :


--
Removed message: https://bugs.python.org/msg396077

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue35714] Document that the null character '\0' terminates a struct format spec

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

This seems resolved, can it be closed?

--
nosy: +iritkatriel

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue40412] [subinterpreters] inittab_copy not set to NULL after free, can lead to crashes when running multiple interpreters in a single process

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions:  -Python 3.5, Python 3.6, Python 3.7

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44447] Syntax Error not as detailed as shown

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Indeed, as Andre mentions your example is different because in you case the 
call is interpreted as a generator comprehension, not as a function call.

--
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31772] SourceLoader uses stale bytecode in case of equal mtime seconds

2021-06-18 Thread Brett Cannon


Brett Cannon  added the comment:

No idea, I was just trying to understand what the link was meant to point at. :)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44246] 3.10 beta 1: breaking change in importlib.metadata entry points

2021-06-18 Thread HEY GOOGLE


HEY GOOGLE  added the comment:

Addes aggreement

--
components: +Build
nosy: +hectorizdaone
type:  -> security

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue39947] [C API] Make the PyThreadState structure opaque (move it to the internal C API)

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
nosy: +iritkatriel
nosy_count: 4.0 -> 5.0
pull_requests: +25372
pull_request: https://github.com/python/cpython/pull/26788

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44310] Document that lru_cache uses hard references

2021-06-18 Thread Raymond Hettinger


Change by Raymond Hettinger :


--
pull_requests: +25373
pull_request: https://github.com/python/cpython/pull/26789

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Jason R. Coombs

Jason R. Coombs  added the comment:


New changeset df1502e47fc1e0cf1e7d460ae04530c3e2e4a7c6 by Miro Hrončok in 
branch 'main':
bpo-44451: Reset DeprecationWarning filters in 
test_importlib.test_entry_points_by_index (GH-26784)
https://github.com/python/cpython/commit/df1502e47fc1e0cf1e7d460ae04530c3e2e4a7c6


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 3.0 -> 4.0
pull_requests: +25374
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26790

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43945] [Enum] standardize format() behavior

2021-06-18 Thread Ethan Furman


Ethan Furman  added the comment:


New changeset f60b07ab6c943fce084772c3c7731ab3bbd213ff by Ethan Furman in 
branch 'main':
bpo-43945: [Enum] reduce scope of new format() behavior (GH-26752)
https://github.com/python/cpython/commit/f60b07ab6c943fce084772c3c7731ab3bbd213ff


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43945] [Enum] standardize format() behavior

2021-06-18 Thread Ethan Furman


Change by Ethan Furman :


--
pull_requests: +25375
pull_request: https://github.com/python/cpython/pull/26791

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread Jason R. Coombs


Jason R. Coombs  added the comment:

Big thanks Miro for the detailed work on this matter.

--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44451] test_entry_points_by_index (test.test_importlib.test_metadata_api.APITests) fails on Fedora 33 and 34

2021-06-18 Thread miss-islington


miss-islington  added the comment:


New changeset bf55a799e0c19285b094d71f794c301c1afaa28d by Miss Islington (bot) 
in branch '3.10':
bpo-44451: Reset DeprecationWarning filters in 
test_importlib.test_entry_points_by_index (GH-26784)
https://github.com/python/cpython/commit/bf55a799e0c19285b094d71f794c301c1afaa28d


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44368] Invalid mapping patterns give confusing SyntaxErrors

2021-06-18 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
pull_requests: +25376
pull_request: https://github.com/python/cpython/pull/26792

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue31772] SourceLoader uses stale bytecode in case of equal mtime seconds

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

The discussion is leading to yes, but the patch needs some more work on the 
test.

(The link was pointing at me being past my bedtime when I pasted it :-)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44455] compileall should exit nonzero for nonexistent directories

2021-06-18 Thread Aaron Meurer


New submission from Aaron Meurer :

$ ./python.exe -m compileall doesntexist
Listing 'doesntexist'...
Can't list 'doesntexist'
$ echo $?
0

It's standard for a command line tool that processes files to exit nonzero when 
given a directory that doesn't exist.

--
messages: 396087
nosy: asmeurer
priority: normal
severity: normal
status: open
title: compileall should exit nonzero for nonexistent directories

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue18182] xml.dom.createElement() does not take implicit namespaces into account

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44456] Improve syntax error for mixing keyword/positional in max patterns

2021-06-18 Thread Pablo Galindo Salgado


New submission from Pablo Galindo Salgado :

This got me confused for a sec when doing some live demo:

>>> match x:
...case A(y=1, foo):
  File "", line 2
case A(y=1, foo):
   ^
SyntaxError: invalid syntax

I propose to improve this to:

>>> match x:
...case A(y=1, foo):
  File "", line 2
case A(y=1, foo):
^^^
SyntaxError: cannot mix keyword patterns and positional patterns

--
messages: 396088
nosy: brandtbucher, pablogsal
priority: normal
severity: normal
status: open
title: Improve syntax error for mixing keyword/positional in max patterns

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44456] Improve syntax error for mixing keyword/positional in max patterns

2021-06-18 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
keywords: +patch
pull_requests: +25377
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26793

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue20513] Python 2.7. Script interruption on logoff from 0 session under Win2003 and earlier

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

The patch doesn't look anything like the current code. Is this issue still 
relevant?

--
nosy: +iritkatriel

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44456] Improve syntax error for mixing keyword/positional in max patterns

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Btw, I noticed this is allowed:

>>> match x:
...case A(foo, t=3):
......
...

but this is not:

>>> match x:
...case A(foo=3, t):

Is that on pourpose?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44456] Improve syntax error for mixing keyword/positional in max patterns

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

If this is supposed to mirror function calls, maybe the error should be::

>>> match a:
...case A(foo=3, t):
  File "", line 2
case A(foo=3, t):
  ^
SyntaxError: positional patterns follow keyword patterns

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44368] Invalid mapping patterns give confusing SyntaxErrors

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset a8c418d5ed1103106db547aa576b82c6031985a4 by Pablo Galindo in 
branch '3.10':
[3.10] bpo-44368: Improve syntax errors with invalid as pattern targets 
(GH-26632) (GH-26792)
https://github.com/python/cpython/commit/a8c418d5ed1103106db547aa576b82c6031985a4


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43329] Multiprocessing Manager Client Not Reconnecting

2021-06-18 Thread Ethan Furman


Ethan Furman  added the comment:

Michael Boon wrote:
---
> The [above] issue is pretty serious and it is preventing me from using a
> system I wrote on a larger scale.

That statement suggests you were able to get this working on a small scale -- 
is that correct?  What does the working small-scale code look like?

--
nosy: +ethan.furman

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43329] Multiprocessing Manager Client Not Reconnecting

2021-06-18 Thread Michael L. Boom


Michael L. Boom  added the comment:

I don't think I even got this working on the small scale.  The unit test in the 
bug report is about as small as it gets and it doesn't work.  The issue still 
exists in Python 3.9.5.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44404] tkinter's after() AttributeError with functools.partial (no attribute __name__)

2021-06-18 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

The docstring for .after says the 2nd argument must be a 'function'.  Whether 
this issue is a bugfix or enhancement request depends whether one interprets 
'function' as 'callable' or something narrower that only includes objects that 
necessarily have __name__ attributes.  The latter would exclude partials and 
instances of user classes with __call__ methods.

While a one-time-use partial as in the example is superfluous, I think other 
uses and parameterized callback classes should be supported.  So I agree with 
changing the tkinter code rather than qualifying 'function' with 'has a 
.__name__ attribute'.  I think 'type(func).__name__' should be safe.

--
nosy: +terry.reedy

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43945] [Enum] standardize format() behavior

2021-06-18 Thread Ethan Furman


Ethan Furman  added the comment:


New changeset 1b4addf3cbd0ef424939681ee67c802328d567ba by Ethan Furman in 
branch '3.10':
[3.10] bpo-43945: [Enum] reduce scope of new format() behavior (GH-26752) 
https://github.com/python/cpython/commit/1b4addf3cbd0ef424939681ee67c802328d567ba


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue6029] FAIL: test_longdouble (ctypes.test.test_callbacks.Callbacks) [SPARC/64-bit]

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

The patch doesn't look anything like the current code. Is this issue still 
relevant?

--
nosy: +iritkatriel

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43945] [Enum] standardize format() behavior

2021-06-18 Thread Ethan Furman


Change by Ethan Furman :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37832] Python requires /dev/urandom on HURD: _Py_HashRandomization_Init: failed to get random numbers

2021-06-18 Thread Irit Katriel


Change by Irit Katriel :


--
resolution:  -> third party
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44457] Finish format() change started in issue43945

2021-06-18 Thread Ethan Furman


New submission from Ethan Furman :

Finish the work started in issue43945 -- in 3.12 `format()` now uses the enum 
member itself instead of its `value`; e.g.:

>>> class Color(int, Enum):
... RED = 1

>>> f"{Color.RED}"
'RED'
>>> f"{Color.RED:d}"
'1'

--
assignee: ethan.furman
messages: 396098
nosy: ethan.furman
priority: normal
severity: normal
status: open
title: Finish format() change started in issue43945
type: behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44457] Finish format() change started in issue43945

2021-06-18 Thread Ethan Furman


Change by Ethan Furman :


--
status: open -> pending

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue30379] multiprocessing Array create for ctypes.c_char, TypeError unless 1 char string arg used

2021-06-18 Thread Irit Katriel


Irit Katriel  added the comment:

I'm assuming Davin's alternative solved your problem. If not, please check that 
you're still seeing it version 3.9+ and create a new issue.

--
nosy: +iritkatriel
resolution:  -> not a bug
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44456] Improve syntax error for mixing keyword/positional in max patterns

2021-06-18 Thread Brandt Bucher


Brandt Bucher  added the comment:

Yep, it's intentional.

And yep, I like the new error message better. :)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44446] linecache.getline TypeError when formatting tracebacks in stacks containing an async list comprehension

2021-06-18 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:

Mark, can you take a look at this?

--
nosy: +pablogsal
versions: +Python 3.11 -Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44446] linecache.getline TypeError when formatting tracebacks in stacks containing an async list comprehension

2021-06-18 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
priority: normal -> release blocker

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27752] [doc] CSV DictReader default dialect name 'excel' is misleading, as MS Excel doesn't actually use ', ' as a separator.

2021-06-18 Thread Jack DeVries


Change by Jack DeVries :


--
keywords: +patch
nosy: +jack__d
nosy_count: 3.0 -> 4.0
pull_requests: +25378
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/26795

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue44413] OverflowError: mktime argument out of range after 2019

2021-06-18 Thread Terry J. Reedy


Terry J. Reedy  added the comment:

An exception is not a 'crash', as defined for this tracker.  3.8 only gets 
security fixes.  A 3.9 or 3.10 test is needed and Windows does not have pytz.

--
nosy: +belopolsky, lemburg, p-ganssle, terry.reedy
type: crash -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27752] [doc] CSV DictReader default dialect name 'excel' is misleading, as MS Excel doesn't actually use ', ' as a separator.

2021-06-18 Thread Jack DeVries


Jack DeVries  added the comment:

If you need semicolon delimiters, can't you just pass ``delimiter=';'`` to the 
reader or writer? I don't think there's a need for a separate dialect class for 
that, since dialect classes should only provide a baseline for the most broad 
use cases. Users have plenty of options for extending or customizing behavior 
without adding more dialect classes.

I also think the docs around dialects are confusing. I remember being confused 
by them when I was learning! I made quite a few changes to try to add clarity 
around dialects to the documentation. Let me know if anybody has feedback!

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



  1   2   >