[issue40612] Make traceback module's formatting of SyntaxError more similar to system formatting

2020-05-14 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Agreed on everything. One thing I don't really understand is if you propose to also strip trailing whitespace. Does "limit the offset to just past the end of the source text" include whitespace or not? For example, the linked PR does

[issue40612] Make traceback module's formatting of SyntaxError more similar to system formatting

2020-05-14 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Understood. -- ___ Python tracker <https://bugs.python.org/issue40612> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40618] PEG Parser: Invalid targets for augassign and except succeed

2020-05-14 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2020-05-15 Thread Lysandros Nikolaou
New submission from Lysandros Nikolaou : The new PEG parser fails when a parenthesised expression with a single child (a group) contains a starred expression. Example: ╰─ ./python.exe Python 3.9.0a6+ (heads/master-dirty:4a12d12186, May 15 2020, 14:53:45) [Clang 11.0.0 (clang-1100.0.33.8)] on

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2020-05-15 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Whoops, false alarm. It's just that we moved the check for invalid starred expressions to the parser, while it previously was in the compiler. ╰─ ./python.exe -X oldparser Python 3.9.0a6+ (heads/master-dirty:003708bcf8, May 15 2020, 15:08:21) [

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2020-05-15 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40334] PEP 617: new PEG-based parser

2020-05-15 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19413 pull_request: https://github.com/python/cpython/pull/20106 ___ Python tracker <https://bugs.python.org/issue40

[issue40334] PEP 617: new PEG-based parser

2020-05-17 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19454 pull_request: https://github.com/python/cpython/pull/20151 ___ Python tracker <https://bugs.python.org/issue40

[issue40334] PEP 617: new PEG-based parser

2020-05-17 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19456 pull_request: https://github.com/python/cpython/pull/20153 ___ Python tracker <https://bugs.python.org/issue40

[issue40661] The new parser segfaults when parsing invalid input

2020-05-17 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19464 pull_request: https://github.com/python/cpython/pull/20165 ___ Python tracker <https://bugs.python.org/issue40

[issue40334] PEP 617: new PEG-based parser

2020-05-18 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I'm not getting any compiler warnings on macOS (clang) and on Ubuntu (gcc) and I can't find any related warnings on the Windows Github Actions logs either. Could you maybe post a verbose log of test_peg_generato

[issue40669] PEG Parser benchmarks fail if memory_profiler is not installed

2020-05-18 Thread Lysandros Nikolaou
New submission from Lysandros Nikolaou : Running the PEG Parser benchmarks requires having memory_profiler installed. In Tools/peg_generator: ➜ peg_generator git:(master) make time_stdlib ../../python -m zipfile -e data/xxl.zip data ../../python scripts/benchmark.py --parser=cpython --target

[issue40669] PEG Parser benchmarks fail if memory_profiler is not installed

2020-05-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch pull_requests: +19471 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20172 ___ Python tracker <https://bugs.python.org/issu

[issue40669] PEG Parser benchmarks fail if memory_profiler is not installed

2020-05-18 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Because `make time` and all the related Makefile targets use the local built Python in the cpython parent directory. In order to install it, one would have to go through various steps, like installing openssl, configuring python with ssl support

[issue40669] PEG Parser benchmarks fail if memory_profiler is not installed

2020-05-18 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Doc/Makefile uses a virtual environment to install Sphinx and Sphinx > extensions. I suggest to do something similar. I like this approach. Let me try it. -- ___ Python tracker <https://bugs.p

[issue40669] PEG Parser benchmarks fail if memory_profiler is not installed

2020-05-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19484 pull_request: https://github.com/python/cpython/pull/20183 ___ Python tracker <https://bugs.python.org/issue40

[issue40669] PEG Parser benchmarks fail if memory_profiler is not installed

2020-05-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40546] Inconsistencies between PEG parser and traceback SyntaxErrors

2020-05-18 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Fixed in GH-20072 and bpo-40612. -- resolution: -> fixed stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40614] ast.parse doesn't respect feature_version for debug f-strings

2020-05-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: +lys.nikolaou ___ Python tracker <https://bugs.python.org/issue40614> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42521] Debug (-d) mode not working in 3.9

2020-12-01 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Hi Anthony, could it be that your 3.9 is not a debug build, while the others are? We only enable parser debug ouput when Python has been build --with-pydebug. Building the 3.9.0 tag --with-pydebug works fine for me

[issue30858] Keyword can't be an expression?

2020-12-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I like the current error message. What bugs me a little is the position of the caret, which I think is a bit misleading. Guido, Pablo, should we move the caret to point at the `=` sign or whatever comes after it? I think I prefer the former

[issue42577] Unhelpful syntax error when expression spans multiple lines

2020-12-14 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Thanks for opening an issue here, Christoph. This is the right place to discuss this. Indeed the parser is pretty dumb when reporting errors. In the technical sense the colon is the right thing to point to, since it's the first token that&

[issue42725] PEP 563: Should the behavior change for yield/yield from's

2020-12-24 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I concur with Guido. I feel that making this an error is the best alternative we have. -- ___ Python tracker <https://bugs.python.org/issue42

[issue42729] tokenize, ast: No direct way to parse tokens into AST, a gap in the language processing pipiline

2020-12-24 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: The thing is that the parser itself does not get a stream of tokens as input. It only accepts either a file or a string and it lazily converts its input to tokens. As for the PR attached to this patch, I'm -1 on that. I don't think the u

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2020-12-30 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: It makes sense to me to be able to do `(*a), b` if I can do `*a, b`, but I don't really have a strong opinion on it. -- ___ Python tracker <https://bugs.python.org/is

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2020-12-30 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Yup, this all sounds much more reasonable. Thanks for the explanation, Guido. > Also the current behavior allows `(*x), y = 1` assignment. If `(*x)` is to be > totally disallowed, `(*x), y = 1` should also be rejected. This is allowed in 3.9

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2020-12-31 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +22867 pull_request: https://github.com/python/cpython/pull/24027 ___ Python tracker <https://bugs.python.org/issue40

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2021-01-02 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: New changeset 2ea320553298038bb7d6789e50e199332f66 by Lysandros Nikolaou in branch 'master': bpo-40631: Disallow single parenthesized star target (GH-24027) https://github.com/python/cpython/commit/2ea320553298038bb7d6789e50

[issue40631] PEG Parser: Cannot used starred expression in parenthesised expr

2021-01-02 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +22901 pull_request: https://github.com/python/cpython/pull/24068 ___ Python tracker <https://bugs.python.org/issue40

[issue42827] pegen parser: Multiline eval with assignment to function call: assertion failed

2021-01-04 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Thanks for letting us know, Julien! I've identified the bug and where it comes from and I'll probably work on it tomorrow. -- ___ Python tracker <https://bugs.python.o

[issue42827] pegen parser: Multiline eval with assignment to function call: assertion failed

2021-01-05 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +22954 pull_request: https://github.com/python/cpython/pull/24124 ___ Python tracker <https://bugs.python.org/issue42

[issue42827] pegen parser: Multiline eval with assignment to function call: assertion failed

2021-01-06 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +22969 pull_request: https://github.com/python/cpython/pull/24140 ___ Python tracker <https://bugs.python.org/issue42

[issue42860] Incompatible types in Python grammar

2021-01-07 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: +lys.nikolaou ___ Python tracker <https://bugs.python.org/issue42860> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue42860] Incompatible types in Python grammar

2021-01-07 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch pull_requests: +22984 stage: -> patch review pull_request: https://github.com/python/cpython/pull/24156 ___ Python tracker <https://bugs.python.org/issu

[issue42860] Incompatible types in Python grammar

2021-01-07 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: This is now fixed, Tobias! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue42827] pegen parser: Multiline eval with assignment to function call: assertion failed

2021-01-14 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: This is now fixed. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue42997] Improve error message for missing : before suites

2021-01-26 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I propose to go with the first approach. I really like that and I can see us using it in various place in the future. It's basically a positive lookahead with a cut, but the extra feature that it raises a SyntaxError, right? I'll have a look

[issue42997] Improve error message for missing : before suites

2021-01-26 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Yeah, but the cut is "absolute" (because of the syntax Error). IIRC the > normal cut only affects that rule, no? Right. -- ___ Python tracker <https://bugs.py

[issue42919] Blank in multiline “if expressions” will lead to EOF errors

2021-02-05 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I can't really understand if this should be considered a bug or not. It's definitely consistent with 3.8 and my inclination that it is not. -- nosy: +pablogsal ___ Python tracker <https://bu

[issue42918] Nested multi-line expression will lead to "compile()" fails

2021-02-05 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Thanks a lot for the report, Xinmeng! This is a bug in how we're checking for bad single statements in bad_single_statement and it's not trivial to fix due to the string shenanigans we're doing there in newline_in_string, which does not a

[issue42128] Structural Pattern Matching (PEP 634)

2021-02-09 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: The grammar is indeed auto-generated by reading the actual Grammar file, python.gram. Here's the lexer Pablo had developed for doing the syntax-highlighting. https://github.com/python/cpython/blob/master/Doc/tools/extensions/peg_highlig

[issue34013] Inconsistent SyntaxError for print

2021-02-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: +lys.nikolaou ___ Python tracker <https://bugs.python.org/issue34013> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40688] PEG Generator: Fix scripts to always use the correct parser

2020-05-19 Thread Lysandros Nikolaou
New submission from Lysandros Nikolaou : All the scripts in Tools/peg_generator/scripts need to be updated, since they mostly assume that ast.parse and compile use the old parser. We can use the _peg_parser extension module instead, but it well need some enhancements so that it also supports

[issue40688] PEG Generator: Fix scripts to always use the correct parser

2020-05-19 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch pull_requests: +19522 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20235 ___ Python tracker <https://bugs.python.org/issu

[issue40716] Pegen: improve error messages for unparenthesized from imports with trailing comma

2020-05-21 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: +gvanrossum, lys.nikolaou, pablogsal ___ Python tracker <https://bugs.python.org/issue40716> ___ ___ Python-bugs-list m

[issue40688] PEG Generator: Fix scripts to always use the correct parser

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue38964] Output of syntax error in f-string contains wrong filename

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- versions: +Python 3.10 -Python 3.8 ___ Python tracker <https://bugs.python.org/issue38964> ___ ___ Python-bugs-list mailin

[issue38964] Output of syntax error in f-string contains wrong filename

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch nosy: +lys.nikolaou nosy_count: 4.0 -> 5.0 pull_requests: +19662 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20399 ___ Python tracker <https://bugs.p

[issue40246] Different error messages for same error - invalid string prefixes

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19664 stage: resolved -> patch review pull_request: https://github.com/python/cpython/pull/20402 ___ Python tracker <https://bugs.python.org/issu

[issue40246] Different error messages for same error - invalid string prefixes

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> wont fix stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue38964] Output of syntax error in f-string contains wrong filename

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19666 pull_request: https://github.com/python/cpython/pull/20404 ___ Python tracker <https://bugs.python.org/issue38

[issue38964] Output of syntax error in f-string contains wrong filename

2020-05-25 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40880] Invalid read in pegen.c

2020-06-05 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: +gvanrossum, pablogsal ___ Python tracker <https://bugs.python.org/issue40880> ___ ___ Python-bugs-list mailing list Unsub

[issue40847] New parser considers empty line following a backslash to be a syntax error, old parser didn't

2020-06-05 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: This is limited to cases where the line continuation character is on an otherwise empty line. For example this works correctly: $ cat t.py print("hello world") print("hello world 2") \ print("hello world 3") $ ./python.exe

[issue40614] ast.parse doesn't respect feature_version for debug f-strings

2020-06-06 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue22021] shutil.make_archive() root_dir do not work

2020-06-08 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Since GH-10367 is now merged, should we close this? -- ___ Python tracker <https://bugs.python.org/issue22021> ___ ___

[issue30533] missing feature in inspect module: getmembers_static

2020-06-09 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: -lys.nikolaou ___ Python tracker <https://bugs.python.org/issue30533> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue40847] New parser considers empty line following a backslash to be a syntax error, old parser didn't

2020-06-09 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch pull_requests: +19967 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20769 ___ Python tracker <https://bugs.python.org/issu

[issue40939] Remove the old parser

2020-06-11 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19996 pull_request: https://github.com/python/cpython/pull/20800 ___ Python tracker <https://bugs.python.org/issue40

[issue40939] Remove the old parser

2020-06-11 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Can we rename the keyword to "__peg_parser__"? I guess we could just remove this, as soon as the old parser is out. We were only using this to differentiate between the two parsers, when we were testing enabling/disabling the old one. I c

[issue40939] Remove the old parser

2020-06-11 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > I would personally would like to keep the easter egg, but I assume is better > to rename it to "__peg_parser__". Ok then! On it. -- ___ Python tracker <https://bugs.py

[issue40939] Remove the old parser

2020-06-11 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +19998 pull_request: https://github.com/python/cpython/pull/20802 ___ Python tracker <https://bugs.python.org/issue40

[issue40939] Remove the old parser

2020-06-11 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Lysandros can you modify PR 20802 to remove it? Yup! -- ___ Python tracker <https://bugs.python.org/issue40939> ___ _

[issue40939] Remove the old parser

2020-06-11 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > This change broke this buildbot: GH-20802 fixes this breakage. -- ___ Python tracker <https://bugs.python.org/issu

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Lysandros, could you take a look? Yup, I'm on it. -- ___ Python tracker <https://bugs.python.org/issue40958> ___

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Agreed. For that I'd probably need the input Christian is getting the error with. I'm currently trying things out, but haven't gotten the error yet. -- ___ Python tracker <https://bugs.pyt

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I cannot reproduce this on my Ubuntu 20.04: ➜ cpython git:(master) ✗ LSAN_OPTIONS="suppressions=asan-suppression.txt,print_suppressions=0" ./python -m test -v test_eof Modules/posixmodule.c:14682:9: runtime error: left shift of 34 by 26 plac

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Running Pablo's examples in the REPL does not reproduce the errors either: ➜ cpython git:(master) ✗ LSAN_OPTIONS="suppressions=asan-suppression.txt,print_suppressions=0" ./python Modules/posixmodule.c:14682:9: runt

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Let me try that. I'm currently using gcc 9.3. -- ___ Python tracker <https://bugs.python.org/issue40958> ___ ___ Pytho

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I now configured Python with ./configure --with-pydebug --with-address-sanitizer --with-undefined-behavior-sanitizer. -- ___ Python tracker <https://bugs.python.org/issue40

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Lysandros, are you using a debug build? The assert() won't trigger if you > don't have run configure with --with-pydebug. BTW I'm not talking about the assert not triggering. I'm only saying that ASAN/UBSAN do not report an

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Is the only way to get gcc-10.1 to build from source? Because currently my internet connection is too slow to get all of gcc downloaded and `apt install gcc-10` installs 10.0.1, which I'm getting totally unrelated erros

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Note that although we could just exit if the length of the line is smaller > than the column offset before calling > https://github.com/python/cpython/blob/master/Parser/pegen.c#L148 (I assume > that is the problem) is more important to un

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > What happens with: >>> "Ṕýţĥòñ" + Exact same thing. The offset is 16 at the start and gets decreased to 15 in the line I linked to in my previous post. And then col_offset gets converted to col_number which is 9, which seems co

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I'm guessing that some parts of the conversion code were only there to circumvent issues in displaying the error messages that weren't pegen's fault. These were fixed by Guido in GH-20072, so I think we can delete some of them. For exam

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > Can you run the test suite before/after of pyflakes to make sure we don't > introduce any regression to double check? If everything looks fine, open a PR > :) The exact same errors before and after! I'll wait on the PR though till s

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-12 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > +Py_ssize_t linesize = PyUnicode_GET_LENGTH(line); This line is wrong though, since PyUnicode_GET_LENGTH returns the length in code points and PyUnicode_DecodeUTF8 expects the number of bytes. For non-ascii input this would push the caret furt

[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT

2020-06-15 Thread Lysandros Nikolaou
New submission from Lysandros Nikolaou : While investigating bpo-40958, the following came up: When a file ends with a line that contains a line continuation character the text of the emitted SyntaxError is empty, contrary to the old parser, where the error text contained the text of the

[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT

2020-06-15 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Copying and pasting the example messed the formatting up. Here it is again. [16:49:16] lysnikolaou:cpython git:(master*) $ cat t.py x = 6\% [16:49:23

[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT

2020-06-15 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I keep doing something wrong. I hope it is clean by now what the difference is. -- ___ Python tracker <https://bugs.python.org/issue40

[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT

2020-06-15 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- nosy: +gvanrossum, pablogsal ___ Python tracker <https://bugs.python.org/issue40985> ___ ___ Python-bugs-list mailing list Unsub

[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT

2020-06-15 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch pull_requests: +20071 stage: -> patch review pull_request: https://github.com/python/cpython/pull/20888 ___ Python tracker <https://bugs.python.org/issu

[issue40985] PEG Parser: SyntaxError text empty when last line has a LINECONT

2020-06-15 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-18 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: > WIll make a PR soon No need. Already got something ready. -- ___ Python tracker <https://bugs.python.org/issu

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20146 pull_request: https://github.com/python/cpython/pull/20968 ___ Python tracker <https://bugs.python.org/issue40

[issue40958] ASAN/UBSAN: heap-buffer-overflow in pegen.c

2020-06-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20148 pull_request: https://github.com/python/cpython/pull/20970 ___ Python tracker <https://bugs.python.org/issue40

[issue40334] PEP 617: new PEG-based parser

2020-06-18 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20150 pull_request: https://github.com/python/cpython/pull/20973 ___ Python tracker <https://bugs.python.org/issue40

[issue40334] PEP 617: new PEG-based parser

2020-06-19 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: All parts of the implementation are now in. New issues should be opened for any potential bugs. -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracke

[issue40939] Remove the old parser

2020-06-20 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: I'm currently testing a commit that removes all these files on my fork, before I push it upstream. A question that I'm not 100% sure about is if we can already remove the symbol module. I guess it's okay since it got deprecated in 3.9

[issue40939] Remove the old parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20179 pull_request: https://github.com/python/cpython/pull/21005 ___ Python tracker <https://bugs.python.org/issue40

[issue40939] Remove the old parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20186 pull_request: https://github.com/python/cpython/pull/21012 ___ Python tracker <https://bugs.python.org/issue40

[issue40939] Remove the old parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20190 pull_request: https://github.com/python/cpython/pull/21016 ___ Python tracker <https://bugs.python.org/issue40

[issue41060] `with a as b` segfault in new peg parser

2020-06-20 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: On it. -- ___ Python tracker <https://bugs.python.org/issue41060> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue41060] `with a as b` segfault in new peg parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- keywords: +patch pull_requests: +20192 stage: -> patch review pull_request: https://github.com/python/cpython/pull/21020 ___ Python tracker <https://bugs.python.org/issu

[issue41060] `with a as b` segfault in new peg parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- assignee: -> lys.nikolaou ___ Python tracker <https://bugs.python.org/issue41060> ___ ___ Python-bugs-list mailing list Un

[issue41060] `with a as b` segfault in new peg parser

2020-06-20 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Thanks for the report, Steve. I've now opened a PR that should fix this. -- ___ Python tracker <https://bugs.python.org/is

[issue41060] `with a as b` segfault in new peg parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20196 pull_request: https://github.com/python/cpython/pull/21024 ___ Python tracker <https://bugs.python.org/issue41

[issue41060] `with a as b` segfault in new peg parser

2020-06-20 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue40939] Remove the old parser

2020-06-21 Thread Lysandros Nikolaou
Change by Lysandros Nikolaou : -- pull_requests: +20207 pull_request: https://github.com/python/cpython/pull/21036 ___ Python tracker <https://bugs.python.org/issue40

[issue40939] Remove the old parser

2020-06-21 Thread Lysandros Nikolaou
Lysandros Nikolaou added the comment: Thanks Victor for the catch! I've opened a PR that deprecates PyNode_Compile in 3.9. -- ___ Python tracker <https://bugs.python.org/is

<    1   2   3   4   >