[issue43283] IDLE: Explain print slowness and speedup method

2021-02-20 Thread miss-islington


Change by miss-islington :


--
pull_requests: +23387
pull_request: https://github.com/python/cpython/pull/24608

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43283] IDLE: Explain print slowness and speedup method

2021-02-20 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 2.0 -> 3.0
pull_requests: +23386
pull_request: https://github.com/python/cpython/pull/24607

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43283] IDLE: Explain print slowness and speedup method

2021-02-20 Thread Terry J. Reedy


Terry J. Reedy  added the comment:


New changeset 4cf7bb8e22bf37e6d65bf4cb5618d09c4a8ad612 by Terry Jan Reedy in 
branch 'master':
bpo-43283: Rearrange some IDLE doc paragraphs. (GH-24604)
https://github.com/python/cpython/commit/4cf7bb8e22bf37e6d65bf4cb5618d09c4a8ad612


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43278] unnecessary leading '\n' from Py_GetCompiler() when build with different complier

2021-02-20 Thread Joseph Shen


Change by Joseph Shen :


--
title: Inconsistent behavior of Py_GetCompiler() -> unnecessary leading '\n'  
from Py_GetCompiler() when build with different complier

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43278] Inconsistent behavior of Py_GetCompiler()

2021-02-20 Thread Joseph Shen


Change by Joseph Shen :


--
keywords: +patch
pull_requests: +23384
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/24606

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43269] [sqlite3] Clean up function scoping

2021-02-20 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +23383
pull_request: https://github.com/python/cpython/pull/24605

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43269] [sqlite3] Clean up function scoping

2021-02-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Serhiy also mentioned that marking functions definitions with the extern 
keyword is not very common in the CPython source base. 
https://github.com/python/cpython/pull/24578#discussion_r579506678

I suggest cleaning up those as well, while we're at it.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43283] IDLE: Explain print slowness and speedup method

2021-02-20 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
keywords: +patch
pull_requests: +23382
pull_request: https://github.com/python/cpython/pull/24604

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43283] IDLE: Explain print slowness and speedup method

2021-02-20 Thread Terry J. Reedy


New submission from Terry J. Reedy :

https://stackoverflow.com/questions/66286367/why-is-my-function-faster-than-pythons-print-function-in-idle
 had some tests of printing speed that showed that print in IDLE can be much 
slower than in REPL.  I did further tests that showed than combining chunks and 
lines into a single string can erase most of the difference.

For easier review, the first patch just rearranges current paragraphs to bring 
together those dealing with 2 processes and sys.stdxxx.  Some are also 
re-wrapped. The second patch will contain just the new paragraph.

--
assignee: docs@python -> terry.reedy

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43283] IDLE: Explain print slowness and speedup method

2021-02-20 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
assignee: docs@python
components: Documentation, IDLE
nosy: docs@python, terry.reedy
priority: normal
severity: normal
stage: patch review
status: open
title: IDLE: Explain print slowness and speedup method
type: enhancement
versions: Python 3.10, Python 3.8, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27646] doc: yield from expression can be any iterable

2021-02-20 Thread Terry J. Reedy


Change by Terry J. Reedy :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.8, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27640] Add --disable-test-modules configure option to not build nor install tests

2021-02-20 Thread Eli Schwartz


Eli Schwartz  added the comment:

I filed issue43282 for this.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43282] Add split install targets to install tests separately from lib

2021-02-20 Thread Eli Schwartz


New submission from Eli Schwartz :

cf. https://bugs.python.org/issue27640#msg386758

Carrying on from the addition of --disable-test-modules, I would find it 
convenient to be able to still provide the tests, but install them separately. 
The end result would be two distro packages, one slim package that does not 
include the test modules by default, and one package that adds in the test 
modules for people that need it.

This is currently possible via running the install step twice and some hacky 
shell globbing to delete unneeded files from each install.

Some sort of libinstall/testinstall target split target would be less hacky, 
and not require checking if the list of test modules is up to date. So I'd 
consider it nice to have. :)

--
components: Build
messages: 387438
nosy: eschwartz
priority: normal
severity: normal
status: open
title: Add split install targets to install tests separately from lib
type: enhancement
versions: Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27646] doc: yield from expression can be any iterable

2021-02-20 Thread miss-islington


miss-islington  added the comment:


New changeset 7cc58890b3c16c28360a9abe030258426e89fec1 by Miss Islington (bot) 
in branch '3.9':
bpo-27646: Say that 'yield from' expression can be any iterable (GH-24595)
https://github.com/python/cpython/commit/7cc58890b3c16c28360a9abe030258426e89fec1


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43166] Unused letters in Windows-specific pragma optimize

2021-02-20 Thread David Bolen


Change by David Bolen :


--
nosy: +db3l

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27646] doc: yield from expression can be any iterable

2021-02-20 Thread miss-islington


miss-islington  added the comment:


New changeset 089a21f7429a3fd3cf78e3779df724757d346d19 by Miss Islington (bot) 
in branch '3.8':
bpo-27646: Say that 'yield from' expression can be any iterable (GH-24595)
https://github.com/python/cpython/commit/089a21f7429a3fd3cf78e3779df724757d346d19


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27646] doc: yield from expression can be any iterable

2021-02-20 Thread miss-islington


Change by miss-islington :


--
nosy: +miss-islington
nosy_count: 2.0 -> 3.0
pull_requests: +23380
pull_request: https://github.com/python/cpython/pull/24602

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27646] doc: yield from expression can be any iterable

2021-02-20 Thread miss-islington


Change by miss-islington :


--
pull_requests: +23381
pull_request: https://github.com/python/cpython/pull/24603

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue27646] doc: yield from expression can be any iterable

2021-02-20 Thread Terry J. Reedy


Terry J. Reedy  added the comment:


New changeset 2f9ef514fb24b6a95bd3272885f197752810c107 by Terry Jan Reedy in 
branch 'master':
bpo-27646: Say that 'yield from' expression can be any iterable (GH-24595)
https://github.com/python/cpython/commit/2f9ef514fb24b6a95bd3272885f197752810c107


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43280] additional argument for str.join()

2021-02-20 Thread Steven D'Aprano


Change by Steven D'Aprano :


--
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43280] additional argument for str.join()

2021-02-20 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

Looking more closely, I think that the semantics are to concatenate the extra 
argument to the second-last item:

", ".join(["a", "b", "c"])
# -> "a, b, c"

", ".join(["a", "b", "c"], ", and")
# -> "a, b, and, c"

which would be the same as:

", ".join(["a", "b, and", "c"])
# -> "a, b, and, c"


I'm not sure how this is useful. In English, there should never be a comma 
after the "and", and there possibly shouldn't be a comma after the "b" either, 
depending on context.

# Should be: "a, b and c" or "a, b, and c"

See the Oxford or serial comma:

https://thegrammargirls.wordpress.com/tag/oxford-comma/


I'm going to close this feature request. It's too specific and the semantics 
don't seem to be very useful. But if you would still like to propose this, or a 
similar change, please discuss it first either on the Python-Ideas mailing list:

https://mail.python.org/archives/list/python-id...@python.org/


or at the Ideas topic on

https://discuss.python.org


so that we can determine the required semantics and get a sense for how useful 
it would be in general.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43281] Walrus comprehension rebind checking behavior

2021-02-20 Thread Saiyang Gou


New submission from Saiyang Gou :

# test

PEP 572 disallows walrus use cases such as `[(i := 1) for i in [1]]`, because 
`for i` implies that `i` is local to the comprehension but `(i := 1)` implies 
that `i` is "exported", which is a contradiction. However, I noticed the 
following behavior both in 3.8 and 3.9:

>>> [(a := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'a'
>>> [(b := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'b'
>>> [(c := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'c'
>>> [(d := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'd'
>>> [(e := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'e'
>>> [(f := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'f'
>>> [(g := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'g'
>>> [(h := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
  File "", line 1
SyntaxError: assignment expression cannot rebind comprehension iteration 
variable 'h'
>>> [(i := 1) for a, (*b, c[d+e::f(g)], h.i) in [1]]
Traceback (most recent call last):
  File "", line 1, in 
  File "", line 1, in 
TypeError: cannot unpack non-iterable int object

Among all of these assignment expressions, only the assignment to `i` 
(attribute name) is allowed. However, in my understanding, only `a` and `b` 
should be disallowed for assignment. This comprehension example only creates 
two new variables, `a` and `b`, which are local to the comprehension. 
Assignment expressions assigning to `c`, `d`, `e`, `f`, `g` and `h` should be 
allowed. `c` and `h` are already in the outer scope. `d`, `e`, `f` and `g` are 
just names inside the expression in the subscript part. They are not 
"comprehension iteration variables" and not local to the comprehension.

The same behavior is also observed when detecting inner loop variable rebinding 
outer loop assignment expression targets:

>>> [i for i in range(5) if (j := 0) for k[j + 1] in range(5)]
  File "", line 1
SyntaxError: comprehension inner loop cannot rebind assignment expression 
target 'j'

--
messages: 387433
nosy: gousaiyang
priority: normal
severity: normal
status: open
title: Walrus comprehension rebind checking behavior
type: behavior
versions: Python 3.10, Python 3.8, Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43269] [sqlite3] Clean up function scoping

2021-02-20 Thread Berker Peksag


Berker Peksag  added the comment:


New changeset bf838a6e7eec2063a17c7c33dfa94afeef116f36 by Erlend Egeberg 
Aasland in branch 'master':
bpo-43269: Clean up sqlite3 file scope (GH-24578)
https://github.com/python/cpython/commit/bf838a6e7eec2063a17c7c33dfa94afeef116f36


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue19073] Inability to specific __qualname__ as a property on a class instance.

2021-02-20 Thread Lewis Gaul


Lewis Gaul  added the comment:

This would also be useful for me - I just hit this same problem. If someone 
could give some guidance on how to make this change I'd be happy to put up a PR.

--
nosy: +LewisGaul

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43280] additional argument for str.join()

2021-02-20 Thread Steven D'Aprano


Steven D'Aprano  added the comment:

Python 3.9 is in feature freeze, this couldn't be added before 3.10 now.

You have:

", ".join(["a", "b", "c"], ", and ")

outputing this:

"a, b, and, c"

So what are the semantics of this additional argument? To insert it before the 
last item?

--
nosy: +steven.daprano
versions: +Python 3.10 -Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42643] http.server does not support HTTP range requests

2021-02-20 Thread David Bordeynik


David Bordeynik  added the comment:

I would appreciate a code review - thank you

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43251] [sqlite3] sqlite3_column_name() failures should raise MemoryError

2021-02-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

"SELECT 1" yields "1" as column name.
"SELECT <...> AS N" yields "N" as column name.
"SELECT NULL" yields "NULL" as column name.

We can't set the column name via the API, so that's pretty much it (implicit 
name or explicit through the AS keyword). As long as sqlite3_prepare_v2() 
returned SQLITE_OK, it seems that SQLite assures we've got a valid column name.

As far as I can sqlite3_column_name() returns NULL if:
1) The first parameter (stmt) is NULL
2) The second parameter is out of bounds
3) Memory error
4) No column name is set (SQLite bug)

We've got 1) and 2) covered. SQLite has a pretty good code coverage, so I'd say 
4) is unlikely.

What do you think?

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43280] additional argument for str.join()

2021-02-20 Thread Dennis Sweeney


Dennis Sweeney  added the comment:

This seems like a very specific use case. Too specific IMO for a method on all 
string objects for anyone using Python anywhere in the world. Why not just 
write a function like this?

def my_join(strings, sep=", ", last_sep=", and "):
strings = list(strings)
return sep.join(strings[:-1]) + last_sep + strings[-1]

>>> my_join(["one", "two", "three"])
'one, two, and three'

--
nosy: +Dennis Sweeney

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43280] additional argument for str.join()

2021-02-20 Thread Fabian Brinkmann


Change by Fabian Brinkmann :


--
title: addition argument for str.join() -> additional argument for str.join()

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43280] addition argument for str.join()

2021-02-20 Thread Fabian Brinkmann


New submission from Fabian Brinkmann :

It would be nice to have an additional argument for str.join() so this

", ".join(["a", "b", "c"], ", and ")

would output

"a, b, and, c"

--
components: Library (Lib)
messages: 387426
nosy: f-brinkmann
priority: normal
severity: normal
status: open
title: addition argument for str.join()
type: enhancement
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue41837] Upgrade installers to OpenSSL 1.1.1j

2021-02-20 Thread Ned Deily

Ned Deily  added the comment:

1.1.1j was issued earlier this week and, from browsing the source, it appears 
that this fix is included (it's not mentioned as a major issue) along with 
other fixes.  So I assume we just need to update the installers to use 1.1.1j. 
The question is then do need to push updated installers for 3.9.x and 3.8.x? 
Setting to "deferred blocker" pending a decision.

@Christian?  @Łukasz?

--
priority: high -> deferred blocker
title: Upgrade installers to OpenSSL 1.1.1i -> Upgrade installers to OpenSSL 
1.1.1j

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43279] Update code taken from Keccak Code Package

2021-02-20 Thread Christian Heimes


Christian Heimes  added the comment:

Please hold off. Once PEP 644 gets accepted, I'm going to remove our copy of 
Keccak and _sha3 module entirely.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42981] Error messages raised by _hashlib_scrypt_impl() are slightly misleading

2021-02-20 Thread Illia Volochii


Change by Illia Volochii :


--
resolution:  -> wont fix
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43277] Add PySet_CheckExact

2021-02-20 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43279] Update code taken from Keccak Code Package

2021-02-20 Thread Illia Volochii


Change by Illia Volochii :


--
keywords: +patch
pull_requests: +23379
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/24601

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue34013] Inconsistent SyntaxError for print

2021-02-20 Thread Lysandros Nikolaou


Change by Lysandros Nikolaou :


--
nosy: +lys.nikolaou

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43277] Add PySet_CheckExact

2021-02-20 Thread Pablo Galindo Salgado


Pablo Galindo Salgado  added the comment:


New changeset d439fb304ca3098aab1ed0a314996f9d29347b21 by Pablo Galindo in 
branch 'master':
bpo-43277: Add PySet_CheckExact to the C-API (GH-24598)
https://github.com/python/cpython/commit/d439fb304ca3098aab1ed0a314996f9d29347b21


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43279] Update code taken from Keccak Code Package

2021-02-20 Thread Illia Volochii


New submission from Illia Volochii :

There were some updates to the Keccak package (https://github.com/XKCP/XKCP) 
since it was integrated in CPython initially.

I will submit a pull request soon

--
components: Extension Modules
messages: 387422
nosy: christian.heimes, illia-v
priority: normal
severity: normal
status: open
title: Update code taken from Keccak Code Package
type: enhancement
versions: Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43265] [sqlite3] Improve backup error handling

2021-02-20 Thread Berker Peksag


Change by Berker Peksag :


Removed file: https://bugs.python.org/file49823/DOC-20200420-WA

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43265] [sqlite3] Improve backup error handling

2021-02-20 Thread Berker Peksag


Berker Peksag  added the comment:

> 3.9, I presume?

Yes, I was going too fast :)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43276] add `false` and `true` keywords (aliases) for True and False

2021-02-20 Thread parsa mpsh


parsa mpsh  added the comment:

I sent a PR: https://github.com/python/cpython/pull/24600

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43265] [sqlite3] Improve backup error handling

2021-02-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Regarding 1: After thinking about it, I see nothing wrong with raising 
ValueError error. No need to change current behaviour.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43265] [sqlite3] Improve backup error handling

2021-02-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

3.9, I presume? Yeah, I guess so.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43276] add `false` and `true` keywords (aliases) for True and False

2021-02-20 Thread parsa mpsh


Change by parsa mpsh :


--
pull_requests: +23378
pull_request: https://github.com/python/cpython/pull/24600

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43278] Inconsistent behavior of Py_GetCompiler()

2021-02-20 Thread Joseph Shen


New submission from Joseph Shen :

The function Py_GetCompiler() return the version info with a leading '\n' when 
build with GCC/clang, while without this on other compilers. This inconsistent 
make the REPL print the 'welcome message' quit different, which I think is not 
we expect.
>From the snapshot images, we can see, when compiler with MSVC, the 'welcome 
>message' has two lines, but with GCC it is 3 lines, which two lines is what 
>expected.
Patch is given in the github rp, thanks for review.

--
components: C API
files: explorer_lN3ARB7gnj.png
messages: 387417
nosy: josephsmeng
priority: normal
pull_requests: 23377
severity: normal
status: open
title: Inconsistent behavior of Py_GetCompiler()
type: behavior
Added file: https://bugs.python.org/file49824/explorer_lN3ARB7gnj.png

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43265] [sqlite3] Improve backup error handling

2021-02-20 Thread Berker Peksag


Berker Peksag  added the comment:

I'd even consider a cryptic error message a minor usability bug and backport it 
to at least 3.10.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43276] add `false` and `true` keywords (aliases) for True and False

2021-02-20 Thread parsa mpsh


parsa mpsh  added the comment:

Also adding them as builtin keywords will make it easier than setting them as 
variables. in this method, we should define them everywhere, but in builtin 
type its easy.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43277] Add PySet_CheckExact

2021-02-20 Thread Pablo Galindo Salgado


Change by Pablo Galindo Salgado :


--
keywords: +patch
pull_requests: +23376
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/24598

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43276] add `false` and `true` keywords (aliases) for True and False

2021-02-20 Thread parsa mpsh


parsa mpsh  added the comment:

Yes i know this. but why not adding this builtin? this will be very nice!

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43277] Add PySet_CheckExact

2021-02-20 Thread Pablo Galindo Salgado


New submission from Pablo Galindo Salgado :

For some mysterious reason we have PySet_Check, PyFrozenSet_Check, 
PyAnySet_Check, PyAnySet_CheckExact and PyFrozenSet_CheckExact but no 
PySet_CheckExact

--
components: C API
messages: 387413
nosy: pablogsal
priority: normal
severity: normal
status: open
title: Add PySet_CheckExact
versions: Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43276] add `false` and `true` keywords (aliases) for True and False

2021-02-20 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

You can do it yourself in your script. It is just two lines of code:

true = True
false = False

And it works in all Python versions!

--
nosy: +serhiy.storchaka
resolution:  -> rejected
stage:  -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43276] add `false` and `true` keywords (aliases) for True and False

2021-02-20 Thread parsa mpsh


New submission from parsa mpsh :

I wanna add `true` and `false` aliases for `True` and `False` keywords.
Currently my patch is ready and i will send it as a pull request.

--
messages: 387411
nosy: parsampsh
priority: normal
severity: normal
status: open
title: add `false` and `true` keywords (aliases) for True and False
type: enhancement
versions: Python 3.10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42128] Structural Pattern Matching (PEP 634)

2021-02-20 Thread Daniel Moisset


Daniel Moisset  added the comment:

Note: I will NOT write something for "What's New in 3.10" seeing that's in 
progress

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42128] Structural Pattern Matching (PEP 634)

2021-02-20 Thread Daniel Moisset


Daniel Moisset  added the comment:

Fyi, I'm looking into the documentation. I think I can have something basic for 
the middle of this week, so it should be ok for March 1st.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42990] Improve the C code for calling Python code: _PyEval_EvalCode()

2021-02-20 Thread STINNER Victor


STINNER Victor  added the comment:


New changeset 46496f9d12582bf11f4911ad0f23315d6f277907 by Victor Stinner in 
branch 'master':
bpo-42990: Functions inherit current builtins (GH-24564)
https://github.com/python/cpython/commit/46496f9d12582bf11f4911ad0f23315d6f277907


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43275] [venv] Add a `.gitignore` file with content `*` in the root folder generated by venv module

2021-02-20 Thread star2000


star2000  added the comment:

I still think the advantages outweigh the disadvantages.

--
components: +Library (Lib)
resolution:  -> duplicate
stage:  -> resolved
status: open -> closed
title: Add a `.gitignore` file with content `*` in the root folder generated by 
venv module -> [venv] Add a `.gitignore` file with content `*` in the root 
folder generated by venv module
type:  -> enhancement

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43275] Add a `.gitignore` file with content `*` in the root folder generated by venv module

2021-02-20 Thread Karthikeyan Singaravelan


Karthikeyan Singaravelan  added the comment:

This seems to be a duplicate of https://bugs.python.org/issue39236

--
nosy: +brett.cannon, vinay.sajip, xtreak

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43251] [sqlite3] sqlite3_column_name() failures should raise MemoryError

2021-02-20 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

Investigate where column names are initialized and whether is it possible to 
get them NULLs. The array of column names is filled with NULLs when initialized 
and later it is filled with references to strings. I am wondering whether there 
is a gap between this which lefts some column names as NULLs.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43275] Add a `.gitignore` file with content `*` in the root folder generated by venv module

2021-02-20 Thread star2000


New submission from star2000 :

In this way, you don't need to add `venv` to `.gitignore` at the root of each 
project.

--
messages: 387404
nosy: star2000
priority: normal
severity: normal
status: open
title: Add a `.gitignore` file with content `*` in the root folder generated by 
venv module

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43251] [sqlite3] sqlite3_column_name() failures should raise MemoryError

2021-02-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

That's inside sqlite3_value_text() and friends, then? Let's investigate further 
before concluding.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43251] [sqlite3] sqlite3_column_name() failures should raise MemoryError

2021-02-20 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:

It also returns NULL if the column name was not set (is it even possible?).

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue42990] Improve the C code for calling Python code: _PyEval_EvalCode()

2021-02-20 Thread STINNER Victor


STINNER Victor  added the comment:

> Regarding the text in What's New 3.10 about this at 
> https://docs.python.org/dev/whatsnew/3.10.html#other-language-changes, I 
> recommend adding there that func.__builtins__ is initialized from 
> globals["__builtins__"], if it exists, else from the frame's builtins, when 
> the function object is created; like you state in 
> https://github.com/python/cpython/pull/24564.

Good idea, I updated my PR.

> Or perhaps make one of these paragraphs refer to the other for details, since 
> they are duplicate mentions of the same behavior change (once the latter PR 
> lands).

IMO it's useful to have two different paragraphs. One about the new attribute 
which is not really a semantics change, and one about the semantics changes 
when globals["__builtins__"] doesn't exist. For people who only care about 
Python 3.10 incompatible changes, they can simply read the Porting to Python 
3.10 > Changes in the Python API section ;-)

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37146] opcode cache for LOAD_GLOBAL emits false alarm in memory leak hunting

2021-02-20 Thread Christian Heimes

Change by Christian Heimes :


--
components: +Interpreter Core -SSL
nosy:  -christian.heimes
title: SSl Securité version 3.9.2 -> opcode cache for LOAD_GLOBAL emits false 
alarm in memory leak hunting
type: security -> behavior

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue37146] SSl Securité version 3.9.2

2021-02-20 Thread Webstar Website

Webstar Website  added the comment:

dans cette version pour securité maximale 

SSLContext.wrap_socket()
import socket
import ssl

hostname = 'www.python.org'
context = ssl.create_default_context()

with socket.create_connection((hostname, 443)) as sock:
with context.wrap_socket(sock, server_hostname=hostname) as ssock:
print(ssock.version())


https://backlinkstrong.com/

--
assignee:  -> christian.heimes
components: +SSL -Interpreter Core
nosy: +christian.heimes, webstarnantes
title: opcode cache for LOAD_GLOBAL emits false alarm in memory leak hunting -> 
SSl Securité version 3.9.2
type:  -> security
versions: +Python 3.9 -Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43274] Backlinks Strong decouverte SSL

2021-02-20 Thread Christian Heimes


Christian Heimes  added the comment:

Could you please repost your question in English? I don't speak French and 
Google translate output is incomprehensible.

--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43274] Backlinks Strong decouverte SSL

2021-02-20 Thread Webstar Website

New submission from Webstar Website :

Comment puis-je savoir si mon python généré à la source a activé SSL
il faut obtenir l'information suivante : 
de savoir si opensslest est installé, vous pouvez analyser la sortie de openssl 
version:

$ openssl version
OpenSSL 1.0.2g-fips  1 Mar 2016

on obtient là toutes sortes d'informations à partir de cette  version, par 
exemple, du répertoire où elles sont stockées:
$ openssl version -d
OPENSSLDIR: "/usr/lib/ssl"

--
assignee: christian.heimes
components: SSL
messages: 387398
nosy: christian.heimes, webstarnantes
priority: normal
severity: normal
status: open
title: Backlinks Strong decouverte SSL
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43273] Mock `_mock_wraps` is undocumented and inconsistently named

2021-02-20 Thread Richard Wise


New submission from Richard Wise :

I am trying to use wraps to delegate a call to a decorated patch mock to 
another method. By examining the source code, I was able to achieve this using 
the (apparently undocumented) `Mock._mock_wraps` attribute instead of the 
`wraps` attribute which would be expected given the constructor parameter 
names. I find this behaviour very confusing and inconsistent. Can we either 
expose `Mock.wraps` attribute or document `_mock_wraps` accordingly?

Example:

class MockRepro(unittest.TestCase)

@patch('foo')
def test_side_effect(self, mock_foo):
  # Set side effect in constructor as per 
https://docs.python.org/3/library/unittest.mock.html#unittest.mock.Mock 
  Mock(side_effect = [1, 2])
  # Or can set on decorated patch
  foo.side_effect = [1, 2]

@patch('foo')
def test_wraps(self, mock_foo):
  def wrapped_method():
return 3
  # Set wraps in constructor as per 
https://docs.python.org/3/library/unittest.mock.html#unittest.mock.Mock 
  Mock(wraps=wrapped_method)
  # Or can set on decorated patch
  foo.wraps = wrapped_method # This silently fails
  foo._mock_wraps = wrapped_method # Where does `_mock_wraps` come from?

--
components: Library (Lib)
messages: 387397
nosy: Woodz
priority: normal
severity: normal
status: open
title: Mock `_mock_wraps` is undocumented and inconsistently named
versions: Python 3.8

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue43260] Never release buffer when MemoryError in print()

2021-02-20 Thread Ramin Farajpour Cami


Change by Ramin Farajpour Cami :


--
nosy: +vstinner

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com