[issue44826] Specialize STORE_ATTR using PEP 659 machinery.

2021-08-04 Thread Mark Shannon
New submission from Mark Shannon : Add specializations of STORE_ATTR following the pattern of LOAD_ATTR and LOAD_GLOBAL. For this to work well we need https://bugs.python.org/issue44821, otherwise the first assigned to an attribute of any object cannot be specialized. -- messages

[issue44772] Regression in memory use of instances due to dictionary ordering

2021-08-04 Thread Mark Shannon
Mark Shannon added the comment: Raymond, When you say "this was mostly a net win" do you mean the more compact layout or ordering? The compact layout is obviously a win, and doesn't conflict with sharing. The problem is that ordering conflicts with sharing. As long as instance

[issue44821] Instance dictionaries should be created eagerly

2021-08-04 Thread Mark Shannon
New submission from Mark Shannon : Currently, instance dictionaries (__dict__ attribute) are created lazily when the first attribute is set. This is bad for performance for a number of reasons: 1. It causes additional checks on every attribute access. 2. It causes allocation of the object

[issue44814] python 3.9.6 installation installs 0 modules

2021-08-04 Thread Mark Dickinson
Mark Dickinson added the comment: Setting as pending. It looks as though this report represents a misunderstanding of how Python works rather than a bug in Python. -- nosy: +mark.dickinson resolution: -> not a bug status: open -> p

[issue44816] PEP 626 does not explain the handling of constants, at all.

2021-08-03 Thread Mark Shannon
Mark Shannon added the comment: This isn't a bug. Although PEP 626 is not at all clear about this. The key word in the PEP is "executed". Because compound and multi-line constants are constants, the parts of them are not "executed", but computed at compile time. Ha

[issue44206] Add a version number to dict keys.

2021-08-02 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +26051 stage: resolved -> patch review pull_request: https://github.com/python/cpython/pull/27542 ___ Python tracker <https://bugs.python.org/issu

[issue44206] Add a version number to dict keys.

2021-08-02 Thread Mark Shannon
Mark Shannon added the comment: Pablo, There is another failure on that buildbot: test_inspect fails with ^^ File "/home/mark/repos/cpython/Lib/inspect.py", line 1154, in walktree classes.sort(key=attrgetter('__module__',

[issue43596] change assertRaises message when wrong exception is raised

2021-08-01 Thread Mark Dickinson
Mark Dickinson added the comment: I think I understand where the request comes from: in the case where you've changed the exception type that an API is expected to raise, and you've either updated the test to check for the new exception type and missed an update in the business logic

[issue44725] Expose specialization stats in python

2021-07-29 Thread Mark Shannon
Mark Shannon added the comment: New changeset ddd1c418c05da0de978c75dfb3e4a5b8d27e1d9f by Irit Katriel in branch 'main': bpo-44725 : expose specialization stats in python (GH-27192) https://github.com/python/cpython/commit/ddd1c418c05da0de978c75dfb3e4a5b8d27e1d9f -- nosy

[issue44707] runtime error: applying zero offset to null pointer in Objects/listobject.c

2021-07-29 Thread Mark Shannon
Mark Shannon added the comment: New changeset e5c8ddb1714fb51ab1defa24352c98e0f01205dc by Serhiy Storchaka in branch 'main': bpo-44707: Fix an undefined behavior of the null pointer arithmetic (GH-27292) https://github.com/python/cpython/commit/e5c8ddb1714fb51ab1defa24352c98e0f01205dc

[issue44590] Create frame objects lazily when needed

2021-07-29 Thread Mark Shannon
Change by Mark Shannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue44772] Regression in memory use of instances due to dictionary ordering

2021-07-29 Thread Mark Shannon
New submission from Mark Shannon : class C: def __init__(self, cond): if cond: self.a = 1 self.b = 2 c1 = C(True) c2 = C(False) In Python 3.5, the dictionary keys are shared - >>> sys.getsize

[issue44754] Documentation for pop in Built-in Types

2021-07-27 Thread Mark Gluzman
New submission from Mark Gluzman : Python documentation: v.3.9.6 The Python Standard Library >> Built-in Types >> Mutable Sequence Types The table says that 'pop' operation should be written as s.pop([i]) The right way to do it is s.pop(i) -- assignee: docs@pytho

[issue44590] Create frame objects lazily when needed

2021-07-26 Thread Mark Shannon
Mark Shannon added the comment: New changeset ae0a2b756255629140efcbe57fc2e714f0267aa3 by Mark Shannon in branch 'main': bpo-44590: Lazily allocate frame objects (GH-27077) https://github.com/python/cpython/commit/ae0a2b756255629140efcbe57fc2e714f0267aa3

[issue44734] turtle: tests for Vec2D.__abs__ are too strict

2021-07-24 Thread Mark Dickinson
Change by Mark Dickinson : -- keywords: +easy ___ Python tracker <https://bugs.python.org/issue44734> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44728] Testsuite fails on x86_64

2021-07-24 Thread Mark Dickinson
Mark Dickinson added the comment: Looks like the turtle code was changed to use `math.hypot` instead of `** 0.5` in issue #41528. That will likely also fix the test failure, but I've opened #44734 to fix the unnecessarily strict test

[issue44734] turtle: tests for Vec2D.__abs__ are too strict

2021-07-24 Thread Mark Dickinson
Change by Mark Dickinson : -- type: -> behavior versions: +Python 3.10, Python 3.11, Python 3.9 ___ Python tracker <https://bugs.python.org/issue44734> ___ _

[issue44734] turtle: tests for Vec2D.__abs__ are too strict

2021-07-24 Thread Mark Dickinson
New submission from Mark Dickinson : >From the tests for Vec2D.__abs__ in the turtle module we have: def test_distance(self): vec = Vec2D(6, 8) expected = 10 self.assertEqual(abs(vec), expected) vec = Vec2D(0, 0) expected

[issue44728] Testsuite fails on x86_64

2021-07-24 Thread Mark Dickinson
Mark Dickinson added the comment: The test_posix failure appears to be unrelated; I'll let others look into that one. The test_turtle failure looks again like a libm issue, perhaps combined with an overeager test: we're expecting a `** 0.5` operation (which translates to a libm pow call

[issue44728] Testsuite fails on x86_64

2021-07-24 Thread Mark Dickinson
Mark Dickinson added the comment: Extract from the log - from the configure output: > checking for expm1... yes and from the test output > expm10118: expm1(27.0): expected 532048240600.79865, got 532048240600.7976 > (error = 0.00104 (17 ulps); permitted error = 0 or 5 ulps) &g

[issue44651] An unclear definition in Doc/glossary.rst

2021-07-22 Thread Mark Dickinson
Mark Dickinson added the comment: Closing. @StevenHsuYL: Thank you for the contribution! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue44651] An unclear definition in Doc/glossary.rst

2021-07-22 Thread Mark Dickinson
Mark Dickinson added the comment: New changeset c05a790693b3b00ac7cb5b96ad416ca9d8ecb14a by Steven Hsu in branch 'main': bpo-44651: delete entry of "coercion" in Doc/glossary.rst (GH-27226) https://github.com/python/cpython/commit/c05a790693b3b00ac7cb5b96ad416c

[issue42414] unable to document fields of dataclass

2021-07-20 Thread John-Mark Gurney
John-Mark Gurney added the comment: So, just looked at the patch, but it's missing the documentation part of it. Also, yes, you can add the doc as another line, but now that's two lines (yes, you can add semicolons to make it one line, but that might surprise some people). I do request

[issue42414] unable to document fields of dataclass

2021-07-20 Thread John-Mark Gurney
John-Mark Gurney added the comment: Though this suggestion does work, I am not a fan of this solution. The issue is that it separates the doc from the definition. This works well if you have only a field fields in the class, But if you get 10-20+ fields, it moves away the docs and makes

[issue44621] Python 3.9 traces async for/else incorrectly

2021-07-20 Thread Mark Shannon
Mark Shannon added the comment: Not quite trivial, but simple enough :) -- ___ Python tracker <https://bugs.python.org/issue44621> ___ ___ Python-bugs-list m

[issue44621] Python 3.9 traces async for/else incorrectly

2021-07-20 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25800 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27255 ___ Python tracker <https://bugs.python.org/issu

[issue44621] Python 3.9 traces async for/else incorrectly

2021-07-20 Thread Mark Shannon
Mark Shannon added the comment: We can fix this for 3.9. The fix to 3.10 was trivial and should port easily. -- ___ Python tracker <https://bugs.python.org/issue44

[issue44672] Final "pass" is traced incorrectly in 3.9 (and before)

2021-07-19 Thread Mark Shannon
Mark Shannon added the comment: I say no, for a couple of reasons. 1. PEP 626 only applies to 3.10 onwards 2. The bytecode optimizer in 3.9 doesn't understand line numbers. Changing it would be a lot of effort and likely to introduce more bugs than it fixes. Ultimately it is Ɓukasz's

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-19 Thread Mark Shannon
Mark Shannon added the comment: New changeset 37bdd2221ce3607a81d5d7fafc4603d95ca3e8cb by Miss Islington (bot) in branch '3.10': bpo-44645: Check for interrupts on any potentially backwards edge (GH-27216) (GH-27235) https://github.com/python/cpython/commit

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-19 Thread Mark Shannon
Mark Shannon added the comment: New changeset d09c13417890427f829e3df297beb0e27133f8f4 by Mark Shannon in branch 'main': bpo-44645: Check for interrupts on any potentially backwards edge (GH-27216) https://github.com/python/cpython/commit/d09c13417890427f829e3df297beb0e27133f8f4

[issue44651] An unclear definition in Doc/glossary.rst

2021-07-18 Thread Mark Dickinson
Mark Dickinson added the comment: My one worry with removing the entry is that documentation of other projects may be referring to it via intersphinx. If we think this is likely to be a real problem, we could leave a stub entry, but I think it's okay to go ahead and delete

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-17 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25755 pull_request: https://github.com/python/cpython/pull/27216 ___ Python tracker <https://bugs.python.org/issue44

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-17 Thread Mark Shannon
Mark Shannon added the comment: Can we at least include the fix, until we can come up with a better test? That test fails on 3.9 as well as 3.10 and main. With a 3.9 build and the test in #27194: ./python -m test test_threading -R : 0:00:00 load avg: 0.95 Run tests sequentially 0:00:00 load

[issue44651] An unclear definition in Doc/glossary.rst

2021-07-16 Thread Mark Dickinson
Mark Dickinson added the comment: Searching further, none of the uses of "coerce" or "coercion" in the docs seem to be a good match for the definition in this glossary entry. For example, from ipaddress.rst: > By default, attempting to create a network object with ho

[issue44651] An unclear definition in Doc/glossary.rst

2021-07-16 Thread Mark Dickinson
Mark Dickinson added the comment: Agreed that "of the same type" part is confusing. I suspect the intended meaning was that the operation *expects* both arguments to have the same type, so if the actual arguments have different types then they have to be coerced to a c

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-16 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25720 pull_request: https://github.com/python/cpython/pull/27183 ___ Python tracker <https://bugs.python.org/issue44

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-16 Thread Mark Shannon
Mark Shannon added the comment: New changeset 000e70ad5246732fcbd27cf59268185cbd5ad734 by Mark Shannon in branch 'main': bpo-44645: Check for interrupts on any potentially backwards edge. (GH-27167) https://github.com/python/cpython/commit/000e70ad5246732fcbd27cf59268185cbd5ad734

[issue44626] Incorrect tracing of nested if/if/for/yield

2021-07-16 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25719 pull_request: https://github.com/python/cpython/pull/27182 ___ Python tracker <https://bugs.python.org/issue44

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-15 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25703 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/27167 ___ Python tracker <https://bugs.python.org/issu

[issue44645] Python 3.10: Under some trivial circunstances, GIL not released

2021-07-15 Thread Mark Shannon
Mark Shannon added the comment: https://github.com/python/cpython/pull/18334 assumes that since all loops will contain a backwards edge, checking for interrupts on JUMP_ABSOLUTE should be sufficient. However, https://github.com/python/cpython/pull/23743 changed the back edges in while

[issue44622] async-for loops are traced incorrectly in Python 3.10

2021-07-15 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25700 pull_request: https://github.com/python/cpython/pull/27163 ___ Python tracker <https://bugs.python.org/issue44

[issue44622] async-for loops are traced incorrectly in Python 3.10

2021-07-15 Thread Mark Shannon
Mark Shannon added the comment: New changeset f333ab0f2edec26a769ed558263ac662e5475451 by Mark Shannon in branch 'main': bpo-44622: Set line number of END_ASYNC_FOR to match that of iterator. (GH-27160) https://github.com/python/cpython/commit/f333ab0f2edec26a769ed558263ac662e5475451

[issue26280] ceval: Optimize list[int] (subscript) operation similarly to CPython 2.7

2021-07-15 Thread Mark Shannon
Mark Shannon added the comment: New changeset 641345d636320a6fca04a5271fa4c4c5ba3e5437 by Irit Katriel in branch 'main': bpo-26280: Port BINARY_SUBSCR to PEP 659 adaptive interpreter (GH-27043) https://github.com/python/cpython/commit/641345d636320a6fca04a5271fa4c4c5ba3e5437

[issue44622] async-for loops are traced incorrectly in Python 3.10

2021-07-15 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25697 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27160 ___ Python tracker <https://bugs.python.org/issu

[issue44581] Interpreter can execute quickened opcodes in tracing mode

2021-07-15 Thread Mark Shannon
Change by Mark Shannon : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker <https://bugs.python.or

[issue44603] REPL: exit when the user types exit instead of asking them to explicitly type exit()

2021-07-14 Thread Mark Dickinson
Mark Dickinson added the comment: > the confusion that it can cause when there is a mismatch between the > interactive interpreter and noninteractive execution I've witnessed similar confusion when teaching, using IPython. After discovering that you can do In [1]: import pandas

[issue44626] Incorrect tracing of nested if/if/for/yield

2021-07-14 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25680 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27138 ___ Python tracker <https://bugs.python.org/issu

[issue44616] Incorrect tracing for "except" with variable

2021-07-14 Thread Mark Shannon
Mark Shannon added the comment: New changeset 794ff7d505f852dc4e0f94901dc7387afaead3bb by Mark Shannon in branch '3.10': bpo-44616: Mark all clean up instructions at end of named exception block as artificial (GH-27109) (GH-27135) https://github.com/python/cpython/commit

[issue44616] Incorrect tracing for "except" with variable

2021-07-14 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25678 pull_request: https://github.com/python/cpython/pull/27135 ___ Python tracker <https://bugs.python.org/issue44

[issue44616] Incorrect tracing for "except" with variable

2021-07-14 Thread Mark Shannon
Mark Shannon added the comment: New changeset e5862f79c16e28f1ec51d179698739a9b2d8c1d2 by Mark Shannon in branch 'main': bpo-44616: Mark all clean up instructions at end of named exception block as artificial (GH-27109) https://github.com/python/cpython/commit

[issue44625] Python C API version of `fractions` module

2021-07-13 Thread Mark Dickinson
Mark Dickinson added the comment: No, no plans. There are tradeoffs here - the extra speed comes at the expense of increased maintenance burden. (It's certainly much harder to make minor changes and fixes to the decimal module now that it's written in C.) -- nosy: +mark.dickinson

[issue44603] REPL: exit when the user types exit instead of asking them to explicitly type exit()

2021-07-13 Thread Mark Dickinson
Mark Dickinson added the comment: and the related issue: https://bugs.python.org/issue1446372 -- ___ Python tracker <https://bugs.python.org/issue44603> ___ ___

[issue44603] REPL: exit when the user types exit instead of asking them to explicitly type exit()

2021-07-13 Thread Mark Dickinson
Mark Dickinson added the comment: Related 2005 python-dev discussion: https://mail.python.org/archives/list/python-...@python.org/thread/VNGY2DLML4QJUXE73JLVBIH5WFBZNIKG/ -- nosy: +mark.dickinson ___ Python tracker <https://bugs.python.

[issue44570] 3.10.0b3 doesn't trace line events for return in some cases

2021-07-13 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: -25653 ___ Python tracker <https://bugs.python.org/issue44570> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44614] Broken Pipe in Server of Manager in multiprocessing when finalizing, sometimes

2021-07-13 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: -25654 ___ Python tracker <https://bugs.python.org/issue44614> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44616] Incorrect tracing for "except" with variable

2021-07-13 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25655 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27109 ___ Python tracker <https://bugs.python.org/issu

[issue44614] Broken Pipe in Server of Manager in multiprocessing when finalizing, sometimes

2021-07-13 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch nosy: +Mark.Shannon nosy_count: 1.0 -> 2.0 pull_requests: +25654 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27109 ___ Python tracker <https://bugs.python.org/i

[issue44570] 3.10.0b3 doesn't trace line events for return in some cases

2021-07-13 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25653 pull_request: https://github.com/python/cpython/pull/27109 ___ Python tracker <https://bugs.python.org/issue44

[issue44616] Incorrect tracing for "except" with variable

2021-07-13 Thread Mark Shannon
Mark Shannon added the comment: Thanks Ned, you're doing a fantastic job of finding these issues. Sorry for keeping you so busy with this. This one was a latent bug, exposed by fixing https://bugs.python.org/issue44570. -- ___ Python tracker

[issue44593] _randbelow_with_getrandbits may request an unnecessary random bit

2021-07-12 Thread Mark Dickinson
Change by Mark Dickinson : -- resolution: -> duplicate superseder: -> _randbelow_with_getrandbits function inefficient with powers of two ___ Python tracker <https://bugs.python.org/i

[issue44207] Add a version number to Python functions

2021-07-12 Thread Mark Shannon
Mark Shannon added the comment: New changeset 9487a17e3c7cbb3f11c144775cd108601701bb74 by Mark Shannon in branch 'main': bpo-44207: Add an internal version number to function objects. (GH-27078) https://github.com/python/cpython/commit/9487a17e3c7cbb3f11c144775cd108601701bb74

[issue44600] match/case statements trace incorrectly in 3.10.0b4

2021-07-11 Thread Mark Shannon
Change by Mark Shannon : -- nosy: +brandtbucher ___ Python tracker <https://bugs.python.org/issue44600> ___ ___ Python-bugs-list mailing list Unsubscribe:

[issue44593] _randbelow_with_getrandbits may request an unnecessary random bit

2021-07-09 Thread Mark Dickinson
Mark Dickinson added the comment: See #37000 for previous discussion. -- nosy: +mark.dickinson ___ Python tracker <https://bugs.python.org/issue44593> ___ ___

[issue44207] Add a version number to Python functions

2021-07-09 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25628 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27078 ___ Python tracker <https://bugs.python.org/issu

[issue44590] Create frame objects lazily when needed

2021-07-09 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25626 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27077 ___ Python tracker <https://bugs.python.org/issu

[issue44590] Create frame objects lazily when needed

2021-07-09 Thread Mark Shannon
New submission from Mark Shannon : In https://bugs.python.org/issue44032 we moved most of the data in the frame stack, that is the locals, stack, and "specials" (globals, builtins, code etc), from the heap allocated stack to a (mostly) contiguous array in memory. That offered som

[issue44570] 3.10.0b3 doesn't trace line events for return in some cases

2021-07-08 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25621 pull_request: https://github.com/python/cpython/pull/27068 ___ Python tracker <https://bugs.python.org/issue44

[issue44570] 3.10.0b3 doesn't trace line events for return in some cases

2021-07-08 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25620 pull_request: https://github.com/python/cpython/pull/27067 ___ Python tracker <https://bugs.python.org/issue44

[issue44570] 3.10.0b3 doesn't trace line events for return in some cases

2021-07-08 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25619 stage: -> patch review pull_request: https://github.com/python/cpython/pull/27066 ___ Python tracker <https://bugs.python.org/issu

[issue44570] 3.10.0b3 doesn't trace line events for return in some cases

2021-07-08 Thread Mark Shannon
Change by Mark Shannon : -- assignee: -> Mark.Shannon ___ Python tracker <https://bugs.python.org/issue44570> ___ ___ Python-bugs-list mailing list Unsubscrib

[issue44581] Interpreter can execute quickened opcodes in tracing mode

2021-07-08 Thread Mark Shannon
Mark Shannon added the comment: New changeset 514f76bbac386c320a9f3a70797241c612544391 by Mark Shannon in branch 'main': bpo-44581: Don't execute quickened instructions if tracing is on (GH-27064) https://github.com/python/cpython/commit/514f76bbac386c320a9f3a70797241c612544391

[issue44581] Interpreter can execute quickened opcodes in tracing mode

2021-07-08 Thread Mark Shannon
Change by Mark Shannon : -- keywords: +patch pull_requests: +25617 stage: needs patch -> patch review pull_request: https://github.com/python/cpython/pull/27064 ___ Python tracker <https://bugs.python.org/issu

[issue44576] AttributeError: incorrect line identified in Python 3.10

2021-07-08 Thread Mark Shannon
Change by Mark Shannon : -- priority: release blocker -> resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker <https://bugs.python

[issue44576] AttributeError: incorrect line identified in Python 3.10

2021-07-07 Thread Mark Shannon
Mark Shannon added the comment: This is a tricky one. Which is the "correct" line appears to be subjective. I'm inclined to leave it as is, as the tracing sequence seems better in the case of method chaining. See https://github.com/python/cpython/blob/main/Lib/test/test_compi

[issue44581] Interpreter can execute quickened opcodes in tracing mode

2021-07-07 Thread Mark Shannon
New submission from Mark Shannon : This breaks a key invariant of PEP 659. Inserting `assert(cframe.use_tracing == 0);` at the top of all quickened instructions results in several failures when running the test suite. -- assignee: Mark.Shannon components: Interpreter Core messages

[issue44530] Propagate qualname from the compiler unit to code objects for finer grained profiling data

2021-07-07 Thread Mark Shannon
Mark Shannon added the comment: I suspect that the 0.1% increase is noise. The size of importlib.h etc show a small decrease, suggesting that the information content of the code object has *decreased*. After all, the qualname has to stored somewhere and moving it from caller to callee

[issue44560] Unrecognized charset "eucgb2312_cn" in email header for many MUA

2021-07-06 Thread Mark Sapiro
Change by Mark Sapiro : -- versions: +Python 3.7, Python 3.8, Python 3.9 ___ Python tracker <https://bugs.python.org/issue44560> ___ ___ Python-bugs-list mailin

[issue44550] Spam

2021-07-03 Thread Mark Dickinson
Change by Mark Dickinson : -- title: DIGITAL CLASSROOM -> Spam ___ Python tracker <https://bugs.python.org/issue44550> ___ ___ Python-bugs-list mailing list Un

[issue44547] fraction.Fraction does not implement __int__.

2021-07-02 Thread Mark Dickinson
Mark Dickinson added the comment: Thanks, that's helpful. I guess what you _really_ want there is a duck-typed "tell me whether this value is integral and if so give me the corresponding Python int", but that's not currently easily available, so I suppose x == int(x) is the next-

[issue44547] fraction.Fraction does not implement __int__.

2021-07-02 Thread Mark Dickinson
Mark Dickinson added the comment: > As another data point, complex supporting __int__ is a little bit of an > oddity, since all that __int__ method does is raise a TypeError. This was fixed in 3.10: #41974 -- ___ Python tracker

[issue44547] fraction.Fraction does not implement __int__.

2021-07-02 Thread Mark Dickinson
Mark Dickinson added the comment: > Maybe typing.SupportsIndex Apologies: that already exists, of course. It was introduced in #36972. -- ___ Python tracker <https://bugs.python.org/issu

[issue44547] fraction.Fraction does not implement __int__.

2021-07-02 Thread Mark Dickinson
Mark Dickinson added the comment: I'm actually struggling to think of situations where typing.SupportsInt would be useful in its current form: if I'm writing a function that wants to do a duck-typed acceptance of integer-like things (for example because I want my function to work with NumPy

[issue44547] fraction.Fraction does not implement __int__.

2021-07-02 Thread Mark Dickinson
Mark Dickinson added the comment: FWIW, there's some history here: there's a good reason that fractions.Fraction didn't originally implement __int__. Back in the Bad Old Days, many Python functions that expected an integer would accept anything whose type implemented __int__ instead

[issue44546] spam

2021-07-01 Thread Mark Dickinson
Change by Mark Dickinson : -- Removed message: https://bugs.python.org/msg396825 ___ Python tracker <https://bugs.python.org/issue44546> ___ ___ Python-bug

[issue44546] spam

2021-07-01 Thread Mark Dickinson
Change by Mark Dickinson : -- stage: -> resolved status: open -> closed title: ASSESSMENT TOOLS -> spam ___ Python tracker <https://bugs.python.or

[issue44545] spam

2021-07-01 Thread Mark Dickinson
Change by Mark Dickinson : -- Removed message: https://bugs.python.org/msg396822 ___ Python tracker <https://bugs.python.org/issue44545> ___ ___ Python-bug

[issue44545] spam

2021-07-01 Thread Mark Dickinson
Change by Mark Dickinson : -- Removed message: https://bugs.python.org/msg396824 ___ Python tracker <https://bugs.python.org/issue44545> ___ ___ Python-bug

[issue44545] spam

2021-07-01 Thread Mark Dickinson
Change by Mark Dickinson : -- stage: -> resolved status: open -> closed title: ASSESSMENT TOOLS -> spam ___ Python tracker <https://bugs.python.or

[issue44313] Generate LOAD_ATTR+CALL_FUNCTION instead of LOAD_METHOD+CALL_METHOD for imports

2021-06-30 Thread Mark Shannon
Mark Shannon added the comment: New changeset 1b28187a0e3e914ee48de8032cbba0a965dd5563 by Batuhan Taskaya in branch 'main': bpo-44313: generate LOAD_ATTR/CALL_FUNCTION for top-level imported objects (GH-26677) https://github.com/python/cpython/commit/1b28187a0e3e914ee48de8032cbba0a965dd5563

[issue16801] Preserve original representation for integers / floats in docstrings

2021-06-29 Thread Mark Dickinson
Mark Dickinson added the comment: FWIW, the relevant change seems to be this one: https://github.com/sphinx-doc/sphinx/pull/7155 -- ___ Python tracker <https://bugs.python.org/issue16

[issue16801] Preserve original representation for integers / floats in docstrings

2021-06-29 Thread Mark Dickinson
Mark Dickinson added the comment: I suspect the difference is due to a change in the way that Sphinx handles the py:method directive: the rst source for `pathlib.Path.touch` hasn't changed between 3.9 and 3.10, but the 3.9 docs are built with Sphinx 2.4.4, while the 3.10 docs are built

[issue44536] wrong output of np.lcm.reduce(*awg)

2021-06-29 Thread Mark Dickinson
Mark Dickinson added the comment: It looks as though you're reporting an issue with NumPy; this tracker is for the Python core language, which doesn't include NumPy. For NumPy bugs, use the NumPy bug tracker at https://github.com/numpy/numpy/issues. (Though I don't think this _is_ a NumPy

[issue44530] Propagate qualname from the compiler unit to code objects for finer grained profiling data

2021-06-29 Thread Mark Shannon
Mark Shannon added the comment: I think this is a worthwhile improvement. A few comments on this issue and your PR. 1. We already have qualified names on functions and generators and those can be modified by @decorators. In those cases, the code object and the function would disagree. Code

[issue44517] test__xxsubinterpreters: AMD64 Fedora Stable 3.x buildbot aborts at test_still_running

2021-06-28 Thread Mark Shannon
Mark Shannon added the comment: Can someone with fedora reproduce this failure? -- ___ Python tracker <https://bugs.python.org/issue44517> ___ ___ Python-bug

[issue44517] test__xxsubinterpreters: AMD64 Fedora Stable 3.x buildbot aborts at test_still_running

2021-06-28 Thread Mark Shannon
Mark Shannon added the comment: I cannot reproduce this on ubuntu Ubuntu 20.04.2 LTS gcc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0 I've tried these configs: ./configure --with-pydebug ./configure ./configure --enable-optimizations ./configure --enable-optimizations --with-lto I also tried

[issue44517] test__xxsubinterpreters: AMD64 Fedora Stable 3.x buildbot aborts at test_still_running

2021-06-28 Thread Mark Shannon
Mark Shannon added the comment: And today's price for uninformative error message goes to... "AssertionError: 'False' != 'True'" ;) I'm looking into it. -- assignee: -> Mark.Shannon ___ Python tracker <https://bugs.pytho

[issue42197] Disable automatic update of frame locals during tracing

2021-06-27 Thread Mark Shannon
Mark Shannon added the comment: > So, it's expected that `some_module` and `v` would be in the locals at this > point. If a function does not have the local variables `some_module` and `v`, then the change wouldn't be visible to the debugee. So what difference does i

[issue44508] asyncio: document failure mode for loop.call_soon_threadsafe

2021-06-25 Thread Mark Dickinson
New submission from Mark Dickinson : `loop.call_soon_threadsafe` raises `RuntimeError` when the event loop has been closed, but that fact doesn't seem to be documented. It would be useful to document it so that that it's clear that that behaviour is part of the API, and can be depended

[issue44297] Frame with -1 line number

2021-06-24 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25468 pull_request: https://github.com/python/cpython/pull/26891 ___ Python tracker <https://bugs.python.org/issue44

[issue44297] Frame with -1 line number

2021-06-24 Thread Mark Shannon
Change by Mark Shannon : -- pull_requests: +25467 pull_request: https://github.com/python/cpython/pull/26890 ___ Python tracker <https://bugs.python.org/issue44

<    4   5   6   7   8   9   10   11   12   13   >