[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread Steve Dower
Steve Dower added the comment: Thanks for the contribution! -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread miss-islington
miss-islington added the comment: New changeset 05063fa15c594012e6dc9c2c7a3ea72e7cb933f2 by Miss Islington (bot) in branch '3.10': bpo-46434: Handle missing docstrings in pdb help (GH-30705) https://github.com/python/cpython/commit/05063fa15c594012e6dc9c2c7a3ea72e7cb933f2 -- __

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread miss-islington
Change by miss-islington : -- pull_requests: +28946 pull_request: https://github.com/python/cpython/pull/30759 ___ Python tracker ___ __

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread miss-islington
miss-islington added the comment: New changeset c3ad850b57f92bd7c5515616b59afbd9e1c79538 by Miss Islington (bot) in branch '3.9': bpo-46434: Handle missing docstrings in pdb help (GH-30705) https://github.com/python/cpython/commit/c3ad850b57f92bd7c5515616b59afbd9e1c79538 -- ___

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread miss-islington
Change by miss-islington : -- pull_requests: +28942 pull_request: https://github.com/python/cpython/pull/30755 ___ Python tracker ___ __

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread Steve Dower
Steve Dower added the comment: New changeset 60705cff70576482fea31dcafbf8a37cbb751ea5 by Tom Sparrow in branch 'main': bpo-46434: Handle missing docstrings in pdb help (GH-30705) https://github.com/python/cpython/commit/60705cff70576482fea31dcafbf8a37cbb751ea5 -- __

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-21 Thread miss-islington
Change by miss-islington : -- nosy: +miss-islington nosy_count: 5.0 -> 6.0 pull_requests: +28941 pull_request: https://github.com/python/cpython/pull/30754 ___ Python tracker _

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-20 Thread Steve Dower
Steve Dower added the comment: > the existing check in `do_help` didn't catch this case because > https://docs.python.org/3/library/sys.html#sys.flags only reflects command > line flags, rather than whether or not it was actually optimised. Precisely. Your check is much more appropriate for

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-20 Thread sparrowt
sparrowt added the comment: Gottit thanks for explaining - so the existing check in `do_help` didn't catch this case because https://docs.python.org/3/library/sys.html#sys.flags only reflects command line flags, rather than whether or not it was actually optimised. -- _

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-20 Thread Steve Dower
Steve Dower added the comment: See https://github.com/python/cpython/blob/b04dfbbe4bd7071d46c8688c2263726ea31d33cd/PC/layout/main.py#L256-L289 Basically, the .pyc files in the embeddable distro have been compiled with optimize=2, which is the equivalent of -OO. So yes, docstrings (and assert

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-20 Thread sparrowt
sparrowt added the comment: Thanks, yes CLA should now be working its way through the system. I guess a side question is: is it expected for docstring to have been stripped from the windows embeddable distribution, and how is that done if not with -OO? (I found --without-doc-strings but not

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-19 Thread Steve Dower
Steve Dower added the comment: The PR looks good. I assume you've started the CLA process, so once that clears we'll be fine to merge. -- versions: -Python 3.7, Python 3.8 ___ Python tracker __

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-19 Thread sparrowt
Change by sparrowt : -- keywords: +patch pull_requests: +28901 stage: -> patch review pull_request: https://github.com/python/cpython/pull/30705 ___ Python tracker ___ ___

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-19 Thread sparrowt
sparrowt added the comment: Perhaps we should have a more generic check for `command.__doc__` as it appears this is a case not handled by the existing `sys.flags.optimize >= 2` check? https://github.com/python/cpython/blob/v3.9.10/Lib/pdb.py#L1492-L1496 -- __

[issue46434] pdb help fails with AttributeError when using Windows embeddable package

2022-01-19 Thread sparrowt
New submission from sparrowt : When running python from an embeddable windows zip file such as: https://www.python.org/ftp/python/3.9.10/python-3.9.10-embed-amd64.zip the `help` command within `pdb` is broken due to missing docstrings, as demonstrated below. Python 3.9.10 (tags/v3.9.10:f2f3f5