duckdb Python Extension Analysis Report
- Langage dominant
- Python
- Étoiles
- 187
- Forks
- 112
- Merge moyen
- 13 h 29 min
- PR mergées (30 j)
- 17
Description
### What happens?
I ran [cext-review-toolkit](https://github.com/devdanzin/cext-review-toolkit) on duckdb-python and got a report with some issues:
> The primary risks are: (1) **Python API calls without GIL in the parallel numpy scan path** (data corruption/crash), (2) **`PyTuple_Pack` reference leak** in `map.cpp` (~11 KB/call), (3) **unchecked `PyNumber_Rshift` NULL** in 128-bit integer conversion (segfault), (4) **`PyErr_PrintEx` clobbering exceptions** in map and filesystem, and (5) **UDF exception handling** that optionally swallows `MemoryError`/`KeyboardInterrupt`.
The full report is available at https://gist.github.com/devdanzin/5c7600153c8e76afee3ef1a2d516ad70
### To Reproduce
Some reproducers are available in the [Reproducers Appencix](https://gist.github.com/devdanzin/5c7600153c8e76afee3ef1a2d516ad70#duckdb-python-extension--reproducer-appendix).
### OS:
Linux x86_64
### DuckDB Package Version:
1.5.1
### Python Version:
3.14.3+ debug build
### Full Name:
Daniel Silva Diniz
### Affiliation:
None
### What is the latest build you tested with? If possible, we recommend testing with the latest nightly build.
I have tested with a stable release
### Did you include all relevant data sets for reproducing the issue?
Not applicable - the reproduction does not require a data set
### Did you include all code required to reproduce the issue?
- [x] Yes, I have
### Did you include all relevant configuration to reproduce the issue?
- [x] Yes, I have
Guide de contribution
Ouvrir le guide de contribution
Piste de recherche
Commencez par le rapport complet lié et son Reproducers Appendix, puis examinez les chemins nommés de map.cpp, du système de fichiers, du scan numpy parallèle, de la conversion d’entiers sur 128 bits et des exceptions UDF. Le travail est terminé lorsque chaque reproducer listé ne déclenche plus le crash, la fuite, l’erreur non vérifiée, l’écrasement d’exception ou l’exception ignorée signalé, et qu’une couverture de régression existe pour les cas concernés.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- numpy, python
- Domaine
- backend
- Type d'issue
- Bug
- Difficulté
- 5/5
- Temps estimé
- Plus d'une semaine
- Activité
- Calme
- Clarté
- À clarifier
- Accessibilité débutants
- 35/100