[issue40077] Convert static types to heap types: use PyType_FromSpec()

2020-11-20 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22319
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/23428

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



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-11-19 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22285
pull_request: https://github.com/python/cpython/pull/23393

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



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-11-18 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

For sqlite3, see bpo-42064

--

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



[issue42393] Raise overflow errors iso. deprecation warnings in socket.htons and socket.ntohs (was deprecated in 3.7)

2020-11-17 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Silent truncation was deprecated in Python 3.7 in bpo-28332 with commit 
6a7d3480fc8fe4c60538547d2935083ccff0f631 by Serhiy Storchaka. It should be ok 
to turn these into OverflowError's starting with Python 3.10.

--
components: Library (Lib)
files: error_iso_warning.patch
keywords: patch
messages: 381284
nosy: erlendaasland, pablogsal, serhiy.storchaka
priority: normal
severity: normal
status: open
title: Raise overflow errors iso. deprecation warnings in socket.htons and 
socket.ntohs (was deprecated in 3.7)
versions: Python 3.10
Added file: https://bugs.python.org/file49605/error_iso_warning.patch

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



[issue42393] Raise overflow errors iso. deprecation warnings in socket.htons and socket.ntohs (was deprecated in 3.7)

2020-11-17 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
type:  -> behavior

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



[issue40956] Use Argument Clinic in sqlite3

2020-11-17 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22232
pull_request: https://github.com/python/cpython/pull/23341

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



[issue41861] Convert sqlite3 to heap types (PEP 384)

2020-11-17 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Yes, all sqlite3 types are converted to heap types.

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

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



[issue41861] Convert sqlite3 to heap types (PEP 384)

2020-11-17 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +6
pull_request: https://github.com/python/cpython/pull/23337

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



[issue41861] Convert sqlite3 to heap types (PEP 384)

2020-11-17 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
title: Convert sqlite3 to PEP 384 -> Convert sqlite3 to heap types (PEP 384)
type:  -> resource usage
versions: +Python 3.10

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



[issue29076] Mac installer shell updater script silently fails if default shell is fish

2020-11-15 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22193
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/23302

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



[issue29076] Mac installer shell updater script silently fails if default shell is fish

2020-11-15 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Sure, I'll create a PR right away.

--

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



[issue38823] Improve stdlib module initialization error handling.

2020-11-11 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-11-05 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22082
pull_request: https://github.com/python/cpython/pull/23170

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



[issue42264] Deprecate or remove sqlite3.OptimizedUnicode

2020-11-05 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue42264] Deprecate or remove sqlite3.OptimizedUnicode

2020-11-04 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Ref. discussion on GH-23148: 
https://github.com/python/cpython/pull/23148#discussion_r517536083

OptimizedUnicode was obsoleted and undocumented in Python 3.3 (see commit 
86dc732f1f).

Suggesting to either deprecate OptimizedUnicode in 3.10 and remove it in 3.11, 
or just simply remove it in 3.10.

Relevant history:
48b13f0427 (undoc)
bc35bebb45 (clean up and undoc, closing bpo-13921)

(Pablo, adding you to nosy since you're the release manager; hope that's ok)

--
components: Library (Lib)
messages: 380363
nosy: berker.peksag, erlendaasland, pablogsal, vstinner
priority: normal
severity: normal
status: open
title: Deprecate or remove sqlite3.OptimizedUnicode
versions: Python 3.10

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



[issue42262] [C API] Add Py_NewRef() function to get a new strong reference to an object

2020-11-04 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-11-04 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22060
pull_request: https://github.com/python/cpython/pull/23148

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



[issue15751] [subinterpreters] Make the PyGILState API compatible with subinterpreters

2020-11-04 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue40077] Convert static types to heap types: use PyType_FromSpec()

2020-11-03 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22050
pull_request: https://github.com/python/cpython/pull/23136

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-11-03 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

FYI, rebased https://github.com/erlend-aasland/cpython/tree/bpo-42064/all onto 
master, added Petr Viktorin's _PyType_GetModuleByDef() for use in item 7 
(module state). I still run into problems in item 8, but I haven't devoted much 
time for this yet:
Modules/gcmodule.c:116: gc_decref: Assertion "gc_get_refs(g) > 0" failed: 
refcount is too small
Enable tracemalloc to get the memory block allocation traceback

object address  : 0x7f861140c6b0
object refcount : 2
object type : 0x10978
object type name: type
object repr : 

Fatal Python error: _PyObject_AssertFailed: _PyObject_AssertFailed
Python runtime state: finalizing (tstate=0x7f8631409000)

--

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



[issue42100] Add _PyType_GetModuleByDef

2020-11-03 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue40077] Convert static types to heap types: use PyType_FromSpec()

2020-11-03 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22040
pull_request: https://github.com/python/cpython/pull/23124

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



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-11-03 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

I've converted _sre to multi-phase init in this branch: 
https://github.com/erlend-aasland/cpython/tree/bpo-1635741/sre

I'm waiting for GH-23101 to be merged (or rejected) before I submit the PR. 
It's a fairly large PR (1 file changed, 259 insertions(+), 173 deletions(-), 
ex. clinic code). Let me know if you want me to split it up.

Here's an overview over the commits in the branch (clinic included):
97fc9aad3f (HEAD -> bpo-1635741/sre, origin/bpo-1635741/sre) Convert _sre to 
multi-phase initialisation
 1 file changed, 55 insertions(+), 15 deletions(-)
f2cc4bdf45 Convert global state to module state
 2 files changed, 212 insertions(+), 345 deletions(-)
0d9b3cb47e Establish global module state and add types to it
 1 file changed, 28 insertions(+), 14 deletions(-)
823767cf9a Convert _sre scanner type to heap type
 1 file changed, 19 insertions(+), 37 deletions(-)
a018a9ce15 Convert _sre match type to heap type
 1 file changed, 31 insertions(+), 43 deletions(-)
7e6e997b59 Convert _sre pattern type to heap type
 1 file changed, 35 insertions(+), 44 deletions(-)
06d23e377c Add convenience macro
 1 file changed, 12 insertions(+)

--

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



[issue40077] Convert static types to heap types: use PyType_FromSpec()

2020-11-02 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +22025
pull_request: https://github.com/python/cpython/pull/23108

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



[issue42243] Don't access the module dictionary directly

2020-11-02 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

> Are all these occurrences in the module initialization code?

Most of them, but not all.

> but rewriting can introduce new bugs.

Of course.


> You can do this, but it will be treated as pure cosmetic change. It can be 
> accepted if the new code is much clearer.

It mostly results in more compact code, which, in my opinion, would improve 
both readability and maintainability.

--

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



[issue42243] Don't access the module dictionary directly

2020-11-02 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue42243] Don't access the module dictionary directly

2020-11-02 Thread Erlend Egeberg Aasland

New submission from Erlend Egeberg Aasland :

Quoting from https://docs.python.org/3.10/c-api/module.html:
"It is recommended extensions use other PyModule_* and PyObject_* functions 
rather than directly manipulate a module’s __dict__."

A number of modules still access the module dictionary directly:
zsh % grep -r PyModule_GetDict Modules
Modules/errnomodule.c:PyObject *module_dict = PyModule_GetDict(module);
Modules/_sre.c:d = PyModule_GetDict(m);
Modules/_cursesmodule.c:d = PyModule_GetDict(m);
Modules/_threadmodule.c:d = PyModule_GetDict(m);
Modules/signalmodule.c:PyObject *d = PyModule_GetDict(m);
Modules/_xxsubinterpretersmodule.c:PyObject *ns = 
PyModule_GetDict(main_mod);  // borrowed
Modules/_xxsubinterpretersmodule.c:PyObject *ns = PyModule_GetDict(module); 
 // borrowed
Modules/socketmodule.c:dict = PyModule_GetDict(m);
Modules/_ssl.c:d = PyModule_GetDict(m);
Modules/_curses_panel.c:PyObject *d = PyModule_GetDict(mod);
Modules/_sqlite/connection.c:module_dict = PyModule_GetDict(module);
Modules/_winapi.c:PyObject *d = PyModule_GetDict(m);
Modules/pyexpat.c:d = PyModule_GetDict(m);

--
components: Library (Lib)
messages: 380197
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Don't access the module dictionary directly
type: enhancement
versions: Python 3.10

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



[issue42242] Backport SQLite trace API v2

2020-11-02 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

> [not sure if this is how you do backporting, a new issue and GH PR for each 
> supported release tag?]

Backports are almost always created as backports of a specific GitHub pull 
request. The pull request is labelled as, for example, "needs backport to 3.9", 
and a bot will automatically try to cherry-pick the squashed commit to the 
target branch. So, if we wanted to backport GH-19581, we would do that directly 
from the original pull request over at GitHub. That will also preserve commit 
meta-data.

See also:
https://devguide.python.org/committing/?highlight=backport#backporting-changes-to-an-older-version

--

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



[issue42241] Backport SQLite trace API v2

2020-11-02 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
keywords: +patch
nosy: +erlendaasland
nosy_count: 1.0 -> 2.0
pull_requests: +22016
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19581

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



[issue42242] Backport SQLite trace API v2

2020-11-02 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
keywords: +patch
nosy: +erlendaasland
nosy_count: 1.0 -> 2.0
pull_requests: +22017
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/19581

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



[issue42229] Fix SQLite warnings on macOS

2020-11-01 Thread Erlend Egeberg Aasland

Erlend Egeberg Aasland  added the comment:

> Should I close this issue—and PR—then? - Backport from master to these?

If this fix is wanted in 3.9 and 3.8, I think the correct way to proceed would 
be to close GH-23072 and backport GH-19581.

Try checking out 3.9 and cherrypicking 7f331c8 to verify that the trace-warning 
disappears. I'm pretty sure that SQLite3 version detection works on macOS.

--

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



[issue42229] Fix SQLite warnings on macOS

2020-11-01 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +ronaldoussoren

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



[issue42229] Fix SQLite warnings on macOS

2020-11-01 Thread Erlend Egeberg Aasland

Erlend Egeberg Aasland  added the comment:

> Yes, this commit extends his changes to include macOS support (for some 
> reason that SQLite version check doesn’t work properly on macOS

I can't reproduce this on master on macOS 10.15.7 with the SQLite 3.28.0 that's 
shipped with the os.

--

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



[issue42229] Fix SQLite warnings on macOS

2020-11-01 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Oh, I see now that you're only mentioning 3.9 here. The issue was fixed in 
master only (that is 3.10 alpha). Perhaps GH-19581 should be backported to 3.9, 
or even 3.8, but that's not for me to decide.

Note: your patch is against 3.10, not 3.9.

--

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



[issue42229] Fix SQLite warnings on macOS

2020-11-01 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Look at bpo-24464 regarding the shared cache issue. Apparently I did not 
remember correctly regarding its status.

--

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



[issue42229] Fix SQLite warnings on macOS

2020-11-01 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

FYI, commit 7f331c8 (GH-19581 / bpo-40318) migrates the sqlite3 to the new 
trace API.

There was also a discussion about sqlite3_enable_shared_cache() on bpo, but I 
think it was closed as "wont-fix", IIRC.

--
nosy: +erlendaasland

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



[issue40512] [subinterpreters] Meta issue: per-interpreter GIL

2020-10-31 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-31 Thread Erlend Egeberg Aasland

Erlend Egeberg Aasland  added the comment:

> Thank you erlendaasland for working on GH-22484.

… and thank you for taking the time to review this!

--

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-31 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21976
pull_request: https://github.com/python/cpython/pull/23057

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



[issue42213] Get rid of cyclic GC hack in sqlite3.Connection and sqlite3.Cache

2020-10-30 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue42213] Get rid of cyclic GC hack in sqlite3.Connection and sqlite3.Cache

2020-10-30 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Get rid of the `pysqlite_Cache->decref_factory` hack by implementing proper 
support for cyclic garbage collection.

--
components: Library (Lib)
messages: 379998
nosy: berker.peksag, erlendaasland
priority: normal
severity: normal
status: open
title: Get rid of cyclic GC hack in sqlite3.Connection and sqlite3.Cache
type: resource usage
versions: Python 3.10

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-23 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

I've narrowed down the traverse problems to Py_VISIT(state->CacheType). 
Suspecting this has to do with the cyclic references in cache/connection. 
Preliminary tests with GC tracking `cache->factory` look promising, but this is 
a part of the C API that's _completely_ unknown to me (yet), so I'm on thin ice 
here.

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-22 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Sorted out item 7 (module state). Item 8 is mostly in place, although I get 
ref. count errors if I add traverse/clear callbacks, so I've temporarily 
disabled those.

Proof-of-concept of multi-phase init can be found here: 
https://github.com/erlend-aasland/cpython/commits/bpo-42064/all
I'll try to break items 3 and 7 up in smaller pieces for the reviewer's 
convenience.

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Connection.__init__() fixed by iterating though tp_bases in order to find the 
correct base class to load the state from. There should be a better way to do 
this than to dig through type member internals.

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-19 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Work with item 7 is progressing; see WIP branch for details. Current 
showstopper is how to fetch module state from Connection.__init__ when it has 
been overloaded (for example in /Lib/sqlite3/test/factory.py). Guessing that 
Py_TYPE(self) does not return the sqlite3.Connection type.

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-18 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

FYI, WIP branch for this bpo is here: 
https://github.com/erlend-aasland/cpython/commits/bpo-42064/all
This currently includes items 1 though 6. I'll update the WIP branch with a 
draft of items 7 and 8, hopefully tomorrow.

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-17 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

No, unless we can add `self` as a private context to a sqlite3 database handle, 
we can't use that shortcut. However, using a custom context struct works, and 
it's a minor code change.

Proof-of-concept implementation diffstat:
 2 files changed, 54 insertions(+), 10 deletions(-)

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-17 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Instead of using a custom context struct for sqlite3_create_funcion_v2(), we 
may just use sqlite3_context_db_handle() to get `self`, and then fetch the 
state using PyType_GetModuleState(Py_TYPE(self)).

--

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



[issue42064] Convert sqlite3 to multi-phase initialisation (PEP 489)

2020-10-17 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Porting sqlite3 to multi-phase initialisation is non-trivial and must be broken 
into smaller bpo's, often with multiple PR's per bpo. As far as I can see, this 
is the task list:

1) Heap types (PEP 384): bpo-41861
2) Argument Clinic: bpo-40956
3) Establish global module state
4) Pass `self` iso. callback object to trace, auth, and progress handlers 
(required for item 7)
5) Use sqlite3_create_collation_v2 iso. sqlite3_create_collation (see next list 
item)
6) For sqlite3_create_* functions, establish a context struct that contains the 
target user callback and the state. Modify callers to allocate memory, and the 
destructor to deallocate
7) Module state (PEP 573)
8) Multi-phase initialisation (PEP 489)

The list may be incomplete.

Separate bpo's for 1) and 2) are opened. Pr. 2020-10-17, 1) is almost done, and 
2), part 1 of 5 is awaiting review. It may be convenient to open up sub-bpo's 
for some of the other tasks as well. For instance, using 
sqlite3_create_collation_v2() iso. sqlite3_create_collation(). (FYI, this 
imposes no new SQLite version requirements.)

I'd wait until AC is implemented with moving forward with the rest of the PR's, 
in order to avoid merge mess. The exception might be item 4, preparing the 
trace/progress/auth callbacks, which is easy to isolate from the rest.

I've prepared branches for most of these things locally, some split in multiple 
PR's to ease reviewing.

I've tagged Victor Stinner and Dong-hee Na (hope that's ok), since they've been 
helpful with reviewing and providing helpful hints thus far. Any input from 
Berker Peksag would be highly appreciated; after all, he is the maintainer of 
this module :)

Ref. bpo-1635741 (the grand multi-phase issue)

--
components: Library (Lib)
messages: 378825
nosy: berker.peksag, corona10, erlendaasland, vstinner
priority: normal
severity: normal
status: open
title: Convert sqlite3 to multi-phase initialisation (PEP 489)
type: enhancement
versions: Python 3.10

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



[issue40775] Fix missing dot in sqlite3 Node type name

2020-10-17 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Fixed in GH-22417 / bpo-41861

--
resolution:  -> out of date
stage: patch review -> resolved
status: open -> closed

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



[issue42048] Document Argument Clinic's defining_class converter

2020-10-15 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

The 'defining_class' AC converter is not documented.

https://www.python.org/dev/peps/pep-0573/#argument-clinic
https://docs.python.org/3.10/howto/clinic.html

--
components: Argument Clinic
messages: 378696
nosy: erlendaasland, larry, vstinner
priority: normal
severity: normal
status: open
title: Document Argument Clinic's defining_class converter
type: enhancement
versions: Python 3.10, Python 3.9

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



[issue42021] Fix possible ref. leaks in _sqlite3 module initialisation

2020-10-15 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-13 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

By the way, what's the preferred way to benchmark performance?

--

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-13 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Also, see the comment from Victor here: 
https://github.com/python/cpython/pull/22478#issuecomment-702201260

--

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-13 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

The primary reason is that it will be provide easy access to module state.

The first step in making sqlite3 support multiphase init was to create heap 
types. The second step is argument clinic. The third will be to use AC for 
module state. The last step will then be final multiphase support.

Also, IMHO, AC greatly improves the body of methods (readability => 
maintainability, hardened parsing of arguments)

--

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-13 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +berker.peksag, vstinner

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-13 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21654
pull_request: https://github.com/python/cpython/pull/22478

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



[issue42021] Fix possible ref. leaks in _sqlite3 module initialisation

2020-10-12 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
type:  -> behavior

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



[issue42021] Fix possible ref. leaks in _sqlite3 module initialisation

2020-10-12 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +berker.peksag

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



[issue42021] Fix possible ref. leaks in _sqlite3 module initialisation

2020-10-12 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue42021] Fix possible ref. leaks in _sqlite3 module initialisation

2020-10-12 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Handle PyDict_SetItemString() errors in _sqlite3 init by dereferencing the item 
object and then goto error.

--
components: Library (Lib)
messages: 378516
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Fix possible ref. leaks in _sqlite3 module initialisation
versions: Python 3.10, Python 3.8, Python 3.9

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



[issue41557] Upgrade Windows and macOS builds to use SQLite 3.33

2020-10-09 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue41557] Upgrade Windows and macOS builds to use SQLite 3.33

2020-10-09 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Merged to 3.10, 3.9, 3.8 on both builds. Closing this.

--

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



[issue41557] Upgrade Windows and macOS builds to use SQLite 3.33

2020-10-07 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +steve.dower

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



[issue40956] Use Argument Clinic in sqlite3

2020-10-01 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21501
pull_request: https://github.com/python/cpython/pull/22484

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



[issue1635741] Py_Finalize() doesn't clear all Python objects at exit

2020-10-01 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland
nosy_count: 17.0 -> 18.0
pull_requests: +21497
pull_request: https://github.com/python/cpython/pull/22478

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



[issue41861] Convert sqlite3 to PEP 384

2020-10-01 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21495
pull_request: https://github.com/python/cpython/pull/22478

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



[issue41861] Convert sqlite3 to PEP 384

2020-09-28 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21474
pull_request: https://github.com/python/cpython/pull/22444

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



[issue41861] Convert sqlite3 to PEP 384

2020-09-27 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21462
pull_request: https://github.com/python/cpython/pull/22428

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



[issue2897] PyMemberDef missing in limited API / Deprecate structmember.h

2020-09-26 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland
nosy_count: 14.0 -> 15.0
pull_requests: +21457
pull_request: https://github.com/python/cpython/pull/22419

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



[issue41861] Convert sqlite3 to PEP 384

2020-09-26 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21456
pull_request: https://github.com/python/cpython/pull/22419

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



[issue41861] Convert sqlite3 to PEP 384

2020-09-26 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21454
pull_request: https://github.com/python/cpython/pull/22417

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



[issue41861] Convert sqlite3 to PEP 384

2020-09-25 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue41861] Convert sqlite3 to PEP 384

2020-09-25 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

https://www.python.org/dev/peps/pep-0384/

--
components: Library (Lib)
messages: 377488
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Convert sqlite3 to PEP 384

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



[issue24464] "sqlite3_enable_shared_cache" deprecation warning when compiling with macOS system SQLite3

2020-09-05 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

The SQLite docs clearly states that using sqlite3_enable_shared_cache() is not 
recommended:

"Shared cache is disabled by default. It is recommended that it stay that way. 
In other words, do not use this routine. This interface continues to be 
provided for historical compatibility, but its use is discouraged. Any use of 
shared cache is discouraged."

If sqlite3.enable_shared_cache is not even documented, perhaps we could just 
deprecate and remove it?

--

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



[issue30646] SQLite: sqlite3_enable_shared_cache() is deprecated

2020-09-05 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

A little bit too fast with my previous comment; just disregard that suggestion.

Maybe we should just disable the sqlite3.enable_shared_cache() method if we are 
running on macOS, since it will only result in a misuse error anyway.

--

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



[issue30646] SQLite: sqlite3_enable_shared_cache() is deprecated

2020-09-05 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

>From the SQLite docs https://sqlite.org/c3ref/enable_shared_cache.html:

"Note: This method is disabled on MacOS X 10.7 and iOS version 5.0 and will 
always return SQLITE_MISUSE. On those systems, shared cache mode should be 
enabled per-database connection via sqlite3_open_v2() with 
SQLITE_OPEN_SHAREDCACHE."

We should make sure sqlite3_open_v2() calls use SQLITE_OPEN_SHAREDCACHE if we 
are running on macOS. This should be a pretty straight-forward fix.

--
nosy: +erlendaasland

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



[issue41557] Upgrade Windows and macOS builds to use SQLite 3.33

2020-08-26 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue41557] Upgrade Windows and macOS builds to use SQLite 3.33

2020-08-26 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +21070
pull_request: https://github.com/python/cpython/pull/21960

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



[issue41557] Upgrade Windows and macOS builds to use SQLite 3.33

2020-08-15 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

SQLite 3.33.0 was just released: https://www.sqlite.org/releaselog/3_33_0.html

Suggesting to wait one week before updating, to see if a patch version appears.

Python 3.9 and 3.10 both build fine against SQLite 3.33.0, and make test 
completes without complaints.

I'll prepare a patch for the source deps repo, and a pair of patches for 
macOS/Windows.

--
components: Library (Lib)
messages: 375455
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Upgrade Windows and macOS builds to use SQLite 3.33
type: enhancement
versions: Python 3.10, Python 3.8, Python 3.9

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



[issue41100] Build failure on macOS 11 (beta)

2020-07-22 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue40744] Explicitly drop support for SQLite version < 3.7.3

2020-07-20 Thread Erlend Egeberg Aasland

Erlend Egeberg Aasland  added the comment:

Łukasz, pinging you, since you are the release manager of 3.9.

Without PR 20909, 3.9 will be released without explicitly requiring SQLite 
3.7.3 (setup.py looks for SQLite >= 3.7.2), compiling python 3.9 against SQLite 
3.7.2 will fail at build time because of commit b9a0376, and it will also be 
possible to compile with SQLite 3.7.3 but run with pre SQLite 3.7.3 libraries, 
which could end up with a core dump.

With PR 20909, we explicitly state, in the docs, that SQLite 3.7.3 is required, 
and we explicitly check the SQLite version at configure time (setup.py), 
compile time (#ifdef => #error), and run time (if sqlite3_libversion_number() < 
...) to prevent CPython from being configured, build, or run against 
unsupported SQLite versions.

I might be overestimating the severity of this issue, but I thought you would 
be interested this, as the release manager of 3.9 :)

--
nosy: +lukasz.langa

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



[issue41014] warning: 'sqlite3_trace' is deprecated

2020-07-20 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

According to the SQLite documentation, sqlite3_trace() is deprecated. See 
https://sqlite.org/c3ref/profile.html

See also:
https://bugs.python.org/issue40318
https://github.com/python/cpython/pull/19581

--
nosy: +erlendaasland

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



[issue40741] Upgrade to SQLite v3.32 in Windows and macOS builds

2020-06-19 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +20155
pull_request: https://github.com/python/cpython/pull/20979

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



[issue40741] Upgrade to SQLite v3.32 in Windows and macOS builds

2020-06-19 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

FYI, 3.32.3 is out now: https://sqlite.org/releaselog/3_32_3.html
I'll update the PR and push a new PR for source deps right away.

--

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



[issue40744] Explicitly drop support for SQLite version < 3.7.3

2020-06-16 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
pull_requests: +20091
pull_request: https://github.com/python/cpython/pull/20909

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



[issue34916] Add create_window_function() to sqlite3.Connection

2020-06-15 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
keywords: +patch
pull_requests: +20086
stage: needs patch -> patch review
pull_request: https://github.com/python/cpython/pull/20903

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



[issue40959] Remove unused and unneeded function declaration from sqlite3 header files

2020-06-12 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue40959] Remove unused and unneeded function declaration from sqlite3 header files

2020-06-12 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

The following function declarations can safely be removed because they're 
either unused or unneeded.

In Modules/_sqlite/cache.h:
pysqlite_node_init() // unused; no function definition
pysqlite_node_dealloc()  // unneeded; file scope
pysqlite_cache_init()// unneeded; file scope
pysqlite_cache_dealloc() // unneeded; file scope

In Modules/_sqlite/connection.h:
pysqlite_connection_alloc()// unused; no function definition
pysqlite_connection_dealloc()  // unneeded; file scope
pysqlite_connection_cursor()   // unneeded; file scope
pysqlite_connection_close()// unneeded; file scope
pysqlite_connection_rollback() // unneeded; file scope
pysqlite_connection_new()  // unused; no function definition
pysqlite_connection_init() // unneeded; file scope

In Modules/_sqlite/cursor.h:
pysqlite_cursor_execute() // unneeded; file scope
pysqlite_cursor_executemany() // unneeded; file scope
pysqlite_cursor_getiter() // unused; no function definition
pysqlite_cursor_iternext()// unneeded; file scope
pysqlite_cursor_fetchone()// unneeded; file scope
pysqlite_cursor_fetchmany()   // unneeded; file scope
pysqlite_cursor_fetchall()// unneeded; file scope
pysqlite_noop()   // unneeded; file scope
pysqlite_cursor_close()   // unneeded; file scope

In Modules/_sqlite/prepare_protocol.h:
pysqlite_prepare_protocol_init()// unneeded; file scope
pysqlite_prepare_protocol_dealloc() // unneeded; file scope

In Modules/_sqlite/statement.h:
pysqlite_statement_dealloc() // unneeded; file scope

--
components: Library (Lib)
messages: 371353
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Remove unused and unneeded function declaration from sqlite3 header files
type: enhancement
versions: Python 3.10

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



[issue40956] Use Argument Clinic in sqlite3

2020-06-12 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue40956] Use Argument Clinic in sqlite3

2020-06-12 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

Use Argument Clinic in sqlite3.

--
components: Library (Lib)
messages: 371347
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Use Argument Clinic in sqlite3
type: enhancement
versions: Python 3.10

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



[issue40077] Convert static types to PyType_FromSpec()

2020-06-09 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue34916] Add create_window_function() to sqlite3.Connection

2020-06-08 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Berker, are you still working on this? If not, I've got a proof-of-concept 
version of this w/unit tests ready for review. If you'd like to have a look at 
it, I can create a draft PR.

--
nosy: +erlendaasland

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



[issue40823] Don't use obsolete unittest.makeSuite() in sqlite3 tests

2020-06-07 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Berker, do you have any objections to this change?

--
nosy: +berker.peksag

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



[issue40617] sqlite3: expose sqlite3_create_window_function

2020-06-07 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

Duplicate of bpo-34916

--

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



[issue20178] Derby #9: Convert 52 sites to Argument Clinic across 11 files

2020-06-07 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
nosy: +erlendaasland

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



[issue40741] Upgrade to SQLite v3.32 in Windows and macOS builds

2020-06-07 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


--
title: Upgrade to SQLite v3.32.1 in Windows and macOS builds -> Upgrade to 
SQLite v3.32 in Windows and macOS builds

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



[issue40741] Upgrade to SQLite v3.32.1 in Windows and macOS builds

2020-06-06 Thread Erlend Egeberg Aasland


Erlend Egeberg Aasland  added the comment:

SQLite 3.32.2 is out: https://www.sqlite.org/releaselog/3_32_2.html

>From the changelog:
Fix a long-standing bug in the byte-code engine that can cause a COMMIT command 
report as success when in fact it failed to commit. Ticket 810dc8038872e212

I've created a PR for cpython-source-deps.

--

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



[issue40867] Remove unused include in Module/_randommodule.c

2020-06-04 Thread Erlend Egeberg Aasland


Change by Erlend Egeberg Aasland :


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

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



[issue40867] Remove unused include in Module/_randommodule.c

2020-06-04 Thread Erlend Egeberg Aasland


New submission from Erlend Egeberg Aasland :

_Py_bswap32() is no longer used in _randommodule.c (removed in commit 2d87577), 
so including pycore_byteswap.h is not necessary.

--
components: Library (Lib)
messages: 370732
nosy: erlendaasland
priority: normal
severity: normal
status: open
title: Remove unused include in Module/_randommodule.c
type: enhancement
versions: Python 3.10

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



  1   2   3   >