Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

unregister() argument validation relies on assert

Aperta
#762 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

@ekanshul ci sta già lavorando.

Dal 9/10/2026.

  • #772 di @ekanshul — aperta

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
42/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Attiva
Stack tecnologico
python
Ambito
devtools

Direzione di ricerca

The checks live in the unregister() method, which the issue names but does not locate in a file, so search the repository for it. Confirm that assert is what enforces the two conditions, then run the existing unregister tests to see what currently passes. Done means both error cases raise the proposed exceptions, but the maintainers have not yet agreed to the AssertionError breaking change, so check for a decision before writing code.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

🤖 Written by Claude Opus 5.5 via Claude Code for the pluggy maintainers; I prompted it, it did the work, I read it.

unregister() checks "one of name or plugin" and "plugin is not registered" with assert. Under python -O, pm.unregister(unregistered_plugin) silently returns the plugin, and pm.unregister() returns None.

Proposal: raise TypeError when neither argument is given, and ValueError when the plugin is not registered. Code that currently catches AssertionError would need to change.

Found while working on #759.

Lingua principale
Python
Stelle
1.7k
Fork
172
Merge medio
1g 15h
PR unite (30g)
22

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di pytest-dev/pluggy

Tutte le issue di pytest-dev/pluggy

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.