[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 9aeb0ef9309384099e2f23bcee2240fbc096568e by Dong-hee Na in branch 
'master':
 bpo-39573: Update clinic to use Py_IS_TYPE() function (GH-18507)
https://github.com/python/cpython/commit/9aeb0ef9309384099e2f23bcee2240fbc096568e


--

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset d212c3c55d414203b0579e000d9f340f8cd11be7 by Dong-hee Na in branch 
'master':
bpo-39573: PyXXX_Check() macros use Py_IS_TYPE() (GH-18508)
https://github.com/python/cpython/commit/d212c3c55d414203b0579e000d9f340f8cd11be7


--

___
Python tracker 

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



Re: ghostscripts in python with watchdog

2020-02-13 Thread Bheesham Persaud

Hey!

If you change the "-sOutputFile` parameter you pass into gswin64c.

For example, something like:

output_directory = os.path.join(os.path.dirname(input_src), "out")

And then you should be able to modify the call to `os.system` to 
something like:


os.system(
"gswin64c -q -dBATCH -dNOPAUSE"
"-sOutputFile={output_directory}/page{page:04d}.pdf"
" -dFirstPage={page} -dLastPage={page}"
" -sDEVICE=pdfwrite {input_pdf}"
.format(
page=i,
input_pdf=input_pdf,
output_directory=output_directory
)
)
--
https://mail.python.org/mailman/listinfo/python-list


Re: first time python learner

2020-02-13 Thread Cameron Simpson

On 13Feb2020 21:38, Marty Konopko  wrote:

Win 10
Anti Virus  off
[image: image.png]

Any idea?


Alas, this is a text only list; your screenshot has been discarded.  
Please reply with your complete error message cut/paste into the text.  
And a description of what you were trying to do.


Thanks,
Cameron Simpson 
--
https://mail.python.org/mailman/listinfo/python-list


first time python learner

2020-02-13 Thread Marty Konopko
Win 10
Anti Virus  off
[image: image.png]

Any idea?

-- 
Martin Konopko
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue39629] inspect.signature fails on math.hypot

2020-02-13 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

This isn't a bug.  It is a known limitation of the ArgumentClinic that it 
cannot currently describe functions with *args.   That and other limitations is 
also why we don't have signatures for min() max() range() etc.

--
nosy: +rhettinger
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



[issue39630] Const some pointers to string literals

2020-02-13 Thread Benjamin Peterson


Benjamin Peterson  added the comment:


New changeset 0d860dd43c72dc7046a5d18fc72d495cadd4a2df by Benjamin Peterson in 
branch '3.8':
[3.8] closes bpo-39630: Update pointers to string literals to be const char *. 
(GH-18511)
https://github.com/python/cpython/commit/0d860dd43c72dc7046a5d18fc72d495cadd4a2df


--

___
Python tracker 

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



[issue39630] Const some pointers to string literals

2020-02-13 Thread Benjamin Peterson


Change by Benjamin Peterson :


--
pull_requests: +17887
pull_request: https://github.com/python/cpython/pull/18511

___
Python tracker 

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



[issue39630] Const some pointers to string literals

2020-02-13 Thread Benjamin Peterson


Benjamin Peterson  added the comment:


New changeset 7386a70746cf9aaf2d95db75d9201fb124f085df by Andy Lester in branch 
'master':
closes bpo-39630: Update pointers to string literals to be const char *. 
(GH-18510)
https://github.com/python/cpython/commit/7386a70746cf9aaf2d95db75d9201fb124f085df


--
nosy: +benjamin.peterson
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



[issue39619] os.chroot is not enabled on HP-UX builds

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 28fc1bac0fbe1f4ae2e3dcba1dee38d2c063a539 by Miss Islington (bot) 
in branch '3.8':
closes bpo-39619 Fix os.chroot on HP-UX 11.31 (GH-18495)
https://github.com/python/cpython/commit/28fc1bac0fbe1f4ae2e3dcba1dee38d2c063a539


--
nosy: +miss-islington

___
Python tracker 

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



[issue39630] Const some pointers to string literals

2020-02-13 Thread Andy Lester


Change by Andy Lester :


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

___
Python tracker 

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



[issue39630] Const some pointers to string literals

2020-02-13 Thread Andy Lester


New submission from Andy Lester :

Here are some fixes of char * pointers to literals that should be const char * 
in these four files.

+++ Objects/frameobject.c
+++ Objects/genobject.c
+++ Python/codecs.c
+++ Python/errors.c

--
components: Interpreter Core
messages: 361982
nosy: petdance
priority: normal
severity: normal
status: open
title: Const some pointers to string literals
type: enhancement

___
Python tracker 

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



[issue39619] os.chroot is not enabled on HP-UX builds

2020-02-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17885
pull_request: https://github.com/python/cpython/pull/18509

___
Python tracker 

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



[issue39619] os.chroot is not enabled on HP-UX builds

2020-02-13 Thread Benjamin Peterson


Benjamin Peterson  added the comment:


New changeset a9edf44a2de9b23a1690b36cdfeed7b41ab763bd by Ian Norton in branch 
'master':
closes bpo-39619 Fix os.chroot on HP-UX 11.31 (GH-18495)
https://github.com/python/cpython/commit/a9edf44a2de9b23a1690b36cdfeed7b41ab763bd


--
nosy: +benjamin.peterson
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



[issue5537] LWPCookieJar cannot handle cookies with expirations of 2038 or greater on 32-bit platforms

2020-02-13 Thread Neil MacLeod


Neil MacLeod  added the comment:

Just an FYI, this is also broken on 32-bit with Python2.7.16, so possibly it 
was never fixed originally (rather than being a regression).

LibreELEC (Milhouse): devel-20191012235627-#1012-ge416c8b (RPi2.arm)
rpi22:~ # python -c "import sys, cookielib; print sys.version; print 
cookielib.time2isoz(2322923767)"
2.7.16 (default, Sep 29 2019, 04:11:31)
[GCC 9.2.0]
Traceback (most recent call last):
  File "", line 1, in 
  File "/usr/lib/python2.7/cookielib.py", line 99, in time2isoz
ValueError: timestamp out of range for platform time_t

--

___
Python tracker 

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



[issue39626] random choice to delegate to sample on sets

2020-02-13 Thread Raymond Hettinger


Raymond Hettinger  added the comment:

Thanks for the suggestion.  I think this is close to being a duplicate of 37708 
which was rejected.  For the most part, it was mistake that sample() accepted 
sets.  The implicit conversion has led to surprising performance issues.  If 
that API was being created from scratch, it would not support sets at and would 
require the user to explicitly convert to a sequence.  I do not wish to 
replicate this mistake with choices().

As for delegating to sample(), that doesn't make sense because choices() works 
with replacement and sample() works without replacement.  The two are 
semantically different.

--
assignee:  -> rhettinger
resolution:  -> duplicate
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



[issue5537] LWPCookieJar cannot handle cookies with expirations of 2038 or greater on 32-bit platforms

2020-02-13 Thread Neil MacLeod


Neil MacLeod  added the comment:

Hi Victor

I can confirm the patch is working on both 32-bit and 64-bit systems running 
Python3.7.6, with both platforms returning the same result after patching - 
many thanks!

 UNPATCHED, 32-bit (RPi3+)
LibreELEC (Milhouse.testing): devel-20200213234919-#0213f-g70b69eb (RPi2.arm)
rpi22:~ # python -c "import sys, http.cookiejar; print(sys.version); 
print(http.cookiejar.time2isoz(2322923767))"
3.7.6 (default, Feb 14 2020, 00:35:22)
[GCC 9.2.0]
Traceback (most recent call last):
  File "", line 1, in 
  File "/usr/lib/python3.7/cookiejar.py", line 101, in time2isoz
OverflowError: timestamp out of range for platform time_t

 PATCHED, 32-bit (RPi3+)
LibreELEC (Milhouse.testing): devel-20200214012134-#0213g-g70b69eb (RPi2.arm)
rpi22:~ # python -c "import sys, http.cookiejar; print(sys.version); 
print(http.cookiejar.time2isoz(2322923767))"
3.7.6 (default, Feb 14 2020, 01:22:50)
[GCC 9.2.0]
2043-08-11 16:36:07Z

 UNPATCHED, 64-bit (x86_64)
LibreELEC (Milhouse.next): devel-20200213053123-#0212x-g67aedc9 (Generic.x86_64)
NUC:~ # python -c "import sys, http.cookiejar; print(sys.version); 
print(http.cookiejar.time2isoz(2322923767))"
3.7.6 (default, Feb 12 2020, 20:54:03)
[GCC 9.2.0]
2043-08-11 16:36:07Z

 PATCHED, 64-bit (x86_64)
LibreELEC (Milhouse.next): devel-20200214005606-#0214-g70b69eb (Generic.x86_64)
NUC:~ # python -c "import sys, http.cookiejar; print(sys.version); 
print(http.cookiejar.time2isoz(2322923767))"
3.7.6 (default, Feb 14 2020, 01:00:37)
[GCC 9.2.0]
2043-08-11 16:36:07Z

--

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread Dong-hee Na


Change by Dong-hee Na :


--
pull_requests: +17884
pull_request: https://github.com/python/cpython/pull/18508

___
Python tracker 

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



[issue39511] [subinterpreters] Per-interpreter singletons (None, True, False, etc.)

2020-02-13 Thread hai shi


Change by hai shi :


--
nosy: +shihai1991

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread Dong-hee Na


Change by Dong-hee Na :


--
pull_requests: +17883
pull_request: https://github.com/python/cpython/pull/18507

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread hai shi


hai shi  added the comment:

> By the way, please find another more inclusive way to say hi, see:
https://heyguys.cc/

Oh, copy that. Sorry for my poor english.

--

___
Python tracker 

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



[issue39545] await is not supported in f-string in 3.6

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 581b8606ca0609cf36c4eb9a5bb025eb77540e5e by Miss Islington (bot) 
in branch '3.8':
bpo-39545: Document changes in the support of await in f-strings. (GH-18456)
https://github.com/python/cpython/commit/581b8606ca0609cf36c4eb9a5bb025eb77540e5e


--

___
Python tracker 

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



[issue39545] await is not supported in f-string in 3.6

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 46cf4fc8a5646ca35f7d1ac06d2ef33eb9efca1d by Miss Islington (bot) 
in branch '3.7':
bpo-39545: Document changes in the support of await in f-strings. (GH-18456)
https://github.com/python/cpython/commit/46cf4fc8a5646ca35f7d1ac06d2ef33eb9efca1d


--

___
Python tracker 

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



[issue39545] await is not supported in f-string in 3.6

2020-02-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17882
pull_request: https://github.com/python/cpython/pull/18506

___
Python tracker 

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



[issue39545] await is not supported in f-string in 3.6

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset f632736023502816f2e6bd714d1b48c81aa2ccc1 by Serhiy Storchaka in 
branch 'master':
bpo-39545: Document changes in the support of await in f-strings. (GH-18456)
https://github.com/python/cpython/commit/f632736023502816f2e6bd714d1b48c81aa2ccc1


--
nosy: +miss-islington

___
Python tracker 

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



[issue39545] await is not supported in f-string in 3.6

2020-02-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17881
pull_request: https://github.com/python/cpython/pull/18505

___
Python tracker 

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



[issue39545] await is not supported in f-string in 3.6

2020-02-13 Thread Ned Deily


Ned Deily  added the comment:


New changeset cebe9ee988837b292f2c571e194ed11e7cd4abbb by Serhiy Storchaka in 
branch '3.6':
bpo-39545: Document restrictions on "await" and "async for" in f-strings. 
(GH-18459)
https://github.com/python/cpython/commit/cebe9ee988837b292f2c571e194ed11e7cd4abbb


--

___
Python tracker 

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



[issue39411] pyclbr rewrite using AST

2020-02-13 Thread Brandt Bucher


Change by Brandt Bucher :


--
nosy: +brandtbucher

___
Python tracker 

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



[issue5537] LWPCookieJar cannot handle cookies with expirations of 2038 or greater on 32-bit platforms

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:

Oh, maybe the bug wasn't properly fixed?

Can you please try the patch above?

diff --git a/Lib/http/cookiejar.py b/Lib/http/cookiejar.py
index 47ed5c3d64..55915cf18a 100644
--- a/Lib/http/cookiejar.py
+++ b/Lib/http/cookiejar.py
@@ -99,7 +99,7 @@ def time2isoz(t=None):
 if t is None:
 dt = datetime.datetime.utcnow()
 else:
-dt = datetime.datetime.utcfromtimestamp(t)
+dt = datetime.datetime(1970, 1, 1) + datetime.timedelta(seconds=t)
 return "%04d-%02d-%02d %02d:%02d:%02dZ" % (
 dt.year, dt.month, dt.day, dt.hour, dt.minute, dt.second)
 

For example, copy http/ subdirectory in the current directory, and then patch 
manually http/cookiejar.py file.

--
resolution: fixed -> 
status: closed -> open

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:

> Hi, guys.

By the way, please find another more inclusive way to say hi, see:
https://heyguys.cc/

--

___
Python tracker 

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



[issue39624] Trace greedy replaces $prefix and $exec_prefix

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:

Would you mind to add examples of patterns should be replaced and patterns 
which should not be replaced?

--

___
Python tracker 

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



[issue39627] Fix TypedDict totality check for inherited keys

2020-02-13 Thread Guido van Rossum


Change by Guido van Rossum :


--
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



[issue39629] inspect.signature fails on math.hypot

2020-02-13 Thread Mark Dickinson


Change by Mark Dickinson :


--
nosy: +mark.dickinson

___
Python tracker 

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



[issue39627] Fix TypedDict totality check for inherited keys

2020-02-13 Thread Guido van Rossum


Guido van Rossum  added the comment:


New changeset 10e87e5ef4c1b4fb8415d9ddc362e2591f2f0b6c by Vlad Emelianov in 
branch 'master':
bpo-39627: Fix TypedDict totality check for inherited keys (#18503)
https://github.com/python/cpython/commit/10e87e5ef4c1b4fb8415d9ddc362e2591f2f0b6c


--
nosy: +gvanrossum

___
Python tracker 

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



[issue17050] argparse.REMAINDER doesn't work as first argument

2020-02-13 Thread dHannasch


dHannasch  added the comment:

I've attached a file that can be run, but it's a simple script that I can 
include here inline, too:


"""
Context:
I am trying to set up a cookiecutter so that newly-created packages will come 
with a Jupyter notebook users can play with.
That is, python -m package_name jupyter would open up a Jupyter quickstart 
notebook demonstrating the package's features.
argparse.REMAINDER as the first argument isn't important for a top-level 
parser, since we can work around it by not using argparse at all,
but using argparse.REMAINDER in a subparser seems like a pretty straightforward 
use case.
Any time we want to dispatch a subcommand to a separate tool --- forwarding all 
following arguments --- we're going to need it.
"""

import argparse

parser = argparse.ArgumentParser()
parser.add_argument('command', default='cmdname')
parser.add_argument('cmdname_args', nargs=argparse.REMAINDER)
args = parser.parse_args('cmdname --arg1 XX ZZ --foobar'.split())
if args != argparse.Namespace(cmdname_args=['--arg1', 'XX', 'ZZ', '--foobar'], 
command='cmdname'):
raise Exception(args)
print('This is how argparse.REMAINDER works when there is an argument in 
front.')

parser = argparse.ArgumentParser()
parser.add_argument('--foo')
parser.add_argument('command', default='cmdname')
parser.add_argument('cmdname_args', nargs=argparse.REMAINDER)
args = parser.parse_args('--foo B cmdname --arg1 XX ZZ --foobar'.split())
if args != argparse.Namespace(cmdname_args=['--arg1', 'XX', 'ZZ', '--foobar'], 
command='cmdname', foo='B'):
raise Exception(args)
print('This is how argparse.REMAINDER works there is an option in front.')

parser = argparse.ArgumentParser()
parser.add_argument('--foo')
subparsers = parser.add_subparsers(dest='command')
commandParser = subparsers.add_parser('cmdname')
commandParser.add_argument('--filler-boundary-marker', dest='cmdname_args', 
nargs=argparse.REMAINDER)
args = parser.parse_args('--foo B cmdname --filler-boundary-marker --arg1 XX ZZ 
--foobar'.split())
if args != argparse.Namespace(cmdname_args=['--arg1', 'XX', 'ZZ', '--foobar'], 
command='cmdname', foo='B'):
raise Exception(args)
print('This is how argparse.REMAINDER works with a visible "filler" name for 
the list of arguments.')

parser = argparse.ArgumentParser()
parser.add_argument('--foo')
subparsers = parser.add_subparsers(dest='command')
commandParser = subparsers.add_parser('cmdname')
commandParser.add_argument('--filler-boundary-marker', dest='cmdname_args', 
nargs=argparse.REMAINDER)
args = parser.parse_args('cmdname --filler-boundary-marker --arg1 XX ZZ 
--foobar --foo B'.split())
if args != argparse.Namespace(cmdname_args=['--arg1', 'XX', 'ZZ', '--foobar', 
'--foo', 'B'], command='cmdname', foo=None):
raise Exception(args)
print("If an optional argument is provided after cmdname instead of before, it 
will get interpreted as part of the argparse.REMAINDER instead of normally. And 
that's great! We don't even need to be paranoid about other functions of our 
command-line tool sharing arguments with the tool we want to wrap. Everything 
will be forwarded.")

parser = argparse.ArgumentParser()
parser.add_argument('--foo')
subparsers = parser.add_subparsers(dest='command')
commandParser = subparsers.add_parser('cmdname')
commandParser.add_argument('positional_arg')
commandParser.add_argument('cmdname_args', nargs=argparse.REMAINDER)
args = parser.parse_args('cmdname can_put_anything_here --arg1 XX ZZ --foobar 
--foo B'.split())
if args != argparse.Namespace(cmdname_args=['--arg1', 'XX', 'ZZ', '--foobar', 
'--foo', 'B'], command='cmdname', positional_arg='can_put_anything_here', 
foo=None):
raise Exception(args)
print("If an optional argument is provided after cmdname instead of before, it 
will get interpreted as part of the argparse.REMAINDER instead of normally. And 
that's great! We don't even need to be paranoid about other functions of our 
command-line tool sharing arguments with the tool we want to wrap. Everything 
will be forwarded.")

"""
Note that this means we can fix the bug simply by,
whenever the cmdname subparser is invoked and the cmdname subparser uses 
argparse.REMAINDER,
automatically adding an imaginary first positional argument to the subparser
and inserting that imaginary first positional argument into the stream before 
parsing the arguments to cmdname.
https://github.com/python/cpython/blob/master/Lib/argparse.py#L1201
(Obviously it would be better to fix the underlying cause.)
"""

print('What we want to do is have a subparser that, in the case of one 
particular selection, forwards all following arguments to another tool.')
print('script.py --foo B cmdname --arg1 XX ZZ --foobar should dispatch to 
cmdname --arg1 XX ZZ --foobar.')
parser = argparse.ArgumentParser()
parser.add_argument('--foo')
subparsers = parser.add_subparsers(dest='command')
commandParser = subparsers.add_parser('cmdname')
commandParser.add_argument('cmdname_args', nargs=argparse.REMAINDER)

[issue39524] Escape sequences in doc string of ast._pad_whitespace

2020-02-13 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset fbeba8f2481411d608a616366394e07cdc52e0bb by mpheath in branch 
'master':
bpo-39524: Fixed doc-string in ast._pad_whitespace (GH-18340)
https://github.com/python/cpython/commit/fbeba8f2481411d608a616366394e07cdc52e0bb


--

___
Python tracker 

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



[issue24337] Implement `http.client.HTTPMessage.__repr__` to make debugging easier

2020-02-13 Thread Demian Brecht


Change by Demian Brecht :


--
nosy: +demian.brecht

___
Python tracker 

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



[issue39629] inspect.signature fails on math.hypot

2020-02-13 Thread Eric Fahlgren


New submission from Eric Fahlgren :

Python 3.8's new math.hypot function also appears to suffer from the same issue 
as math.log:

>>> import math, inspect
>>> inspect.signature(math.hypot)
Traceback (most recent call last):
  File "", line 1, in 
  File "C:\Program Files\Python38\lib\inspect.py", line 3093, in signature
return Signature.from_callable(obj, follow_wrapped=follow_wrapped)
  File "C:\Program Files\Python38\lib\inspect.py", line 2842, in from_callable
return _signature_from_callable(obj, sigcls=cls,
  File "C:\Program Files\Python38\lib\inspect.py", line 2296, in 
_signature_from_callable
return _signature_from_builtin(sigcls, obj,
  File "C:\Program Files\Python38\lib\inspect.py", line 2107, in 
_signature_from_builtin
raise ValueError("no signature found for builtin {!r}".format(func))
ValueError: no signature found for builtin 

Possibly related to issue29299?

--
components: Library (Lib)
messages: 361966
nosy: eric.fahlgren
priority: normal
severity: normal
status: open
title: inspect.signature fails on math.hypot
type: behavior
versions: Python 3.8

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset d905df766c367c350f20c46ccd99d4da19ed57d8 by Dong-hee Na in branch 
'master':
bpo-39573: Add Py_IS_TYPE() function (GH-18488)
https://github.com/python/cpython/commit/d905df766c367c350f20c46ccd99d4da19ed57d8


--

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 968dcd9e7a4d3aa9aaa1dfca693adf60d6b71ce7 by Brandt Bucher in 
branch 'master':
bpo-39573: Fix bad copy-paste in Py_SET_SIZE (GH-18496)
https://github.com/python/cpython/commit/968dcd9e7a4d3aa9aaa1dfca693adf60d6b71ce7


--

___
Python tracker 

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



[issue5996] abstract class instantiable when subclassing built-in types

2020-02-13 Thread Benedikt Bieringer


Change by Benedikt Bieringer <2xb.cod...@wwu.de>:


--
nosy: +2xB

___
Python tracker 

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



[ANN] 13ᵗʰ Advanced Scientific Programming in Python in Ghent, Belgium, 31 August—5 September, 2020

2020-02-13 Thread Tiziano Zito
13ᵗʰ Advanced Scientific Programming in Python
==

a Summer School by the ASPP faculty and the Ghent University

https://aspp.school

Scientists spend more and more time writing, maintaining, and debugging
software. While techniques for doing this efficiently have evolved, only few
scientists have been trained to use them. As a result, instead of doing their
research, they spend far too much time writing deficient code and reinventing
the wheel. In this course we will present a selection of advanced programming
techniques and best practices which are standard in the industry, but especially
tailored to the needs of a programming scientist. Lectures are devised to be
interactive and to give the students enough time to acquire direct hands-on
experience with the materials. Students will work in pairs throughout the school
and will team up to practice the newly learned skills in a real programming
project — an entertaining computer game.

We use the Python programming language for the entire course. Python works as
a simple programming language for beginners, but more importantly, it also works
great in scientific simulations and data analysis. We show how clean language
design, ease of extensibility, and the great wealth of open source libraries for
scientific computing and data visualization are driving Python to become
a standard tool for the programming scientist.

This school is targeted at Master or PhD students and Post-docs from all areas
of science. Competence in Python or in another language such as Java, C/C++,
MATLAB, or R is absolutely required. Basic knowledge of Python and of a version
control system such as git, subversion, mercurial, or bazaar is assumed.
Participants without any prior experience with Python and/or git should work
through the proposed introductory material before the course.

We are striving hard to get a pool of students which is international and
gender-balanced.

Date & Location
===
31 August–5 September, 2020. Ghent, Belgium.

Application
===
You can apply online: https://aspp.school/wiki/applications

Application deadline: 23:59 UTC, Sunday 24 May, 2020

There will be no deadline extension, so be sure to apply on time. Be sure to
read the FAQ before applying: https://aspp.school/wiki/faq

Participation is for free, i.e. no fee is charged! Accommodation in the student
residence comes at no costs for participants. We are trying to arrange financial
coverage for food expenses too, but this may not work. Participants however
should take care of travel expenses by themselves.

Program
===

• Version control with git and how to contribute to open source projects with 
GitHub
• Best practices in data visualization
• Testing and debugging scientific code
• Advanced NumPy
• Organizing, documenting, and distributing scientific code
• Advanced scientific Python: context managers and generators
• Writing parallel applications in Python
• Profiling and speeding up scientific code with Cython and numba
• Programming in teams

Faculty
===

• Caterina Buizza, Personal Robotics Lab, Imperial College London UK
• Lisa Schwetlick, Experimental and Biological Psychology, Universität Potsdam 
Germany
• Nelle Varoquaux, CNRS, TIMC-IMAG, University Grenoble Alpes France
• Nicolas P. Rougier, Inria Bordeaux Sud-Ouest, Institute of Neurodegenerative 
Disease, University of Bordeaux France
• Pamela Hathway, Neural Reckoning, Imperial College London UK
• Pietro Berkes, NAGRA Kudelski, Lausanne Switzerland
• Rike-Benjamin Schuppner, Institute for Theoretical Biology, 
Humboldt-Universität zu Berlin Germany
• Tiziano Zito, Department of Psychology, Humboldt-Universität zu Berlin Germany
• Zbigniew Jędrzejewski-Szmek, Red Hat Inc., Warsaw Poland

Organizers
==

Head of the organization for ASPP and responsible for the scientific program:

• Tiziano Zito, Department of Psychology, Humboldt-Universität zu Berlin Germany

Local team:

• Nina Turk, Photonics Research Group, INTEC, Ghent University – imec Belgium
• Freya Acar, Office for Data and Information, City of Ghent Belgium
• Joan Juvert

Institutional organizers:

• Wim Bogaerts, Photonics Research Group, INTEC, Ghent University –imec Belgium
• Sven Degroeve, VIB-UGent Center for Medical Biotechnology, Ghent Belgium
• Jeroen Famaey, Department of Mathematics and Computer Science, University of 
Antwerp – iMinds Belgium
• Bernard Manderick, Artificial Intelligence Lab, Vrije Universiteit Brussel 
Belgium


Website: https://aspp.school
Contact: info@aspp.school
--
Python-announce-list mailing list -- python-announce-list@python.org
To unsubscribe send an email to python-announce-list-le...@python.org
https://mail.python.org/mailman3/lists/python-announce-list.python.org/

Support the Python Software Foundation:
http://www.python.org/psf/donations/


[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread hai shi


hai shi  added the comment:

>"obj == Py_None" is a very common pattern.
>You have check how it is done in HPy: https://github.com/pyhandle/hpy
>See also bpo-39511: "[subinterpreters] Per-interpreter singletons (None, 
>>True, False, etc.)".

Thanks, I will check it.

--

___
Python tracker 

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



[issue5537] LWPCookieJar cannot handle cookies with expirations of 2038 or greater on 32-bit platforms

2020-02-13 Thread nmacleod


nmacleod  added the comment:

Apologies for the necro on this issue, but should this now be fixed in 
Python3.7? As it appears to still be an issue.

Testing on a Raspberry Pi with LibreELEC (32-bit OS):

rpi512:~ # python -c "import sys, http.cookiejar; print(sys.version); 
print(http.cookiejar.time2isoz(2322923767))"
3.7.6 (default, Feb 12 2020, 17:36:39)
[GCC 9.2.0]
Traceback (most recent call last):
  File "", line 1, in 
  File "/usr/lib/python3.7/cookiejar.py", line 101, in time2isoz
OverflowError: timestamp out of range for platform time_t


This is on a distribution built with latest glibc-2.31.

--
nosy: +nmacleod

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:

> Hi, guys. Is there value in adding `PyNone_Check` macro?

"obj == Py_None" is a very common pattern.

You have check how it is done in HPy: https://github.com/pyhandle/hpy

See also bpo-39511: "[subinterpreters] Per-interpreter singletons (None, True, 
False, etc.)".

--

___
Python tracker 

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



[issue39573] Make PyObject an opaque structure in the limited C API

2020-02-13 Thread hai shi


hai shi  added the comment:

Hi, guys. Is there value in adding `PyNone_Check` macro?(`_PyNone_Type` is not 
esposed to CAPI directly, so I am not sure about it)
If the answer is 'yes', i can add it ;)

--
nosy: +shihai1991

___
Python tracker 

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



[issue39624] Trace greedy replaces $prefix and $exec_prefix

2020-02-13 Thread Ben Boeckel


Ben Boeckel  added the comment:

`\b` is a bit too loose. That example should *not* have it replaced because it 
is not a full path component.

(Granted, any of these conflicting paths are "dumb" in general; I'm fine with 
just leaving this as a low priority, but if it does get modified, it should 
actually get fixed.)

--

___
Python tracker 

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



[issue39628] msg.walk memory leak?

2020-02-13 Thread Marco


New submission from Marco :

Hello,

 if I write

```
msg = email.message_from_bytes(...)
for part in msg.walk():
  content_type = part.get_content_type()
  if not part.get_content_maintype() == 'multipart':
 filename = part.get_filename(None)
 attachment = part.get_payload(decode=True)
```

if the mime parts are more than one, then the memory increases at each 
iteration and will never be released.

--
components: email
messages: 361959
nosy: barry, falon, r.david.murray
priority: normal
severity: normal
status: open
title: msg.walk memory leak?
type: resource usage
versions: Python 3.6

___
Python tracker 

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



[issue39627] Fix TypedDict totality check for inherited keys

2020-02-13 Thread Vlad Emelianov


Change by Vlad Emelianov :


--
title: Fix TypedDict totalizy check for inherited keys -> Fix TypedDict 
totality check for inherited keys

___
Python tracker 

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



[issue39627] Fix TypedDict totalizy check for inherited keys

2020-02-13 Thread Vlad Emelianov


Change by Vlad Emelianov :


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

___
Python tracker 

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



[issue39627] Fix TypedDict totalizy check for inherited keys

2020-02-13 Thread Vlad Emelianov


New submission from Vlad Emelianov :

Add changes made in https://github.com/python/typing/pull/700 to upstream.

--
components: Library (Lib)
messages: 361957
nosy: Vlad Emelianov
priority: normal
severity: normal
status: open
title: Fix TypedDict totalizy check for inherited keys
type: enhancement
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



[issue39617] max_workers argument to concurrent.futures.ProcessPoolExecutor is not flexible enough

2020-02-13 Thread sds


sds  added the comment:

cf https://github.com/joblib/loky/issues/233

--

___
Python tracker 

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



[issue39624] Trace greedy replaces $prefix and $exec_prefix

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:

str.replace() can be replaced with re.sub() and \b marker.

Example:

>>> re.sub(r'\$prefix\b', '[xxx]', '$prefix $prefixpath')
'[xxx] $prefixpath'

--

___
Python tracker 

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



[issue39626] random choice to delegate to sample on sets

2020-02-13 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +rhettinger

___
Python tracker 

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



[issue39626] random choice to delegate to sample on sets

2020-02-13 Thread Ilya Kamenshchikov


New submission from Ilya Kamenshchikov :

In a few of my projects I had this (minor) pain of having to remember which 
collections of elements are sets and which are [list, tuple]. It causes me to 
double check and have random.sample(my_set, 1)[0] in many places. 

To me this is not how I think and causes friction: conceptually, I know 
something is a collection and I want 1 random choice from it. Having to 
differentiate on sequences vs sets makes my code uglier :(

This issue is similar to https://bugs.python.org/issue37708.

--
components: Library (Lib)
messages: 361954
nosy: Ilya Kamenshchikov
priority: normal
severity: normal
status: open
title: random choice to delegate to sample on sets

___
Python tracker 

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



Re: Load python from different plugin dlls

2020-02-13 Thread R.Wieser
Eko,

> My test looks like this right now.

And there you have a probem, as I have no experience with what those 
functions do.   The below is therefore just a bit of educated guessing, so 
caveat emperor.

> According to the docs  PyImport_AppendInittab should be called
> before Py_Initialize

And should probably be done only once - adding the same module to the same 
list will likely fail, though the above function will than just return a -1 
(minus one) result.

>Py_InitializeEx(Py_IsInitialized() ? 0 : 1);

Initializing when already being initialized might well be the cause of your 
AccessViolation - the first plugin looses its objects, but still tries to 
use them.

Suggestion: Do a Py_IsInitialized() and if so skip the the Py_InitializeEx() 
(and maybe change that one to the simpler Py_Initialize() ).

Hope that helps.

Regards,
Rudy Wieser


-- 
https://mail.python.org/mailman/listinfo/python-list


[issue39625] Traceback needs more details

2020-02-13 Thread Andrew Wall


New submission from Andrew Wall :

I encountered a question on Stackoverflow where, unusually, a Traceback was 
given in full, but I couldn't diagnose the problem.

It was like this:

Traceback (most recent call last):
  File "soFailedTraceback.py", line 15, in 
c = C(C1("C1"), C2("C2"))
TypeError: __init__() missing 1 required positional argument: 'p'

What I am claiming is missing is info about class C1:
  File "soFailedTraceback.py", line 8, in 
def __init__(self, s1, p):


Here is the file soFailedTraceback.py:
#soFailedTraceback

class C:
def __init__(self, c1, p):
pass

class C1:
def __init__(self, s1, p):
pass

class C2:
def __init__(self, s1):
pass

c = C(C1("C1"), C2("C2"))

I find the Traceback confusing, because it so happens there are two classes 
which have required positional argument "p", but python does not directly show 
which class it is.

--
messages: 361953
nosy: Andrew Wall
priority: normal
severity: normal
status: open
title: Traceback needs more details
type: enhancement
versions: Python 3.8

___
Python tracker 

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



Re: Load python from different plugin dlls

2020-02-13 Thread Eko palypse
Thanks for the information.
My test looks like this right now.
I have two plugins which, when loaded separately, work.
But when both are loaded, I get AccessVioletion messages from python37.dll.
The init code for both dlls is this:

cpp_init_code = f'''#include 
#include "PluginInterface.h"

PyMODINIT_FUNC PyInit_{PLUGIN_NAME}(void);

BOOL APIENTRY DllMain( HANDLE hModule,
   DWORD reasonForCall,
   LPVOID /* lpReserved */ )
{{
switch ( reasonForCall )
{{
case DLL_PROCESS_ATTACH:
PyImport_AppendInittab("{PLUGIN_NAME}", _{PLUGIN_NAME});
Py_InitializeEx(Py_IsInitialized() ? 0 : 1);
PyImport_ImportModule("{PLUGIN_NAME}");
break;
case DLL_PROCESS_DETACH:
Py_Finalize();
break;

case DLL_THREAD_ATTACH:
break;

case DLL_THREAD_DETACH:
break;
}}

return TRUE;
}}'''

This is written to a plugininit.cpp file and then built via setup.py with
distutil, cython and VS2017.

According to the docs  PyImport_AppendInittab should be called before
Py_Initialize
but I can't call  Py_Initialize the second time as it would remove what was
initialized by the first dll.
And using PyImport_ImportModule on the second dll only does not work either.
So that is were I'm trapped.

Thank you
Eren

Am Do., 13. Feb. 2020 um 07:26 Uhr schrieb R.Wieser :

> Eko,
>
> > which needs also access to python3.dll but cannot load it itself as it
> has
> > been already loaded by plugin1
> >
> > Is such a scenario actually possible?
>
> Yes.
>
> Normally a DLL can be loaded in as many processes (and threads thereof) as
> you like.
>
> However, it is possible that the DLLs initialisation contains code to
> check
> if something it needs is available*, and if not directly exit.
>
> *like if it can access certain I/O - if the first DLL instance "takes
> posession" the second DLL instance wil fail.  Than again, this can also
> happen when using two totally different plugin DLLs.
>
> tl;dr:
> Yes, but not likely.
>
>
> --
> https://mail.python.org/mailman/listinfo/python-list
>
-- 
https://mail.python.org/mailman/listinfo/python-list


[issue39606] Regression: it should be possible to close async iterators multiple times

2020-02-13 Thread Nathaniel Smith


Change by Nathaniel Smith :


--
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



[issue39606] Regression: it should be possible to close async iterators multiple times

2020-02-13 Thread Nathaniel Smith


Nathaniel Smith  added the comment:


New changeset f464edf3239f7867fe31c9cd238a68fb3b90feaa by Nathaniel J. Smith in 
branch '3.7':
bpo-39606: allow closing async generators that are already closed (GH-18475) 
(GH-18502)
https://github.com/python/cpython/commit/f464edf3239f7867fe31c9cd238a68fb3b90feaa


--

___
Python tracker 

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



[issue39386] Prevent double awaiting of async iterator

2020-02-13 Thread Nathaniel Smith


Nathaniel Smith  added the comment:


New changeset f464edf3239f7867fe31c9cd238a68fb3b90feaa by Nathaniel J. Smith in 
branch '3.7':
bpo-39606: allow closing async generators that are already closed (GH-18475) 
(GH-18502)
https://github.com/python/cpython/commit/f464edf3239f7867fe31c9cd238a68fb3b90feaa


--
nosy: +njs

___
Python tracker 

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



[issue39623] __str__ and __repr__ for asyncio.Task still omit arg values

2020-02-13 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

This could sometimes make the output verbose when the arguments themselves are 
tasks while including arguments in the signature in _format_coroutine.

$ cat /tmp/foo.py
import asyncio

async def foo(a, b): pass

async def main():
task = asyncio.create_task(foo(1, b=1))
task1 = asyncio.create_task(foo(1, b=task))
print(repr(task))
print(repr(task1))

asyncio.run(main())

$ python3.8 /tmp/foo.py
>
>

$ ./python.exe /tmp/foo.py
>
>) running at /tmp/foo.py:3>>

--

___
Python tracker 

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



[issue39623] __str__ and __repr__ for asyncio.Task still omit arg values

2020-02-13 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
type:  -> behavior
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



[issue39624] Trace greedy replaces $prefix and $exec_prefix

2020-02-13 Thread Ben Boeckel


New submission from Ben Boeckel :

Previously reported as a sidenote in Issue21016.

The `--ignore-dir` option in trace.py replaces `$prefix` and `$exec_prefix` 
*anywhere* in the path when it really should just replace it in the start of 
the path and if it is followed by nothing or a path separator (that is, it is a 
path component). I suspect that there's always a separator though.

--
components: Library (Lib)
messages: 361949
nosy: mathstuf, vstinner
priority: normal
severity: normal
status: open
title: Trace greedy replaces $prefix and $exec_prefix

___
Python tracker 

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



[issue39386] Prevent double awaiting of async iterator

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 8dbdf5f275c6462bb522bcf3a29054239d72989d by Miss Islington (bot) 
in branch '3.8':
[3.8] bpo-39606: allow closing async generators that are already closed 
(GH-18475) (GH-18501)
https://github.com/python/cpython/commit/8dbdf5f275c6462bb522bcf3a29054239d72989d


--

___
Python tracker 

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



[issue39606] Regression: it should be possible to close async iterators multiple times

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 8dbdf5f275c6462bb522bcf3a29054239d72989d by Miss Islington (bot) 
in branch '3.8':
[3.8] bpo-39606: allow closing async generators that are already closed 
(GH-18475) (GH-18501)
https://github.com/python/cpython/commit/8dbdf5f275c6462bb522bcf3a29054239d72989d


--

___
Python tracker 

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



[issue39386] Prevent double awaiting of async iterator

2020-02-13 Thread Nathaniel Smith


Change by Nathaniel Smith :


--
pull_requests: +17878
pull_request: https://github.com/python/cpython/pull/18502

___
Python tracker 

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



[issue39606] Regression: it should be possible to close async iterators multiple times

2020-02-13 Thread Nathaniel Smith


Change by Nathaniel Smith :


--
pull_requests: +17877
pull_request: https://github.com/python/cpython/pull/18502

___
Python tracker 

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



[issue21016] trace: $prefix and $exec_prefix improperly replaced on Fedora

2020-02-13 Thread STINNER Victor


STINNER Victor  added the comment:

> It also erroneously replaces things like '$prefixpath'. It should probably do 
> split the path on the path separators and only replace components that are 
> equal to $prefix or $exec_prefix (so that the '$' can be escaped for 
> directories named as such literally, but that would require a pass to parse 
> the escapes).

re.sub() can be used to leave $prefixpath unchanged. Yeah, please open a 
separed issue. Sorry, I missed this part of the bug report.

--

___
Python tracker 

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



[issue39184] Many command execution functions are not raising auditing events

2020-02-13 Thread Steve Dower


Steve Dower  added the comment:


New changeset a00b5be5f71b702ab80b0a7c046485046aaae160 by Steve Dower in branch 
'3.8':
bpo-39184: Add audit events to functions in `fcntl`, `msvcrt`, `os`, 
`resource`,  `shutil`, `signal`, `syslog` (GH-18407)
https://github.com/python/cpython/commit/a00b5be5f71b702ab80b0a7c046485046aaae160


--

___
Python tracker 

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



[issue39623] __str__ and __repr__ for asyncio.Task still omit arg values

2020-02-13 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
nosy: +xtreak

___
Python tracker 

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



[issue39623] __str__ and __repr__ for asyncio.Task still omit arg values

2020-02-13 Thread Karthikeyan Singaravelan


Change by Karthikeyan Singaravelan :


--
components: +asyncio
nosy: +asvetlov, yselivanov

___
Python tracker 

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



[issue39623] __str__ and __repr__ for asyncio.Task still omit arg values

2020-02-13 Thread Stuart Ball


New submission from Stuart Ball :

This is not very helpful if your gather or wait contains multiple versions of 
foo with different argument values: 

``

Should just be:

``

Would probably take all of 5 minutes to implement and make a lot of people's 
lives easier.

--
messages: 361944
nosy: stuball123
priority: normal
severity: normal
status: open
title: __str__ and __repr__ for asyncio.Task still omit arg values

___
Python tracker 

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



[issue39606] Regression: it should be possible to close async iterators multiple times

2020-02-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17875
pull_request: https://github.com/python/cpython/pull/18501

___
Python tracker 

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



[issue39386] Prevent double awaiting of async iterator

2020-02-13 Thread miss-islington


Change by miss-islington :


--
pull_requests: +17876
pull_request: https://github.com/python/cpython/pull/18501

___
Python tracker 

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



[issue39606] Regression: it should be possible to close async iterators multiple times

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 925dc7fb1d0db85dc137afa4cd14211bf0d67414 by Nathaniel J. Smith in 
branch 'master':
bpo-39606: allow closing async generators that are already closed (GH-18475)
https://github.com/python/cpython/commit/925dc7fb1d0db85dc137afa4cd14211bf0d67414


--
nosy: +miss-islington

___
Python tracker 

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



[issue39386] Prevent double awaiting of async iterator

2020-02-13 Thread miss-islington


miss-islington  added the comment:


New changeset 925dc7fb1d0db85dc137afa4cd14211bf0d67414 by Nathaniel J. Smith in 
branch 'master':
bpo-39606: allow closing async generators that are already closed (GH-18475)
https://github.com/python/cpython/commit/925dc7fb1d0db85dc137afa4cd14211bf0d67414


--

___
Python tracker 

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



[issue39184] Many command execution functions are not raising auditing events

2020-02-13 Thread Steve Dower


Change by Steve Dower :


--
pull_requests: +17874
pull_request: https://github.com/python/cpython/pull/18500

___
Python tracker 

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