Change by Ammar Askar :
--
pull_requests: +25582
pull_request: https://github.com/python/cpython/pull/27023
___
Python tracker
<https://bugs.python.org/issue43
Change by Ammar Askar :
--
pull_requests: +25582, 25583, 25584
pull_request: https://github.com/python/cpython/pull/27023
___
Python tracker
<https://bugs.python.org/issue43
Change by Ammar Askar :
--
pull_requests: +25582, 25583
pull_request: https://github.com/python/cpython/pull/27023
___
Python tracker
<https://bugs.python.org/issue43
New submission from Ammar Askar :
During the implementation of PEP 657, Terry Jan Reedy pointed out that in the
format method of traceback.StackSummary there are two roles being fulfilled,
there is some logic to handle omitting repeated lines involved in recursive
calls and then the core per
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +25598
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/27038
___
Python tracker
<https://bugs.python.org/issu
Change by Ammar Askar :
--
pull_requests: +25603
pull_request: https://github.com/python/cpython/pull/27047
___
Python tracker
<https://bugs.python.org/issue43
Ammar Askar added the comment:
As per https://bugs.python.org/issue36249 and https://bugs.python.org/issue38351
We don't generally do large-scale changes that are mostly formatting based. We
would prefer that these sort of improvements happen when someone happens to be
touching that
Ammar Askar added the comment:
Brandt, maybe this regression test from a previous tracing bug might be useful
for the test writing:
https://github.com/python/cpython/pull/22026/files#diff-8b73bfc55514d8add8904c5f4d1d24b7b644ebfccba8d846085303577aa94dd6
--
nosy: +ammar2
Ammar Askar added the comment:
Thanks for trying to help Leonardo! You might consider looking for easy issues
on the bug tracker or reviewing open pull requests to help. Definitely take a
look at the dev guide :) https://cpython-devguide.readthedocs.io/fixingissues/
--
resolution
Change by Ammar Askar :
--
nosy: +paul.moore, steve.dower, tim.golden, zach.ware
___
Python tracker
<https://bugs.python.org/issue44624>
___
___
Python-bug
Ammar Askar added the comment:
As reported by Will McGugan on twitter:
Printing may be wrong for some unicode characters like:
Traceback (most recent call last):
File "test.py", line 1, in
x = ("该" / 0) + (1 / 2)
~~^
TypeError: unsupported operand type
Ammar Askar added the comment:
Aah, I won't have time to investigate until Monday. I'll take a look then
unless someone gets to it first :)
--
___
Python tracker
<https://bugs.python.o
Ammar Askar added the comment:
Had some time to look into this. Just to summarize this problem, it deals with
unicode points that are single characters but take up more than the width of a
single character, even with a monospace font [1].
In the examples from above, the Chinese character
Ammar Askar added the comment:
I think this is the previous issue you are talking about Terry.
https://bugs.python.org/issue24665
The correct algorithm is a little more complex than just using
east_asian_widths. Ideally we would like to use the wcwidth function
(https://man7.org/linux/man
Ammar Askar added the comment:
Indeed, and the unicode_width package seems to implement the wcwidth algorithm:
* https://github.com/unicode-rs/unicode-width/blob/master/src/tables.rs#L39-L48
* https://www.cl.cam.ac.uk/~mgk25/ucs/wcwidth.c
https://bugs.python.org/issue12568 is an issue from
Change by Ammar Askar :
--
pull_requests: +25923
pull_request: https://github.com/python/cpython/pull/27390
___
Python tracker
<https://bugs.python.org/issue34
Change by Ammar Askar :
--
versions: +Python 3.11 -Python 3.5, Python 3.6, Python 3.7, Python 3.8, Python
3.9
___
Python tracker
<https://bugs.python.org/issue41
Ammar Askar added the comment:
New changeset ac811f9b5a68ce8756911ef2c8be83b46696018f by da-woods in branch
'main':
bpo-41886: Fix documented type of PyType_Type (GH-22454)
https://github.com/python/cpython/commit/ac811f9b5a68ce8756911ef2c8be83b46696018f
--
nos
Ammar Askar added the comment:
Thank you for spotting this and the patch da-woods!
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
type: -> behavior
versions: +Python 3.9
___
Python tracker
<https://
Ammar Askar added the comment:
New changeset 9d3b6b2472f7c7ef841e652825de652bc8af85d7 by Miss Islington (bot)
in branch '3.9':
[3.9] bpo-34990: Treat the pyc header's mtime in compileall as an unsigned int
(GH-19708)
https://github.com/python
Ammar Askar added the comment:
New changeset 0af681b652c43f0ba90988400ecc1e7934fbfc5d by Miss Islington (bot)
in branch '3.10':
[3.10] bpo-34990: Treat the pyc header's mtime in compileall as an unsigned int
(GH-19708)
https://github.com/python
Change by Ammar Askar :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.10, Python 3.11 -Python 3.5, Python 3.6, Python 3.7, Python
3.8
___
Python tracker
<https://bugs.python.or
Ammar Askar added the comment:
Could you explain your use-case for this feature in a bit more detail? zipfile
is meant to be a relatively high level library to do common tasks such as
reading/writing/listing files.
The use case for `data_offset` proposed here seems to be relatively advanced
Change by Ammar Askar :
--
keywords: +patch
nosy: +ammar2
nosy_count: 1.0 -> 2.0
pull_requests: +27109
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/28774
___
Python tracker
<https://bugs.python.org/i
Change by Ammar Askar :
--
pull_requests: +27111
pull_request: https://github.com/python/cpython/pull/28777
___
Python tracker
<https://bugs.python.org/issue29
Change by Ammar Askar :
--
components: +Library (Lib)
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
type: -> enhancement
versions: +Python 3.11
___
Python tracker
<https://bugs.python
New submission from Ammar Askar :
>From the newly added ast.literal_eval(x) fuzzer, the following string fed to
>ast.literal_eval will cause a null pointer in get_error_line:
\
(\
\
This can be recreated with:
❯ ./python
Python 3.11.0a1+ (heads/fuzz_ast-dirty:6c942a86a4,
New submission from Ammar Askar :
Another parser crash found by the fuzzer:
"\
"(1for c in I,\
\
Recreator:
>>> import ast
>>> ast.literal_eval('"\\\n"(1for c in I,\\\n\\')
[1]17916 segmentation fault ./python
>>> impo
Ammar Askar added the comment:
Looks like the latest versions of icc support this flag:
https://www.intel.com/content/www/us/en/develop/documentation/cpp-compiler-developer-guide-and-reference/top/compiler-reference/compiler-options/compiler-option-details/compiler-diagnostic-options/wunused
Ammar Askar added the comment:
Looks like this got fixed somewhere along between 3.5 and 3.6
---
3.5
---
./python: can't open file 'id:000109': [Errno 2] No such file or directory
=
==28078==ERROR: LeakSani
Change by Ammar Askar :
--
nosy: +rhettinger
___
Python tracker
<https://bugs.python.org/issue38769>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ammar Askar added the comment:
An easier way to understand might be to just write out the generator expression
"manually":
def generator_expression():
for k, v in sorted(self.__dict__.items()):
yield k
return hash(my_generator_expression())
Would yo
Ammar Askar added the comment:
The behavior is documented here:
https://docs.python.org/3.9/library/stdtypes.html#numeric-types-int-float-complex
> Numeric literals containing a decimal point or an exponent sign yield
> floating point numbers.
--
nosy: +
Ammar Askar added the comment:
That would potentially let an invalid usage slip through, since you know what
you're doing, you can suppress the warning with:
warnings.filterwarnings('ignore', category=SyntaxWarning, message='"is" with
a liter
Ammar Askar added the comment:
Just for reference/existing behavior:
>>> class A(collections.abc.Iterable): pass
...
>>> class B:
... def __iter__(): pass
...
>>> issubclass(B, A)
False
>>> issubclass(B, collections.abc.Iterable)
True
>>>
Ammar Askar added the comment:
Just for a quick datapoint: llvm/clang do this by default and you need an
explicit `-fsemantic-interposition` to disable it
http://lists.llvm.org/pipermail/llvm-dev/2016-November/107625.html
It seems to me that the performance gains here really outweigh any
Ammar Askar added the comment:
> Installed the readline module as the arrows do not work when running Python
> interactively.
This is not a suggested way to fix the issue, especially given that the module
you installed is marked as deprecated: https://pypi.org/project/readline/
&
Ammar Askar added the comment:
Do you mean to say we should or shouldn't be raising an error? With Inada-san's
change you get this:
>>> json.loads("true", encoding='utf8')
Traceback (most recent call last):
File "", line 1, in
File "
Ammar Askar added the comment:
Hi Angel, thank you for the report! The file that corresponds to that
documentation is here
https://github.com/python/cpython/blob/master/Doc/library/venv.rst and we'd be
happy to have you make a PR for it :)
--
nosy: +a
Ammar Askar added the comment:
Oh and I think the new link should point here:
https://packaging.python.org/guides/installing-using-pip-and-virtual-environments/#creating-a-virtual-environment
--
___
Python tracker
<https://bugs.python.
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +17512
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/18125
___
Python tracker
<https://bugs.python.org/issu
Change by Ammar Askar :
--
nosy: +vinay.sajip
___
Python tracker
<https://bugs.python.org/issue39407>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ammar Askar added the comment:
Duplicate of https://bugs.python.org/issue25478
See Raymond's open PR here: https://github.com/python/cpython/pull/6574
--
nosy: +ammar2
resolution: -> duplicate
stage: -> resolved
status: open -> closed
superseder: -> Consider a
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +17542
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/18156
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
See also: https://bugs.python.org/issue37645 which discusses changing the
string representation of functions to omit the address.
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/issue39
Ammar Askar added the comment:
Take a look at
https://docs.python.org/3/faq/programming.html#why-am-i-getting-an-unboundlocalerror-when-the-variable-has-a-value
What's happening is that because `a |= x` is treated as an assignment, i.e `a =
a | x`. The compiler treats it as a local var
Ammar Askar added the comment:
This is a common mistake, you'll find the FAQ entry for it here:
https://docs.python.org/3/faq/programming.html#why-are-default-values-shared-between-objects
It's not necessarily a "feature" but default values in functions are only
cr
Ammar Askar added the comment:
Please direct this to https://github.com/python/pythondotorg/issues
This tracker is for issues pertaining to the interpreter.
--
nosy: +ammar2
resolution: -> third party
stage: -> resolved
status: open -&g
Ammar Askar added the comment:
What is the use case for this? You seem to want `enumerate` to return (item,
index) instead of (index, item) when `reverse=True`? You can achieve this
yourself easily a custom generator:
>>> def swapped_enumerate(l):
... for idx, item in en
Change by Ammar Askar :
--
keywords: +newcomer friendly
___
Python tracker
<https://bugs.python.org/issue39417>
___
___
Python-bugs-list mailing list
Unsub
Ammar Askar added the comment:
Note that there was an earlier attempt to make it const
https://github.com/python/cpython/commit/af68c874a6803b4e90b616077a602c0593719a1d
but this was reverted as part of
https://github.com/python/cpython/commit/15e62742fad688b026ba80bf17d1345c4cbd423b
Ammar Askar added the comment:
tuple + tuple is NOT tuple concatenation. It adds each individual member of the
tuple. So for example
(a, b) + (c, d)
results in
(a + c, b + d)
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.
Ammar Askar added the comment:
Are you trying to concatenate a single string? If so keep in mind you need a
trailing comma:
>>> (1, 2) + (3, 4) + ('a',)
(1, 2, 3, 4, 'a')
>>> (1, 2) + (3, 4) + ('a')
Traceback (most recent call last):
File
Change by Ammar Askar :
--
Removed message: https://bugs.python.org/msg362037
___
Python tracker
<https://bugs.python.org/issue39641>
___
___
Python-bugs-list m
Ammar Askar added the comment:
I don't know how common this situation is, the fact that all constructors go to
__init__ here makes it a little tough in this case but normally you'd be able
to tell by the function name.
One potential solution might be to show which file the error
Ammar Askar added the comment:
Can re-create, this is because the **kwargs handling inside unicode format only
performs a lookup when needed
https://github.com/python/cpython/blob/c4cacc8c5eab50db8da3140353596f38a01115ca/Objects/stringlib/unicode_format.h#L393-L424
and doesn't eagerly
Ammar Askar added the comment:
Is this still a problem after you run configure again?
As pointed out in https://devguide.python.org/setup/#unix
> If you decide to Install dependencies, you will need to re-run both configure
> and make.
--
nosy: +
Ammar Askar added the comment:
As pointed out in your other issue:
https://devguide.python.org/setup/#unix
> If you decide to Install dependencies, you will need to re-run both configure
> and make.
--
nosy: +ammar2
resolution: -> not a bug
stage: -> resolved
New submission from Ammar Askar :
I think the Github action for building CPython on Ubuntu is accidentally
caching the built Python files.
If we take a look at: https://github.com/python/cpython/runs/455936632#step:7:1
and
https://github.com/python/cpython/pull/18567/checks?check_run_id
Ammar Askar added the comment:
Aah sorry. This was my mistake, I didn't notice that we're passing `-s`
(silent) to make. It is actually performing the build underneath, just not with
the outputs that get produced form other CIs.
Steve, is there a reason the Github action and Azure
Ammar Askar added the comment:
Sorry about your experience Marco but I think the dev guide is pretty clear on
all these steps (including having to redo `make clean`). You can find some
discussion on the build system here
https://discuss.python.org/t/is-there-prior-discussion-around-the
Change by Ammar Askar :
--
resolution: not a bug ->
stage: resolved ->
status: closed -> open
title: Ubuntu Github action not fully running build process -> Some CIs silence
potentially useful output from make
type: behavior -&
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +17953
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/18583
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Agreed, it's way too noisy. This PR which touches absolutely no code
https://github.com/python/cpython/pull/18583#issuecomment-589432937
claims to "increase coverage by 1.01%."
This doesn't really add much value and only adds noise
Ammar Askar added the comment:
Also just to clarify, the actual coverage build which measures the build. That
is:
https://github.com/python/cpython/blob/d4d17fd2cf69e7c8f4cd03fbf2d575370945b952/.travis.yml#L75-L114
is fine. The build succeeds and the coverage can be seen online at
https
Ammar Askar added the comment:
A good place to start is looking at the blame to find the commit that
introduced it. Which was:
https://github.com/python/cpython/commit/17ab123cf1f0597e7e257c1ce83a6e87b85ffd7b#diff-71666751dc5821f7fc30e9c8138019c9
and if we browse to the state of the file
Ammar Askar added the comment:
The ctypes on pypi is no longer maintained as it was merged by the original
author Thomas Heller into python itself.
This article goes over the history of it a little:
https://blog.python.org/2011/04/thomas-heller-steps-down-as-ctypes.html
Why do you need
Ammar Askar added the comment:
Size of the mode aside, isn't this approach problematic anyway? One platform
could have an entirely different way of signalling ISDIR vs another. In this
case using the host's S_ISDIR for the remote's mode would result in possibly
i
Ammar Askar added the comment:
Thanks for the pointer Brett, I'll submit a PR.
--
___
Python tracker
<https://bugs.python.org/issue39704>
___
___
Pytho
Ammar Askar added the comment:
This has the disadvantage that it won't work for PRs because Github doesn't
make secrets like `${{ secrets.CODECOV_TOKEN }}` available in PRs.
See: https://github.com/codecov/codecov-action/issues/29
--
nos
Ammar Askar added the comment:
On a second look, we currently do this anyway:
https://github.com/python/cpython/blob/374d998b507d34a6c0a3816a163926a8ba0c483f/.github/workflows/coverage.yml#L66-L70
and don't run coverage for PRs so it shouldn
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +18039
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/18680
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Can someone with access check that
https://codecov.io/gh/python/cpython/settings/yaml has the right config? The
latest run after my PR was pushed through still has the status check running :(
--
___
Python tracker
Ammar Askar added the comment:
Looks like it was just cached, the latest pull request didn't get a codecov
comment nor was it ran on the latest commit:
https://github.com/python/cpython/pull/18682
Should this be back-ported so backport pull requests/pull requests to other
vers
Change by Ammar Askar :
--
nosy: +ammar2
nosy_count: 9.0 -> 10.0
pull_requests: +18043
pull_request: https://github.com/python/cpython/pull/18679
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
I can't re-create this locally (tested on master and 3.5.2):
ammar@cowlick:~/cpython$ getent group | grep testgroup
testgroup:x:1008:ammar,root
ammar@cowlick:~/cpython$ ./python
Python 3.9.0a4+ (heads/master:02a4d57, Feb 27 2020, 01:54:32)
[GCC
Ammar Askar added the comment:
Just a quick update, I think this is a codecov bug as per here:
https://community.codecov.io/t/prs-are-commented-even-with-comment-off/941
The yaml configuration doesn't show up here:
https://codecov.io/gh/python/cpython/settings/yaml
While we wait
Ammar Askar added the comment:
Nothing too interesting, here's the stack trace:
/src/cpython3/Modules/_struct.c:487:28: runtime error: load of value 32, which
is not a valid value for type '_Bool'
#0 0x7f50371a7670 in nu_bool cpython3/Modules/_struct.c:487:28
#1 0x
Ammar Askar added the comment:
I believe this was implemented in issue33234
--
nosy: +ammar2
resolution: -> fixed
stage: needs patch -> resolved
status: open -> closed
superseder: -> Improve list() pre-sizing for inputs with k
Ammar Askar added the comment:
Aah, thanks for the catcher Victor. Missed that this was about list
/comprehensions/, not the list constructor.
--
___
Python tracker
<https://bugs.python.org/issue14
Ammar Askar added the comment:
In my original PR I changed it to divmod:
https://github.com/python/cpython/pull/16302/files#diff-986275b975a33c44c0aba973362516fa
--
___
Python tracker
<https://bugs.python.org/issue38
Ammar Askar added the comment:
I don't think that matters. The example is supposed to just serve as an
illustration, it doesn't need to encode the dunder dispatch semantics. The
already existing example doesn't check for a __pow__.
I'd picture it just a
Ammar Askar added the comment:
Instead of noindex maybe the 3.x documentation can be marked as the canonical
one: https://support.google.com/webmasters/answer/139066
This should still allow the old docs to be crawled but emphasize the latest
docs on the website:
> Google Search res
Change by Ammar Askar :
--
pull_requests: +18531
pull_request: https://github.com/python/cpython/pull/19171
___
Python tracker
<https://bugs.python.org/issue38
Ammar Askar added the comment:
As unfortunate as this is, I don't think there's an easy way to solve this
while adhering to descriptors and the attribute lookup model. This is a
consequence of the following rule:
> object.__getattr__(self, name):
> Called when the default
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +18665
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/19303
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Update: opened up https://github.com/python/cpython/pull/19303 as a quick first
pass at implementing this. It works as expected and retains the context from
the original exception just in case it's needed. The code isn't too pretty,
looks like
Ammar Askar added the comment:
As noted in the documentation for os.stat
(https://docs.python.org/3.9/library/os.html#os.stat):
> This function normally follows symlinks; to stat a symlink add the argument
> follow_symlinks=False, or use lstat().
--
nosy: +ammar2
reso
Ammar Askar added the comment:
Just re-posting this here from the open PR. Rust's handling of this seems nice
and beginner friendly:
error: unterminated double quote string
--> src/main.rs:2:19
|
2 | let message = "Hello world
| ___^
3 |
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +18801
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/19446
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Jacob, let's skip the 2.7 part of the report since that is EOL now. For
reference, the full error on the latest Python is:
>>> a, b, c, d = [1, 2, 3]
Traceback (most recent call last):
File "", line 1, in
ValueError: not enough valu
Ammar Askar added the comment:
The reason you're seeing gdb still work even when all Pythons are deleted is
because it embeds a Python interpreter in itself
(https://docs.python.org/3/extending/embedding.html).
This issue is thus out of scope here and belongs on the gdb tracker, but
Change by Ammar Askar :
--
keywords: +patch
nosy: +ammar2
nosy_count: 5.0 -> 6.0
pull_requests: +18878
stage: test needed -> patch review
pull_request: https://github.com/python/cpython/pull/19528
___
Python tracker
<https://bugs.p
Change by Ammar Askar :
--
keywords: +patch
nosy: +ammar2
nosy_count: 1.0 -> 2.0
pull_requests: +18885
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/19537
___
Python tracker
<https://bugs.python.org/i
Change by Ammar Askar :
--
nosy: +ammar2
nosy_count: 4.0 -> 5.0
pull_requests: +18977
pull_request: https://github.com/python/cpython/pull/19651
___
Python tracker
<https://bugs.python.org/issu
Change by Ammar Askar :
--
nosy: +ammar2
nosy_count: 8.0 -> 9.0
pull_requests: +19023
pull_request: https://github.com/python/cpython/pull/19651
___
Python tracker
<https://bugs.python.org/issu
New submission from Ammar Askar :
Looks like checkpyc.py has been broken since PEP 552 was implemented
https://github.com/python/cpython/blob/0e80b561d442769631d66f1cc8813ac30f97378e/Tools/scripts/checkpyc.py#L44-L46
It fails to read the 4 bytes for the `flags` field nor does it handle hash
Change by Ammar Askar :
--
pull_requests: -19023
___
Python tracker
<https://bugs.python.org/issue13645>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Ammar Askar :
--
pull_requests: +19029
pull_request: https://github.com/python/cpython/pull/19708
___
Python tracker
<https://bugs.python.org/issue34
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +19030
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/19709
___
Python tracker
<https://bugs.python.org/issu
101 - 200 of 461 matches
Mail list logo