[issue14965] super() and property inheritance behavior

2021-05-20 Thread Daniel Urban
Daniel Urban added the comment: @habnabit I believe I've already signed some contributor form some years ago. If there is a new one, I can sign that one too. -- ___ Python tracker __

[issue44184] crash on windows invoking flake8

2021-05-20 Thread Steve Dower
Steve Dower added the comment: > I've found that it's reproducible if you run flake8 on a file that just > contains: `a.b` ISTR there were some changes made to assigning attributes on AST classes recently? I forget who did them, but I remember discussing it during the sprints last year. Per

[issue44184] crash on windows invoking flake8

2021-05-20 Thread Anthony Sottile
Anthony Sottile added the comment: would it maybe be helpful to bisect a history where the dataclasses / inspect import change is introduced earlier? this would perhaps help pinpoint the other commit which is causing this? -- ___ Python tracker

[issue44199] code example index error in tutorial controlflow

2021-05-20 Thread HVoltBb
New submission from HVoltBb : An index error in the code example given just above https://docs.python.org/3/tutorial/controlflow.html#documentation-strings The code now is : pairs = [(1, 'one'), (2, 'two'), (3, 'three'), (4, 'four')] pairs.sort(key=lambda pair: pair[1]) pairs The "pair[1]" in

[issue44199] code example index error in tutorial controlflow

2021-05-20 Thread HVoltBb
Change by HVoltBb : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker ___ ___ Python-bugs-l

[issue44189] multiprocessing AF_PIPE name format is slightly confusing in the docs

2021-05-20 Thread Eryk Sun
Eryk Sun added the comment: There's a formatting problem in Doc/library/multiprocessing.rst due to consumption of the backslashes in multiple steps. The following keeps all of the required backslashes in the HTML output: * An ``'AF_PIPE'`` address is a string of the form :samp:`r'\

[issue44197] [request feature] Itertools extended combinations to limited number of repetition

2021-05-20 Thread Dennis Sweeney
Dennis Sweeney added the comment: How is proposed_function("abcd", max_repeat=3) any different from what you can currently spell as combinations("aaabbbcccddd") ? Or, more generally, def proposed_function(it, repeats) repeated = chain.from_iterable([x] * repeat for x in it) return com

[issue44184] crash on windows invoking flake8

2021-05-20 Thread STINNER Victor
STINNER Victor added the comment: I have a reproducer (.py script) on Windows, but the crash rate is between 1/3 and 1/2. Also, in VS, if I run "import bug" (bug.py) in the REPL, I fail to reproduce the crash. Using "exec(open('../bug.py').read())" is more likely to trigger the crash, but in

[issue44184] crash on windows invoking flake8

2021-05-20 Thread STINNER Victor
Change by STINNER Victor : -- keywords: +patch pull_requests: +24880 stage: -> patch review pull_request: https://github.com/python/cpython/pull/26274 ___ Python tracker ___ _

[issue40280] Consider supporting emscripten/webassembly as a build target

2021-05-20 Thread Ethan Smith
Ethan Smith added the comment: I think the first thing we should do is figure out whether we want to support Emscripten or WASI (or both). Emscripten uses Javascript polyfills for some syscalls, while WASI makes direct calls the VM it is running in. They both can use WebAssembly for executin

[issue44184] crash on windows invoking flake8

2021-05-20 Thread STINNER Victor
STINNER Victor added the comment: Apply attached debug_subtype_dealloc.patch to reproduce the issue on Linux with attached ref.py script: $ ./python ref.py exit subtype_dealloc(_ABC): call basedealloc() with Py_REFCNT(type)=1 subtype_dealloc(_Precedence): call basedealloc() with Py_REFCNT(ty

[issue44184] crash on windows invoking flake8

2021-05-20 Thread STINNER Victor
Change by STINNER Victor : Added file: https://bugs.python.org/file50056/debug_subtype_dealloc.patch ___ Python tracker ___ ___ Python-bugs-

[issue44200] Recommend importlib.abc.Traversable users to implement __fspath__

2021-05-20 Thread Filipe Laíns
New submission from Filipe Laíns : The files()/Traversable api is meant to replace ResourceReader api, but it falls short in one dimension, tying the abstraction to a file system path. I propose to document that Traversable users *should* implement __fspath__ if the Traversable represents a fi

[issue44200] Recommend importlib.abc.Traversable users to implement __fspath__

2021-05-20 Thread Filipe Laíns
Filipe Laíns added the comment: I am gonna wait until/if GH-26272 (#44196) gets merged because this would conflict with that. -- ___ Python tracker ___ ___

[issue44184] crash on windows invoking flake8

2021-05-20 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Ok, I got a crash under the address sanitizer using ref.py: ./python lel.py exit Cycle.__del__ Cycle.__del__ = ==77503==ERROR: AddressSanitizer: heap-use-after-free on address 0x6195a6

[issue44184] crash on windows invoking flake8

2021-05-20 Thread STINNER Victor
STINNER Victor added the comment: Valgrind detects the bug (unmodified Python): $ PYTHONMALLOC=debug valgrind ./python ref.py (...) ==607098== Invalid read of size 8 ==607098==at 0x493FBE: subtype_dealloc (typeobject.c:1456) ==607098==by 0x47C914: _Py_Dealloc (object.c:2288) ==607098=

[issue44200] Recommend importlib.abc.Traversable users to implement __fspath__

2021-05-20 Thread Filipe Laíns
Change by Filipe Laíns : -- assignee: -> docs@python components: +Documentation nosy: +docs@python ___ Python tracker ___ ___ Python

[issue44201] REPL requests another line despite syntax error

2021-05-20 Thread Guido van Rossum
New submission from Guido van Rossum : This seems a regression from 3.9. >>> foo[x = 1 ... ] File "", line 1 foo[x = 1 ^ SyntaxError: invalid syntax. Maybe you meant '==' or ':=' instead of '='? >>> Note how the syntax error is in line 1 and yet the REPL asks for more input

[issue44201] REPL requests another line despite syntax error

2021-05-20 Thread Guido van Rossum
Change by Guido van Rossum : -- nosy: +lys.nikolaou, pablogsal ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44201] REPL requests another line despite syntax error

2021-05-20 Thread Guido van Rossum
Change by Guido van Rossum : -- keywords: +3.10regression ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: htt

[issue44202] Add errors argument to importlib.abc.Traversable.read_text

2021-05-20 Thread Filipe Laíns
New submission from Filipe Laíns : errors should be supported by Traversable.open and is currently supported in importlib.resources.open_text, but Traversable.read_text cannot do it, making it an unsuitable replacement for open_text. -- messages: 394088 nosy: FFY00, brett.cannon, jarac

[issue44202] Add errors argument to importlib.abc.Traversable.read_text

2021-05-20 Thread Filipe Laíns
Filipe Laíns added the comment: I am gonna wait until/if GH-26272 (#44196) gets merged to submit a PR because it will conflict with that. -- components: +Library (Lib) versions: +Python 3.11 ___ Python tracker _

[issue43882] [security] urllib.parse should sanitize urls containing ASCII newline and tabs.

2021-05-20 Thread Senthil Kumaran
Change by Senthil Kumaran : -- pull_requests: +24881 stage: commit review -> patch review pull_request: https://github.com/python/cpython/pull/26275 ___ Python tracker ___

[issue44120] logging.config.fileConfig/dictConfig can not import class

2021-05-20 Thread Hiroaki Mizuguchi
Hiroaki Mizuguchi added the comment: bar module use logging module of stdlib not bar.logging module in this test case. change the statement to `from . import logging` is not a solution. -- ___ Python tracker _

[issue44201] REPL requests another line despite syntax error

2021-05-20 Thread Pablo Galindo Salgado
Pablo Galindo Salgado added the comment: Unfortunately this happens because to generate the error message we check for the equal and the right hand side of the equal (to also discard some false positives) and this triggers the parser to ask for additional tokens. Notice that you don't need t

[issue44194] Folding ''.join() into f-strings

2021-05-20 Thread Eric V. Smith
Eric V. Smith added the comment: To be pedantic, f-strings don't "cast" to a string, they call format(obj) on the argument. Typically this is the same as str(obj), but it need not be. I guess if all of the arguments are already exact strings then this distinction doesn't matter, but I'd have

[issue44199] code example index error in tutorial controlflow

2021-05-20 Thread Eric V. Smith
Eric V. Smith added the comment: The example is correct. The result is sorted by the second item (index=1) of each tuple: four one three two Maybe the text could make it more clear that that's the desired output. -- nosy: +eric.smith ___ Python t

[issue43882] [security] urllib.parse should sanitize urls containing ASCII newline and tabs.

2021-05-20 Thread Senthil Kumaran
Change by Senthil Kumaran : -- pull_requests: +24882 pull_request: https://github.com/python/cpython/pull/26276 ___ Python tracker ___ _

[issue43882] [security] urllib.parse should sanitize urls containing ASCII newline and tabs.

2021-05-20 Thread Senthil Kumaran
Change by Senthil Kumaran : -- pull_requests: +24883 pull_request: https://github.com/python/cpython/pull/26277 ___ Python tracker ___ _

[issue14965] super() and property inheritance behavior

2021-05-20 Thread Will Razen
Will Razen added the comment: Fixed superprop.py workaround, now works with multiple inheritance and follows mro adequately. Renamed to duper.py as inspired by Torsten. Uploading here and also to https://gist.github.com/willrazen/bef3fcb26a83dffb6692e5e10d3e67ac -- Added file: https:

[issue44197] [request feature] Itertools extended combinations to limited number of repetition

2021-05-20 Thread Tim Peters
Tim Peters added the comment: Dennis, combinations("aaabbbcccddd") isn't a valid call - the function requires a "how many?" argument too. If, e.g., we were asking for groups of 4, then combinations("aaabbbcccddd", 4) generates the 4-tuple ('a', 'b', 'c', 'd') 81 (3**4) times, while the OP pr

[issue44197] [request feature] Itertools extended combinations to limited number of repetition

2021-05-20 Thread Tim Peters
Change by Tim Peters : -- nosy: +rhettinger ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.pyth

[issue44150] Add optional weights parameter to statistics.fmean()

2021-05-20 Thread Raymond Hettinger
Change by Raymond Hettinger : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___ ___

<    1   2