python / python/mypy

Consider removing `six`, `past`, and `future` support

Aperta
#13,567 7 commenti 0 reazioni 1 assegnatario Vedi su GitHub

@sobolevn ci sta già lavorando.

Dal 31/8/2022.

deferred feature topic-python2
Lingua principale
Python
Stelle
20.6k
Fork
3.3k
Metriche di merge delle PR
Metriche PR in attesa

Descrizione

Since python2 is now no longer supported, I think it might be a good time to remove special casing of these libraries.

Why?

  1. None of them are required for python3+ code
  2. All their features are now (long) supported by python3+
  3. Their support is clearly a hack
  4. Code to support them is quite complex: https://github.com/python/mypy/blob/840a310f0b6c4a4bd7edfb141c8d1731ba4dd027/mypy/semanal.py#L1971-L2018
  5. There are multiple places where six. / etc special cases are used: mypy/stubgen.py, mypy/semanal.py, mypyc/irbuild/for_helpers.py

I don't see much benefit in keeping them.

Related https://github.com/python/mypy/issues/12237

Guida per i contributori

Apri la guida per i contributori

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.

Valutazione

Questa issue non è ancora stata valutata.

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.