scan.Run should always end with exactly one EventDone
Maintainer antworten meist innerhalb von 1 Tag
Dieses Issue hat noch niemand übernommen.
Bewertung
- Schwierigkeit
- 4/5
- Geschätzter Aufwand
- 3-5 Tage
- Anfängerfreundlichkeit
- 65/100
Rechercherichtung
Start in internal/scan/runner.go: read scan.Run, its early-exit paths, and the EventError documentation. Add coverage for each listed early exit and check that each produces exactly one EventDone; then review the CLI, TUI, and pkg/subenum consumers named in the issue. Done means all tests pass and no consumer handles a channel closing without EventDone.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Beschreibung
Why it matters
scan.Run has two shapes of ending, and every consumer has to know both. Three consumers now each handle it separately: the CLI (main.go), the TUI (internal/tui/model.go, scan_view.go), and pkg/subenum, which adds an extra KindDone so its callers see one shape.
Evidence
- On five early-exit paths,
scan.RunsendsEventErrorand returns withoutEventDone: an out-of-scope domain, the recursion ceiling, a failed preflight, a failed wildcard check, and a wildcard zone without-force(internal/scan/runner.go, about lines 434–495). Only the deferredclose(events)runs. EventErroris documented as "non-fatal error message" (runner.go:345). In practice, five of its six uses stop the scan. The sixth, the reliability guard at line 877, is followed byEventDone.- The CLI comment says "Early errors such as wildcard detection close the channel without EventDone". The TUI has a
closedflag for "the scan ended without EventDone".
Suggested approach
- Have
scan.Runalways send exactly oneEventDone, withStats(all zero when nothing was scanned), even after an earlyEventError. - Fix the
EventErrordoc comment to say it usually means the scan stopped. - Then remove the special cases: the CLI drain comment, the TUI
closedpath, and the synthesized event inpkg/subenum'sRun.
Done when
scan.Run always ends with one EventDone, a test covers each early-exit path, and none of the three consumers has to handle a channel that closes without one.
- Vorherrschende Sprache
- Go
- Sterne
- 1
- Forks
- 1
- Ø Merge
- 5 T. 2 Std.
- Gemergte PRs (30 T.)
- 3
Entwicklungsumgebung
Startet den Dev-Container des Projekts im Browser, mit Ihrem eigenen GitHub-Konto.
- Enthält ein Dockerfile oder eine Docker-Compose-Datei
- Hat eine Pull-Request-Vorlage
- Beitragsleitfaden lesen
Erste Schritte
- Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
- Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
- Forken Sie das Repository und arbeiten Sie in einem Branch.
- Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.
Mehr aus TMHSDigital/subenum
-
area: cli enhancement good first issue
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 88/100
TMHSDigital/subenum#136 ·
Maintainer antworten meist innerhalb von 1 Tag
-
community documentation good first issue
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 85/100
TMHSDigital/subenum#135 ·
Maintainer antworten meist innerhalb von 1 Tag
-
area: dns enhancement good first issue
Schwierigkeit 2/5 Unter einer Stunde Anfängerfreundlichkeit 90/100
TMHSDigital/subenum#134 ·
Maintainer antworten meist innerhalb von 1 Tag
-
community marketing priority: low
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 35/100
TMHSDigital/subenum#132 · 1 Kommentar ·
Maintainer antworten meist innerhalb von 1 Tag
-
feature priority: low
Schwierigkeit 5/5 Über eine Woche Anfängerfreundlichkeit 35/100
TMHSDigital/subenum#131 ·
Maintainer antworten meist innerhalb von 1 Tag
Alle Issues in TMHSDigital/subenum
Ähnliche Issues
-
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 62/100
siyuan-note/siyuan#20353 ·
Maintainer antworten meist innerhalb von 1 Tag
-
attributes-natural-language "en-US" is rejected by PAPPL >= 1.4.12 printers (RFC 8011 requires lowercase)Evtl. vergeben @ChrisEdgington hat das heute übernommen. Offen
Schwierigkeit 1/5 Unter einer Stunde Anfängerfreundlichkeit 84/100
OpenPrinting/ipp-usb#140 ·
-
Discriminator mapping keys are listed in a random orderEvtl. vergeben @reuvenharrison hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 1 Tag
-
Idle compaction monitors LIST the replica every tick when the newest destination file spans more than one TXIDEvtl. vergeben @pishuv hat das heute übernommen. Offen
Schwierigkeit 2/5 1-3 Stunden Anfängerfreundlichkeit 72/100
benbjohnson/litestream#1563 ·
Maintainer antworten meist innerhalb von 2 Tagen
-
triage needed
Schwierigkeit 1/5 1-3 Stunden Anfängerfreundlichkeit 78/100
Maintainer antworten meist innerhalb von 2 Tagen