Skip to content

retire: a repo with issues disabled fails every carrier count as "request failed", and the cause is hidden by 2>/dev/null #315

Done

Description

@aitrawog

Category

category:governance

Type

type:fix

Remedy / files the remedy will touch

labels.sh cmd_retire: give api_error_class a distinct "issues disabled" class (lib-org.sh), report it once per repo instead of warning per label, and add a mock-gh arm (repo2 with issues disabled) that proves no "request failed" and a single notice

Cited design decision or org-rulebook rule (or none)

R1 (the retirement output carried 9 unactionable warnings); the deletions themselves were correct

Measured on the 2026-11-23 org retirement:

labels: retire: request failed: Qwen3-TTS        (x9)
retire: mode=apply deleted=4399 absent=507 open_carriers=0 failed=0

Root cause: opencharly/Qwen3-TTS has GitHub issues disabled, so gh issue list --label <retired> exits 1 with the 'opencharly/Qwen3-TTS' repository has disabled issues. api_error_class has no class for that message, so it returns 1 (other); the count step calls handle_api_class, which warns request failed: <repo> and returns 1; the step then treats the count as 0 and continues. The count call redirects stderr to /dev/null, so the cause never reaches the reader. The deletes still succeeded (issues-disabled repos have no open carriers), hence failed=0.

Fix: a distinct class (e.g. 2, "issues disabled") in the one classifier, a single per-repo notice, and an arm in labels-test.sh with a repo whose issue list refuses. The retirement snapshot (446 repos x their labels, taken before deletion) is /tmp/retired-2026-11-23.json in the session that ran it.

Agent: issue-labels · Claude Code session 24a82b7d-810b-46ce-99d6-b16955645c51
Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)

Activity

  1. added
    category:governance
    type:fix
    on Nov 23, 2026
  2. aitrawog commented on Nov 23, 2026

    @aitrawog
    ContributorAuthor

    RESOLVED

    Fixed by #319. api_error_class now returns class 2 for "the repository has disabled issues" (a property, not an API refusal), and retire treats it as count=0, naming it ONCE per repo (retire: <repo> has issues disabled — carrier counts are 0) instead of emitting request failed per retired label. The new arm in scripts/labels-test.sh proves the state is named once and never reads as a request failure; the deletion plan is still produced.

    Agent: issue-labels · Claude Code session 24a82b7d-810b-46ce-99d6-b16955645c51
    Assisted-by: Claude Code deepseek-v4.1-flash:cloud (analysed on a live system)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    category:governancetype:fix

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions