[issue39762] PyLong_AS_LONG missing from longobject.h

2020-02-26 Thread Enji Cooper
New submission from Enji Cooper : While trying to port python 2 C extension code forward to python 3, I noticed that the python 2.6 PyInt -> PyLong unification lacks a forward-compatible API for PyLong_AS_LONG. I'm not sure if this was intentional, but it is a slightly annoying wicket to

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread David Carlier
David Carlier added the comment: Sorry for the inconveniences. I can reproduce on FreeBSD too if I do not set the DFLAGS env var (because FreeBSD needs architecture bits in addition). What happens when make distclean && export DFLAGS="" && ./configure --with-dtrace ? --

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Miro Hrončok
Miro Hrončok added the comment: aabdeb766b7fa581e7de01f3c953b12792f0736d is the first new commit commit aabdeb766b7fa581e7de01f3c953b12792f0736d Author: David Carlier Date: Tue Jan 28 12:53:32 2020 + bpo-38960: DTrace build fix for FreeBSD. (GH-17451) DTrace build fix for

[issue39530] Documentation about comparisons between numeric types is misleading

2020-02-26 Thread Mark Dickinson
Mark Dickinson added the comment: There's a PR on GitHub. (GH-18615) Terry: I think you've looked at similar sorts of documentation clarifications in the past. Would you have any interest in reviewing this one? -- nosy: +terry.reedy ___ Python

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Miro Hrončok
Miro Hrončok added the comment: I can reproduce this from git and will try to bisect the introducer. -- nosy: +hroncok ___ Python tracker ___

[issue39761] Python 3.9.0a4 fails to build when configured with --with-dtrace

2020-02-26 Thread Marcel Plch
New submission from Marcel Plch : Steps to reproduce: $ wget https://www.python.org/ftp/python/3.9.0/Python-3.9.0a4.tar.xz $ tar xvf Python-3.9.0a4.tar.xz $ cd Python-3.9.0a4 $ ./configure --with-dtrace $ make -j12 /usr/bin/ld: libpython3.9.a(ceval.o): in function `_PyEval_EvalFrameDefault':

[issue39760] ast.FormattedValue.format_spec unnecessarily wrapped in JoinedStr

2020-02-26 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: FYI you can use ast CLI: $ echo 'f"is {x:d}"' | ./python -m ast Module( body=[ Expr( value=JoinedStr( values=[ Constant(value='is ', kind=None), FormattedValue( value=Name(id='x',

[issue39689] test_struct failure on s390x Fedora Clang buildbot

2020-02-26 Thread Charalampos Stratakis
Charalampos Stratakis added the comment: On this loop: for c in [b'\x01', b'\x7f', b'\xff', b'\x0f', b'\xf0']: self.assertTrue(struct.unpack('>?', c)[0]) It fails for the b'\xf0' case -- ___ Python tracker

[issue39759] os.getenv documentation is misleading

2020-02-26 Thread Rémi Lapeyre
Rémi Lapeyre added the comment: I don't really have a preference regarding saying that `default` should be a string or not but the phrase should still be reworded to be less confusing. In typeshed it's documented with a generic type:

[issue39760] ast.FormattedValue.format_spec unnecessarily wrapped in JoinedStr

2020-02-26 Thread Eric V. Smith
Eric V. Smith added the comment: I agree that could probably be simplified, if the format_spec is constant (which it need not be). >>> ast.dump(ast.parse('f"is {x:d}"')) "Module(body=[Expr(value=JoinedStr(values=[Str(s='is '), FormattedValue(value=Name(id='x', ctx=Load()), conversion=-1,

[issue39759] os.getenv documentation is misleading

2020-02-26 Thread Andrew Svetlov
Andrew Svetlov added the comment: I consider a free type for the default as an implementation detail, not the encouraged approach. Since the value is always a string, using the same type for the default sounds like a sane design for me. -- nosy: +asvetlov

[issue39750] UnicodeError becomes unpicklable if data is appended to args

2020-02-26 Thread João Eiras
João Eiras added the comment: Hi. It's perfectly fine for classes to have their public APIs and intended uses. But then unpickling would be the worst place to complain, specially when running 40 parallel processes while an unhandled stacktrace appears between a couple hundred thousand lines

[issue34788] ipaddress module fails on rfc4007 scoped IPv6 addresses

2020-02-26 Thread Andrew Svetlov
Change by Andrew Svetlov : -- resolution: -> fixed stage: patch review -> resolved status: open -> closed ___ Python tracker ___

[issue34788] ipaddress module fails on rfc4007 scoped IPv6 addresses

2020-02-26 Thread miss-islington
miss-islington added the comment: New changeset 21da76d1f1b527d62b2e9ef79dd9aa514d996341 by opavlyuk in branch 'master': bpo-34788: Add support for scoped IPv6 addresses (GH-13772) https://github.com/python/cpython/commit/21da76d1f1b527d62b2e9ef79dd9aa514d996341 -- nosy:

[issue16487] Allow ssl certificates to be specified from memory rather than files.

2020-02-26 Thread Lord Anton Hvornum
Lord Anton Hvornum added the comment: I agree with Jan-Philip Gehrcke, would have been nice to have had this. Pretty pissed reading through this ancient issue. In regards to how people treat other volunteers: We're all working for free, and I think expectations from people with

[issue39760] ast.FormattedValue.format_spec unnecessarily wrapped in JoinedStr

2020-02-26 Thread Ilya Kamenshchikov
New submission from Ilya Kamenshchikov : Most usual usecase for format_spec is to specify it as a constant, that would be logical to represent as ast.Constant. However, ast.parse wraps value of ast.FormattedValue.format_spec into a JoinedStr with a single constant value, as can be seen from

[issue30064] BaseSelectorEventLoop.sock_{recv, sendall}() don't remove their callbacks when canceled

2020-02-26 Thread Andrew Svetlov
Andrew Svetlov added the comment: This is a very interesting question. In asyncio, task cancellation is not executed on `task.cancel()` call immediately but the task is *marked* for cancellation. The actual cancellation requires a context switch (await asyncio.sleep(0) or similar) to

[issue39759] os.getenv documentation is misleading

2020-02-26 Thread Andrei Daraschenka
Change by Andrei Daraschenka : -- keywords: +patch nosy: +dorosch nosy_count: 2.0 -> 3.0 pull_requests: +18024 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18668 ___ Python tracker

[issue39759] os.getenv documentation is misleading

2020-02-26 Thread Rémi Lapeyre
New submission from Rémi Lapeyre : The documentation states that "*key*, *default* and the result are str." at https://github.com/python/cpython/blame/3.8/Doc/library/os.rst#L224 but either I'm missing something or it's not actually true: $ python -c 'import os; print(type(os.getenv("FOO")))'

[issue39758] StreamWriter.wait_closed() can hang indefinitely.

2020-02-26 Thread François Voron
Change by François Voron : -- nosy: +François Voron title: StreamWriter.wait_closed() can hang indefinately. -> StreamWriter.wait_closed() can hang indefinitely. ___ Python tracker

[issue39758] StreamWriter.wait_closed() can hang indefinately.

2020-02-26 Thread Tom Christie
New submission from Tom Christie : Raising an issue that's impacting us on `httpx`. It appears that in some cases SSL unwrapping can cause `.wait_closed()` to hang indefinately. Trio are particularly careful to work around this case, and have an extensive comment on it:

[issue39757] EmailMessage wrong encoding for international domain

2020-02-26 Thread Julien Castiaux
Change by Julien Castiaux : -- keywords: +patch pull_requests: +18023 stage: -> patch review pull_request: https://github.com/python/cpython/pull/18667 ___ Python tracker ___

[issue39757] EmailMessage wrong encoding for international domain

2020-02-26 Thread Julien Castiaux
New submission from Julien Castiaux : Affected python version: 3.5 and above (did test them all except 3.9) Steps to reproduce: from mail.message import EmailMessage from mail.policy import SMTP msg = EmailMessage(policy=SMTP) msg['To'] = 'Joe ' # notice the é in the domain

[issue39748] PyScripter could not find Python 3.8 64 bits

2020-02-26 Thread Eric V. Smith
Eric V. Smith added the comment: I'm going to close this. If you have more information that shows it's a bug in Python, we can re-open it. -- resolution: -> not a bug stage: -> resolved status: open -> closed ___ Python tracker

<    1   2