Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

manage-symptoms

БесплатноЗапускает вложенные скриптыНе проверен

Create, update, or delete Sippy Symptoms — known CI failure signatures that automatically label job runs — via the authenticated Sippy API

openshift-engот openshift-eng★ 123 звезды на GitHub

Об этом скилле

Manage Symptoms

Sippy Symptoms are known-failure signatures for OpenShift CI. A symptom is a rule made of a file pattern (a glob over a CI job run's artifact files, e.g. **/build-log.txt) and a matcher (string = substring, regex = regular expression, none = file merely exists, cel = a compound CEL expression over other label names). When a symptom matches a job run's artifacts, Sippy applies one or more Labels — human-readable tags that categorize the failure — to that run. Labels appear in the Sippy UI and Spyglass and help everyone quickly recognize known failure modes without re-debugging them. You do not need any prior Sippy knowledge to use this skill.

Every symptom must always have at least one label. A symptom exists to label matching runs, so a symptom without a label serves no purpose. Even when the label reads the same string as another field (e.g. the summary), a label is still required — always supply --label-ids. Creating or updating a symptom with no labels is rejected by client-side validation.

InfraFailure label warning: If you specify the InfraFailure label, you will be prompted to confirm. This generic label can hide specific problems and make them harder to track as they become pervasive. Best practice is to use more specific labels (e.g., AWSAuthFailure, NetworkTimeout, DiskFull). Use --yes to skip the confirmation prompt if you're certain.

Creating or updating a symptom does NOT apply its label to job runs that already finished. Symptom detection only runs automatically as new artifacts arrive, so a brand-new or changed symptom leaves already-completed runs unlabeled until you retroactively reevaluate them. After every create or update you MUST apply the label to the affected runs with the reevaluate-job-runs skill (see Step 8) — otherwise the label you defined never shows up in the Sippy UI or Spyglass, which is the most common reason a symptom "has a label but nothing is labeled."

When to Use This Skill

Use this skill when you need to:

  • Auto-label a recurring failure pattern you found in CI logs, so future runs are recognized without re-debugging
  • Correct an existing symptom's matcher, file pattern, or match string
  • Retire an obsolete symptom that no longer applies

Prerequisites

  1. OpenShift CLI Authentication: Required for authenticating to the sippy-auth API

    • Must be logged into the DPCR cluster via oc login
    • Cluster API: https://api.cr.j7t7.p1.openshiftapps.com:6443
    • Use the oc-auth skill to obtain the Bearer token
  2. Python 3: Python 3.6 or later

    • Check: python3 --version
    • Uses only standard library (no external dependencies)

Implementation Steps

Step 1: Check for Duplicates

Before creating a symptom, search the existing catalog to avoid duplicates:

python3 plugins/ci/skills/list-symptoms/list_symptoms.py --search "AuthFailure" --format summary

If an equivalent symptom already exists, prefer updating it instead of creating a new one.

Step 2: Verify the Target Labels Exist

Symptoms can only reference labels that already exist:

python3 plugins/ci/skills/list-symptoms/list_symptoms.py --labels --format summary

If a label is missing, create it first with the manage-labels skill. (The script also verifies label IDs against the labels API before submitting; use --skip-label-check only if the labels API is unreachable.)

Step 3: Obtain Authentication Token

Use the oc-auth skill to obtain a Bearer token from the DPCR cluster:

# Get token from the DPCR cluster context
# The oc-auth skill's curl_with_token.sh uses this cluster for sippy-auth
DPCR_CLUSTER="https://api.cr.j7t7.p1.openshiftapps.com:6443"

# Find the oc context for the DPCR cluster and get the token
CONTEXT=$(oc config get-contexts -o name 2>/dev/null | while read -r ctx; do
  server=$(oc config view -o jsonpath="{.clusters[?(@.name=='$(oc config view -o jsonpath="{.contexts[?(@.name=='$ctx')].context.cluster}" 2>/dev/null)')].cluster.server}" 2>/dev/null || echo "")
  server_clean=$(echo "$server" | sed -E 's|^https?://||')
  if [ "$server_clean" = "api.cr.j7t7.p1.openshiftapps.com:6443" ]; then
    echo "$ctx"
    break
  fi
done)

if [ -z "$CONTEXT" ]; then
  echo "Error: Not logged into DPCR cluster. Please run: oc login $DPCR_CLUSTER"
  exit 1
fi

export SIPPY_TOKEN=$(oc whoami -t --context="$CONTEXT" 2>/dev/null)
if [ -z "$SIPPY_TOKEN" ]; then
  echo "Error: Failed to get token. Please re-authenticate to DPCR cluster."
  exit 1
fi

Prefer exporting SIPPY_TOKEN as above rather than passing --token on the command line — command-line arguments are visible in process listings. --token still works and takes precedence over the environment variable.

Step 4: Confirm the Payload with the User

**Before any create or update, show the user the full payload that will be sent (summary, matcher type, file pattern, match string, label IDs) and get their confirmat

Полный SKILL.md на GitHub

Установить manage-symptoms в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

manage_symptoms.pytest_manage_symptoms.py

FAQ

Что делает скилл manage-symptoms?

Create, update, or delete Sippy Symptoms — known CI failure signatures that automatically label job runs — via the authenticated Sippy API

Как установить скилл manage-symptoms?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл manage-symptoms запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить manage-symptoms с