refactor(services): leave CLI flag and command names to the app layer

Services report ErrRunScanExhausted, ErrMaxPages and plain conflicts,
and the commands add the --branch/--max-pages/--force hints. Unknown
label names use the shared NotFoundError, and the repository-scoped
review and team search refusal moves into tea search's own usage
check.

Signed-off-by: bircni <bircni@icloud.com>
This commit is contained in:
bircni committed 2026-10-12 18:44:29 +02:00
1 parent f2f1dd1e34
commit af14803b3a
10 files changed
+37 -18

No files matched your search

+3
View File
@@ -78,6 +78,9 @@ $ tea run list --since 24h --json id,status,conclusion,workflow`,
opts.Workflow = workflow.ID
}
page, err := service.RunsPage(cmd.Context(), opts)
if errors.Is(err, services.ErrRunScanExhausted) {
return fmt.Errorf("%w; narrow the search with --branch, --workflow or --status", err)
}
if err != nil {
return err
}