Ammar Askar added the comment:
Hi Jeffrey, your second solution where you omit `-pie` is almost there. Instead
of modifying the Makefile you can pass `-pie` in `LINKFORSHARED`:
export CFLAGS="-fPIC -fstack-protector-all -D_FORTIFY_SOURCE=2"
export CXXFLAGS="-fPIC -fstac
New submission from Ammar Askar :
Similar to https://bugs.python.org/issue46503 found by the ast.literal_eval
fuzzer
```
>>> f'{<'
python: Parser/string_parser.c:346: fstring_compile_expr: Assertion `*expr_end
== '}' || *expr_end == '!' || *expr_
Ammar Askar added the comment:
See also https://bugs.python.org/issue34398
There is some related work done by Julien there as well:
https://github.com/JulienPalard/pydocsearch
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.
Ammar Askar added the comment:
Thanks for the insight Terry.
I think the functions that accept ints as bools are kind of a red herring:
Booleans were only formally introduced in Python 2.3 [1], thus any functions
that existed before that accepted ints and continued to accept ints for
Ammar Askar added the comment:
What version of Sphinx are you using? As far as I know, Sphinx supports
internationalization for autodoc, so this should be possible.
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/issue38
Ammar Askar added the comment:
When did you try this? For reference, Doc/conf.py on master currently has
`master_doc = 'contents'` and I performed a successful build with Sphinx 2.2.0
a few days ago.
--
nosy: +ammar2
___
Python track
Change by Ammar Askar :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Change by Ammar Askar :
--
nosy: +eryksun
___
Python tracker
<https://bugs.python.org/issue38188>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ammar Askar added the comment:
As the error says:
> Can't connect to HTTPS URL because the SSL module is not available.
Since you built it from source, you should check your build logs, the _ssl
module likely failed to build. You're most probably missing the openss
Ammar Askar added the comment:
Could you provide the output of
gcc --version
and
ld --version
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/issue38
New submission from Ammar Askar :
When dealing with a heap allocated type
(https://docs.python.org/3/c-api/typeobj.html#Py_TPFLAGS_HEAPTYPE /
PyType_FromSpec), if the type has a custom tp_dealloc function then it MUST
decrement the references to the type object itself due to this code block
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +15844
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16248
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Hmm, I think this might be the following gcc/binutils bug:
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=84847
https://sourceware.org/bugzilla/show_bug.cgi?id=20882
This might be a bit of a pain but could you try updating binutils and see if
the problem
Ammar Askar added the comment:
For the control path warning, that can be fixed by just hinting to the compiler
that the function doesn't return like so:
# ifdef __GNUC__
__attribute__ ((noreturn))
# elif defined(_MSC_VER)
__declspec(noreturn)
# endif
static inline
Ammar Askar added the comment:
> What bothers me here is that we apparently changed de facto behavior between
> maintenance releases, in the middle of 3.7's lifecycle, without warning, no
> doubt because we didn't realize it would break third-party packages.
Arguably, I
Ammar Askar added the comment:
Thanks for the report Alexandre, this has to do with issues with negative
numbers in Window's time APIs. There's already a bug open for this, so I've
marked it as a duplicate.
--
nosy: +ammar2
resolution: -> duplicate
stage: ->
Ammar Askar added the comment:
This is a great point Matt, the documentation search is a bit lacking and we're
kind of using https://bugs.python.org/issue34398 and
https://github.com/python/cpython/pull/8773 to track it.
The current idea that Julien, the docs expert, had is to add some
Ammar Askar added the comment:
Changing the title a little to represent that this is now a general improvement
of the docs search. Julien is working to upstream a solution into Sphinx that
will allow any items to be featured prominently on search.
--
title: Docs search does not
Ammar Askar added the comment:
> Somewhat related, I am responding to this through the bugs.python.org
> interface. If I reply directly to the email the tracker sent me, will my
> reply be properly routed to this thread?
Yes, it will :)
The bug tracker allows replies
Ammar Askar added the comment:
Looks like a solid proposal, I especially like the clarity for the 3-argument
call. Often beginners ask about why there's a third argument in pow especially
when teaching RSA and number-theoretic stuff.
Do you mind if I take this on Raymond?
--
Ammar Askar added the comment:
Actually quick question, should a similar change be made for `math.pow` for
consistency's sake?
--
___
Python tracker
<https://bugs.python.org/is
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +15887
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16302
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
I've made a PR, feel free to close it if you'd rather implement this yourself
or this proposal won't be accepted :)
--
___
Python tracker
<https://bugs.pyt
Ammar Askar added the comment:
Here's a little microbenchmark, let me know if there's anything specific you'd
like to see:
Before
==
> python -m pyperf timeit "from test.test_builtin import BuiltinTest; tst =
> BuiltinTest()" -- "tst.test_pow()&q
Ammar Askar added the comment:
Before
==
>python -m pyperf timeit "pow(2, 3)" --duplicate 10
Mean +- std dev: 242 ns +- 19 ns
> python -m pyperf timeit "pow(2.0, 3.0)" --duplicate 10
Mean +- std dev: 197 ns +- 16 ns
After
=
> python -m pyperf t
Ammar Askar added the comment:
math.pow changes removed from PR
--
___
Python tracker
<https://bugs.python.org/issue38237>
___
___
Python-bugs-list mailin
Change by Ammar Askar :
--
resolution: -> duplicate
stage: -> resolved
superseder: -> unittest.TestCase.assertCountEqual is a very misleading name
type: -> behavior
___
Python tracker
<https://bugs.python
Ammar Askar added the comment:
Hey Vitaly, not sure if you're the author of the original bug here:
https://bugs.python.org/issue27071
Could you re-open that so the discussion is kept in one place.
--
nosy: +ammar2
___
Python tracker
&
Change by Ammar Askar :
--
resolution: -> duplicate
stage: -> resolved
status: open -> closed
superseder: -> Docs search should prominently show definitions and glossary
items
___
Python tracker
<https://bugs.python
Ammar Askar added the comment:
Check out this part of the FAQ:
https://docs.python.org/3/faq/programming.html#how-do-i-create-a-multidimensional-list
Essentially, when you did `C = 2*[[]]`, what happens is that the SAME empty
list is placed into C[0] and C[1]. Whereas when you do `M
Ammar Askar added the comment:
For whitespace, the correct way to achieve this using split() with no argument:
>>> print(list("Hello World How Are You?".split()))
['Hello', 'World', 'How', 'Are', 'You?']
>>> prin
Change by Ammar Askar :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Ammar Askar added the comment:
Hmm, I can't recreate this locally:
>>> import tempfile
>>> import os
>>> t = tempfile.TemporaryDirectory()
>>> temp_dir = t.name
>>> os.path.exists(temp_dir)
True
>>> del t
>>>
Ammar Askar added the comment:
> I'd like to help with this, but I don't even know where to start with
> argumentclinic -- any points would be greatly appreciated
Are you asking about argumentclinic in general or something specific to this
bug? If it's something specifi
Ammar Askar added the comment:
This isn't the ternary form of pow(), the documentation there is referring to
the `pow(base, exp, modulus)`.
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/is
Ammar Askar added the comment:
Yeah, that parenthesized bit seems a bit weird: co_stacksize really has nothing
to do with the number of variables, it's just that certain opcodes
(https://docs.python.org/3/library/dis.html#python-bytecode-instructions) push
and pop off the
Change by Ammar Askar :
--
nosy: +skrah, twouters
___
Python tracker
<https://bugs.python.org/issue38318>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ammar Askar added the comment:
I think the key thing you're missing here is that the set() constructor can
take any arbitrary iterable
(https://docs.python.org/3/library/functions.html#func-set). It simply goes
over all the elements inside and adds them all to the set. This is no diff
Ammar Askar added the comment:
If you're trying to get raw bytes, you need to use
print(b'\x80')
what's happening right now is that the '\x80' is treated as a unicode code
point (see https://docs.python.org/3/howto/unicode.html#the-string-type), and
wh
Ammar Askar added the comment:
Any updates on this? Some of the re-organization and simplifications here look
pretty good overall and make the guide way more approachable.
Seeing as how this has been sitting a while and Github has an option allow
maintainers to make edits to PRs. Raymond
Ammar Askar added the comment:
I did a quick search to see what code would break from sys.argv[0] going
relative
intext:"sys.argv[0]" ext:py site:github.com
https://www.google.com/search?q=intext:"sys.argv%5B0%5D"+ext:py+site:github.com
and while most uses of i
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +16451
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/16919
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Thank you for the report Matt!
--
nosy: +ammar2
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.9
___
Python tracker
<https://bugs.python.or
Ammar Askar added the comment:
This is what I get on master, will try 3.7.5+ as noted in the Github issue:
Python 3.9.0a0 (heads/noopt-dirty:f3b170812d, Oct 1 2019, 20:15:53) [MSC
v.1916 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or
Ammar Askar added the comment:
Err...I mean I think this is a dateutil bug rather than in the Python stdlib.
--
___
Python tracker
<https://bugs.python.org/issue38
Ammar Askar added the comment:
It is windows specific, but I don't think this is a dateutil bug rather than
the python stdlib:
Python 3.6.5 (v3.6.5:f59c0932b4, Mar 28 2018, 16:07:46) [MSC v.1900 32 bit
(Intel)] on win32
Type "help", "copyright", "credits"
Ammar Askar added the comment:
Closing, here's the bug in dateutil's repo:
https://github.com/dateutil/dateutil/issues/197
--
resolution: -> third party
stage: -> resolved
status: open -> closed
___
Python tracker
<h
Ammar Askar added the comment:
The notion of equivalent regular expressions does exist but is way more
complicated than the simple example you described.
For example:
r"a|b" is the same as r"[ab]",
r"^aa*$" is the same as r"^a+$"
Implementin
Ammar Askar added the comment:
The documentation for is_private notes:
Returns:
A boolean, True if the address is reserved per RFC 4193.
iana-ipv4-special-registry or iana-ipv6-special-registry.
If we take a look at the iana-ipv4-special-registry then 0.0.0.0/8 does show up
there
Ammar Askar added the comment:
Aah actually I was looking at an older version of the docs, the documentation
now says, "if the address is allocated for private networks" which is actually
misleading. The addresses here aren't all private networks:
https://github.com/pyth
Ammar Askar added the comment:
Just for some more reference points from "production" python web servers:
* gunicorn - 2048
(https://github.com/benoitc/gunicorn/blob/678b326dc030b450717ec505df69863dcd6fb716/docs/source/settings.rst#backlog)
* tornado - 128
(https://github.com/
Change by Ammar Askar :
--
pull_requests: +16572
stage: resolved -> patch review
pull_request: https://github.com/python/cpython/pull/17064
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Opened https://github.com/python/cpython/pull/17064 to fix this. Essentially
it's a tiny little oversight in the back-porting. In the 3.7 branch, we perform
an attribute lookup for `from_param` before the union checking code, so we must
remember to DECR
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +16575
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/17066
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
I like Steven's "truthy value" or "true value" proposal. Another alternative:
"x does not evaluate to true"
"x does not evaluate to false"
--
nosy: +ammar2
___
Python
Ammar Askar added the comment:
I don't think the word "true" is really the issue here. It's the fact that "is"
in this context is ambiguous, is it referring to the English "is" or the python
operator `is`?
--
__
Ammar Askar added the comment:
Will close after
https://buildbot.python.org/all/#/builders?tags=%2Brefleak&tags=%2B3.7 go back
to green.
--
___
Python tracker
<https://bugs.python.org/iss
Change by Ammar Askar :
--
nosy: +gregory.p.smith
___
Python tracker
<https://bugs.python.org/issue38724>
___
___
Python-bugs-list mailing list
Unsubscribe:
Change by Ammar Askar :
--
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.org/issue16575>
___
___
Pyth
Change by Ammar Askar :
--
nosy: +ammar2
nosy_count: 1.0 -> 2.0
pull_requests: +23657
pull_request: https://github.com/python/cpython/pull/20628
___
Python tracker
<https://bugs.python.org/issu
Change by Ammar Askar :
--
pull_requests: +23658
pull_request: https://github.com/python/cpython/pull/20508
___
Python tracker
<https://bugs.python.org/issue43
Ammar Askar added the comment:
Sure thing, I'll work on the backport.
--
___
Python tracker
<https://bugs.python.org/issue43499>
___
___
Python-bugs-list m
Change by Ammar Askar :
--
pull_requests: +23661
pull_request: https://github.com/python/cpython/pull/24896
___
Python tracker
<https://bugs.python.org/issue43
Ammar Askar added the comment:
> We should definitely document the column offset being 1-based
Yes please, I remember working on that issue to make it consistently 1-based a
while ago and I remember that the tooling was relying on 1-based indexes for
column offsets.
--
n
Change by Ammar Askar :
--
nosy: +eric.snow
___
Python tracker
<https://bugs.python.org/issue43601>
___
___
Python-bugs-list mailing list
Unsubscribe:
Ammar Askar added the comment:
Just a note and possible design inspiration, pytest has pretty assertions like
this to allowing you to write unit tests purely with the assert statement and
not unittest's special `assert...` methods:
https://docs.pytest.org/en/stable/ex
Change by Ammar Askar :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Ammar Askar added the comment:
Thank you to Julien for reviewing, we ended up going with our own solution
instead of waiting on Sphinx and I think it looks good :)
--
resolution: -> fixed
stage: patch review -> resolved
status: open -&g
Ammar Askar added the comment:
Thank you Steve and Zachary for reviewing, this warning is in the docs now.
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Change by Ammar Askar :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Change by Ammar Askar :
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Ammar Askar added the comment:
All the modules prescribed in the original bug are now actively being fuzzed,
thank you to Devin for the original work on this and Gregory for reviewing all
these changes.
I'm closing this now, feel free to make a new bug and nosy me in if there are
any
Ammar Askar added the comment:
This has been fixed as part of
https://github.com/python/docsbuild-scripts/pull/99
Thank you to Julien, our Google results are much cleaner now :)
--
resolution: -> fixed
stage: -> resolved
status: open -&g
New submission from Ammar Askar :
As pointed out by Guido in https://bugs.python.org/issue43555, we switched to
making the column offsets for SyntaxError be 1-indexed consistently in
https://bugs.python.org/issue34683
The rationale is explained by Guido and expanded upon in follow up
Change by Ammar Askar :
--
keywords: +patch
pull_requests: +23900
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/25153
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
Aah thanks for pointing that out Terry, I didn't realize f-strings have
different semantics for SyntaxError. Would you mind making a separate issue for
that, I'll look into making the documentation for it clearer after I get a
chance to i
Ammar Askar added the comment:
Marked as a duplicate.
Kaleb, would you mind posting your comment on the original bug #28197?
--
nosy: +ammar2
resolution: -> duplicate
stage: -> resolved
status: open -> closed
superseder: -> Add start and stop parameters to the range
Change by Ammar Askar :
--
keywords: +patch
nosy: +ammar2
nosy_count: 8.0 -> 9.0
pull_requests: +24194
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/25469
___
Python tracker
<https://bugs.python.org/i
Ammar Askar added the comment:
Opened https://github.com/python/cpython/pull/25469 for the first suggestion of
reversing the precedence table order since it seems like a good improvement. I
think the tight binding to weak order is more natural and aside from K&R, the
following o
Ammar Askar added the comment:
Looks like this is the issue described in the comment here:
https://github.com/python/cpython/blob/master/Lib/test/test_enum.py#L3691-L3692
On the first run you have the correct
('CONVERT_STRING_TEST_NAME_A', 5)
but later it
Change by Ammar Askar :
--
pull_requests: +24234
stage: resolved -> patch review
pull_request: https://github.com/python/cpython/pull/25516
___
Python tracker
<https://bugs.python.org/issu
Ammar Askar added the comment:
For what it's worth I think Brett's suggestion of just removing the coverage
build entirely is good too since it seems like no one actually looks at the
results and they take up valuable CI time.
--
nos
Change by Ammar Askar :
--
pull_requests: +24370
pull_request: https://github.com/python/cpython/pull/25679
___
Python tracker
<https://bugs.python.org/issue43
Ammar Askar added the comment:
Note that the `more_itertools` package on pypi also has a partition method.
Shall we close this off given that a recipe is already present and this is
available as part of a popular 3rd-party library?
--
nosy: +ammar2
Ammar Askar added the comment:
Just a little update to this, now that issue34398 is fixed it is possible to
make this more beginner friendly by making sure the right terms have glossary
entries.
As an example, here is a search for "argument" on the latest docs:
https://docs.pytho
Change by Ammar Askar :
--
keywords: +patch
nosy: +ammar2
nosy_count: 4.0 -> 5.0
pull_requests: +24416
stage: -> patch review
pull_request: https://github.com/python/cpython/pull/25724
___
Python tracker
<https://bugs.python.org/i
Ammar Askar added the comment:
See also https://github.com/python/cpython/pull/25679 where we're proposing
just removing the coverage build altogether.
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/is
Ammar Askar added the comment:
Coverage builds have been removed from the CI, closing this now.
--
resolution: -> fixed
stage: patch review -> resolved
status: open -> closed
___
Python tracker
<https://bugs.python.or
Ammar Askar added the comment:
With issue43888 being fixed with the removal of the coverage build, this is now
obsolete. Thanks for pointing out the codecov breach, we will make sure to
follow this if we ever re-add codecov.
--
resolution: -> out of date
stage: -> resolved
Ammar Askar added the comment:
Added Julien to the nosy list, looks like we might be retaining old deleted
docs pages.
--
nosy: +ammar2, mdk
___
Python tracker
<https://bugs.python.org/issue44
Ammar Askar added the comment:
Also, would it make sense to do a clean build (with the html output folder
wiped) in the build-cron to avoid this happening in the future?
--
___
Python tracker
<https://bugs.python.org/issue44
Ammar Askar added the comment:
Seconded, also seeing the same ASAN failure on the fuzzers with a blame for
this commit.
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/issue40
Ammar Askar added the comment:
Can recreate on the latest 3.10 checkout, taking a look.
--
nosy: +ammar2
___
Python tracker
<https://bugs.python.org/issue44
Ammar Askar added the comment:
The segfault seems to be occuring on typeobject.c:1456 during interpreter
finalization:
if (type->tp_flags & Py_TPFLAGS_HEAPTYPE && !(base->tp_flags &
Py_TPFLAGS_HEAPTYPE))
where `type` seems to have already been deallocated.
Ammar Askar added the comment:
The bisect was bizarre to say the least...
It points to commit 11159d2c9d6616497ef4cc62953a5c3cc8454afb
bpo-43080: pprint for dataclass instances (GH-24389)
* Added pprint support for dataclass instances which don't have a custom
__repr__.
which doesn
Ammar Askar added the comment:
Just to thicken the mystery a bit further, if you comment out
import inspect
in dataclasses.py, the error also goes away.
--
___
Python tracker
<https://bugs.python.org/issue44
Ammar Askar added the comment:
Indeed, it's quite a tricky issue so I'm glad it was caught in the beta.
Thank you for the report Anthony. Thanks for tracing the root cause and the fix
Victor and thank you to everyone who he
New submission from Ammar Askar :
The AST currently stores column offsets for characters as byte-offsets.
However, when displaying errors, these byte-offsets must be turned into
character-offsets so that the characters line up properly with the characters
on the line when printed. This is
Change by Ammar Askar :
--
title: Edge case in when error displaying with non-utf8 lines -> Edge case in
compiler when error displaying with non-utf8 lines
___
Python tracker
<https://bugs.python.org/issu
Change by Ammar Askar :
--
nosy: +ammar2
nosy_count: 8.0 -> 9.0
pull_requests: +25524
pull_request: https://github.com/python/cpython/pull/26958
___
Python tracker
<https://bugs.python.org/issu
1 - 100 of 461 matches
Mail list logo