Possible `NULL`-related `SystemError` when interpreter is not fully initialized
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 3/5
- Tempo estimado
- 1-2 dias
- Facilidade para iniciantes
- 65/100
Direção de pesquisa
Read Python/import.c around lines 3921–3922 and the IMPORTLIB(interp) definition around lines 95–96 to understand how the null value reaches this path. Reproduce with the _freeze_module command shown in the issue, then check the error handling and tests for this import path. Done means the incomplete initialization case reports a clear SystemError explaining that imports are not fully initialized; the issue also mentions fixing freeze later.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Here IMPORTLIB(interp) can be NULL under rare conditions:
For example, when interpreter is not yet fully initialized.
Output:
» ./Programs/_freeze_module crash crash.py crash.h
Exception ignored in the internal traceback machinery:
SystemError: null argument to internal routine
# ...
Refs https://github.com/python/cpython/pull/161860 where I first found this case.
Refs https://github.com/python/cpython/issues/142662 where the initial reproducer was found.
I guess we should raise a different SystemError here with the text that imports are not yet fully initialized.
My proposal is to make the error message better here: it should state the interpreter is not fully initialized.
And ideally we can fix the freeze command as well later.
- Linguagem predominante
- Python
- Estrelas
- 78.2k
- Forks
- 36.6k
- Merge médio
- 19h 57min
- PRs com merge (30d)
- 630
Preparar o ambiente
Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.
- Sem Dockerfile nem arquivo Docker Compose
- Tem um modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de python/cpython
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
stdlib type-bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
Mantenedores costumam responder em até 1 dia
-
extension-modules stdlib topic-XML type-bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
python/cpython#161807 · 1 comentário ·
Mantenedores costumam responder em até 1 dia
-
stdlib type-feature
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
python/cpython#161788 · 7 comentários ·
Mantenedores costumam responder em até 1 dia
-
extension-modules topic-IO type-bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 75/100
Mantenedores costumam responder em até 1 dia
Todas as issues de python/cpython
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 62/100
cpp-best-practices/project_validator#267 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
Project-N-E-K-O/N.E.K.O#3725 ·
Mantenedores costumam responder em até 1 dia
-
[Bug] Sending a Telegram message chain twice duplicates mentionsTalvez já em andamento @123XieC assumiu hoje. Aberta
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
AstrBotDevs/AstrBot#11125 ·
Mantenedores costumam responder em até 1 dia
-
backend bug priority: high
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
nooriegarg/ContribIQ#73 ·
Mantenedores costumam responder em até 1 dia
-
bug p3 security
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
amd/gaia#8197 · 2 comentários ·
Mantenedores costumam responder em até 1 dia