python / python/cpython

Circular dependency between `mapping` term `collections.abc.Mapping`

Offen
#149,093 6 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

docs
Vorherrschende Sprache
Python
Sterne
77.2k
Forks
35.9k
PR-Merge-Kennzahlen
PR-Kennzahlen ausstehend

Beschreibung

Documentation

The mapping (1) glossary term is defined as

A container object that supports arbitrary key lookups and implements the methods specified in the collections.abc.Mapping or collections.abc.MutableMapping abstract base classes. Examples include dict, collections.defaultdict, and collections.Counter.

Whereas for example collections.abc.Mapping(2) and collections.abc.MutableMapping(2) have the documentation:

ABCs for read-only and mutable mappings.

I expected either the documentation on a mapping or the documentation on the ABC's to describe or link to what methods a (mutable) mapping implements. Now they refer to each other in a circle for the actual specification of what methods are required.

1: https://docs.python.org/3/glossary.html#term-mapping
2: https://docs.python.org/3/library/collections.abc.html#collections.abc.Mapping

Linked PRs
  • gh-149348

Beitragsleitfaden

Beitragsleitfaden öffnen

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Prüfe zuerst den verknüpften PR gh-149348, untersuche anschließend den Glossareintrag zu Mapping sowie die im Bericht verlinkte Dokumentation zu collections.abc.Mapping und collections.abc.MutableMapping. Aktualisiere die Dokumentation so, dass die erforderlichen Mapping-Methoden beschrieben werden, ohne dass die beiden Einträge zirkulär aufeinander verweisen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
python
Bereich
documentation
Issue-Typ
Dokumentation
Schwierigkeit
2/5
Geschätzter Aufwand
1-3 Stunden
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
35/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.