Add runnable code snippets to CTable.where() and sort_by() docstrings
- Vorherrschende Sprache
- Python
- Sterne
- 211
- Forks
- 58
- Ø Merge
- 1 T. 17 Std.
- Gemergte PRs (30 T.)
- 6
Beschreibung
The docstrings for CTable.where() and CTable.sort_by() describe the API well but contain no runnable Examples: section. New contributors exploring the API in a REPL or reading rendered API docs get no concrete illustration of the lazy-view behaviour introduced in this release.
Suggested work: Add an Examples section to both docstrings (NumPy docstring format) showing:
- where(): filter with a simple predicate, with columns=, and with a compound condition
- sort_by(): sort a plain table, sort a filtered view (demonstrating that it stays lazy until iterated), and multi-key sort
- Both should include print() calls that make the lazy-vs-eager distinction visible
Beitragsleitfaden
Rechercherichtung
Beginne mit den Docstrings von CTable.where() und CTable.sort_by() und prüfe die bereits vorhandenen Beispiele im NumPy-Format im Repository, bevor du Änderungen vornimmst. Füge ausführbare Beispiele für die angeforderten Prädikate, die Spaltenauswahl, das Filtern, das einfache Sortieren und das Sortieren nach mehreren Schlüsseln sowie für lazy views hinzu, mit print()-Ausgaben, die sichtbar machen, wann die Auswertung erfolgt; fertig ist die Aufgabe, wenn beide Docstrings gültige Beispiele rendern.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- python
- Bereich
- documentation
- Issue-Typ
- Dokumentation
- Schwierigkeit
- 2/5
- Geschätzter Aufwand
- Ein halber Tag
- Aktivitätsstatus
- Ruhig
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 74/100