Przejdź do treści
Biblioteka skilli
Programowanie · Analiza

sf-debug

/sf-debug

Szuka przyczyn błędów w Salesforce: nieudanych testów, przekroczeń limitów governora, błędów wdrożenia i śladów Agentforce.

Licencja
MIT
Ostatnia zmiana repozytorium
21.10.2026

Ocena i bezpieczeństwo

100/ 100Klasa: dobry
Format25 / 25
Frontmatter z nazwą i opisem, poprawna nazwa, opis do 1024 znaków, nazwa zgodna z folderem.
Odkrywalność25 / 25
Opis mówi, kiedy użyć skilla, ma sensowną długość i jest w 3. osobie.
Treść35 / 35
Co najmniej 150 słów i do 500 linii, nagłówki, listy kroków, przykłady albo kod.
Higiena15 / 15
Bez zaślepek typu TODO, bez ścieżek Windows, z licencją.
Ryzykobrak sygnałów w skanie
Pliki w paczce
29
Skrypty
1
Komentarze HTML
0
Adresy URL w SKILL.md
0
Przestarzałość

Brak sygnałów. Repozytorium zmienione 21.10.2026, bez odwołań do wycofanych modeli i API.

Licencja

MIT, otwarta: można używać i zmieniać, z zachowaniem informacji o autorze.

Co sprawdzić przed instalacją
  • 1 skrypt w paczce. Przejrzyj je przed instalacją, bo Claude może je uruchomić.

Skrypty: references/explain/scripts/context.mjs

Co robi i kiedy

Szuka przyczyn błędów w Salesforce: nieudanych testów, przekroczeń limitów governora, błędów wdrożenia i śladów Agentforce.

Wyzwalacze z opisu

debugwhy is this failingexplain this

Argumenty

/sf-debug [mode:explain|agent-observe] [error, test path, log, or subject]
Oryginalny opis (EN)

Find root causes of Salesforce bugs and explain code: failing tests, governor-limit errors, deploy failures, LWC errors, sharing issues, Agentforce traces. Use for 'debug', 'why is this failing', 'explain this'.

Jak działa

  1. Modes
  2. Required reads
  3. Mode
  4. Salesforce Angle
  5. Interaction Method
  6. After the fix
Sekcje z nagłówków SKILL.md, w oryginale · 63 linii, 638 słów
Podgląd SKILL.md
---
name: sf-debug
tier: discipline-gate
description: "Find root causes of Salesforce bugs and explain code: failing tests, governor-limit errors, deploy failures, LWC errors, sharing issues, Agentforce traces. Use for 'debug', 'why is this failing', 'explain this'."
argument-hint: "[mode:explain|agent-observe] [error, test path, log, or subject]"
---

# sf-debug

## Modes

First argument `mode:<name>` selects a mode; everything after it passes to that mode's guide. Load only the guide for the chosen mode.

| Mode | Use for | Guide |
|---|---|---|
| `(none)` | Reproduce, find the root cause, fix | this file |
| `explain` | Explain how or why code works, or recap work | `references/explain/guide.md` |
| `agent-observe` | Analyze production Agentforce sessions (STDM traces) | `references/agent-observe/guide.md` |

> **Principles enforced:** 2 (verifiability), 3 (jagged intelligence). See `PRINCIPLES.md`.

> **Persona dispatch.** This skill dispatches personas as isolated subagents — see `../sf-work/references/dispatch/guide.md` for the mechanics (isolated subagents, same-response parallelism, same-file-conflict check). The `sf-bug-reproduction-validator` (a writer) and any reviewers it spawns live under `references/personas/`; research personas are referenced from `../sf-plan/references/personas/`.

Investigate Salesforce-specific bugs systematically — tracing the full causal chain (UI → Flow → trigger → Apex → DML → callback) before proposing a fix — and optionally implement the fix with test-first discipline.

\<feature\_description>
\#$ARGUMENTS
\</feature\_description>

## Required reads

Procedure lives in sibling files, not only in this orchestrator:

- **Mandatory debugging gate** — read `references/mandatory-debugging-gate.md` before acting on this section.
- **3-strikes escalation rule** — read `references/3-strikes-escalation-rule.md` before acting on this section.
- **Defense-in-depth pattern** — read `references/defense-in-depth-pattern.md` before acting on this section.
- **Related** — read `references/related.md` before acting on this section.
- **Pipeline mode** — when invoked with `mode:pipeline`, read `references/pipeline-mode.md` before mutating.

**Iron Law:** no fixes without root-cause classification first (`references/mandatory-debugging-gate.md`).

## Mode

Default is interactive. **`mode:pipeline`** (set by `sf-ship mode:babysit` or `sf-lfg`) is non-interactive: never ask the user; fix only convergent bugs; return the structured JSON in `references/pipeline-mode.md`. Status spellings are fixed: `fixed-and-pushed | fixed-not-pushed | diagnosed-no-fix | flaky-infra | needs-human`.

## Salesforce Angle

* **Trigger context awareness**: when a bug surfaces in a trigger, identify whether it fires on `before insert`, `after update`, `after undelete`, etc., and whether the same logic must hold across all relevant contexts.

* **Governor limit framing**: `System.LimitException` or `Too many SOQL queries: 101` errors are causal-chain symptoms; the cause is usually a query inside a loop, a recursive trigger, or unbatched DML several layers up.

* **Sharing-context bugs**: failing tests in production that pass in sandbox often trace to `with sharing` / `without sharing` / `inherited sharing` mismatches; reproduce with `System.runAs(User)` for the suspect role.

* **Mixed DML / setup/non-setup**: errors of the form `MIXED_DML_OPERATION` mean a DML on a setup object (User, Group, GroupMember) and a non-setup object happen in the same transaction; the fix is to split into asynchronous contexts.

* **Deploy validation failures**: `sf project deploy validate` failures are reproducible against a sandbox; capture the validation ID and run the relevant Apex test selectively before re-validating.

## Interaction Method

When asking the user a question, use the platform's blocking question tool (`AskUserQuestion` in Claude Code, `request_user_input` in Codex, `ask_user` in Gemini). Fall back to numbered options in chat when no blocking tool is available. Ask one question at a time. Prefer concise single-select choices when natural options exist.

## After the fix

Record which files this fix owns, and which files were already dirty. Commit and publish only the fix-owned files.

Do not ask whether to open a pull request when the branch contains only this fix. State the branch, the files, and that a pull request will be opened, then continue. If the branch also holds work this run did not create, commit the fix-owned files when they are separable and stop before push, naming the other files. If a fix-owned file was already dirty, ask once before including the user's edits.

An instruction already in context that names how this repo ships (drafts only, commit only, review first) outranks that default. Do not widen the diff to the rest of the branch. `mode:pipeline` still follows `references/pipeline-mode.md` and does not open a pull request on its own.
Pliki w paczce (29)
  • SKILL.md 5 KB
  • references/3-strikes-escalation-rule.md 1 KB
  • references/defense-in-depth-pattern.md 1 KB
  • references/mandatory-debugging-gate.md 4 KB
  • references/pipeline-mode.md 1 KB
  • references/related.md 1 KB
  • references/agent-observe/guide.md 3 KB
  • references/agent-observe/references/capture-learnings.md 1 KB
  • references/agent-observe/references/inputs-to-gather-before-starting.md 5 KB
  • references/agent-observe/references/inspiration.md 2 KB
  • references/agent-observe/references/phase-0-discover-the-data-space.md 4 KB
  • references/agent-observe/references/phase-1-alt-fallback-when-stdm-is-unavailable.md 8 KB
  • references/agent-observe/references/phase-1-observe-query-stdm-preferred-path.md 6 KB
  • references/agent-observe/references/phase-2-reproduce-live-preview-3-run-classification.md 3 KB
  • references/agent-observe/references/phase-3-improve-edit-the-agent-file-directly.md 8 KB
  • references/agent-observe/references/when-to-use-this-skill.md 1 KB
  • references/explain/guide.md 4 KB
  • references/explain/references/boundaries.md 1 KB
  • references/explain/references/check-in.md 4 KB
  • references/explain/references/destinations.md 5 KB
  • references/explain/references/execution-flow.md 15 KB
  • references/explain/references/explainer-html.md 5 KB
  • references/explain/references/explainer-markdown.md 3 KB
  • references/explain/references/intake.md 6 KB
  • references/explain/references/model-tiers.md 1 KB
  • references/explain/references/who-the-explainer-is-for.md 1 KB
  • references/explain/references/agents/work-recap-scout.md 2 KB
  • references/explain/scripts/context.mjs 4 KB
  • references/personas/sf-bug-reproduction-validator.md 3 KB

Wersje

W bazie nie ma innych skilli o nazwie sf-debug.

Migawka bazy z 13.11.2026 · wersja paczki 0276ae1b0206 (skrót SHA-256 całej paczki)

Pobrania w ostatnich 30 dniach: 0 · ranking

Zgłoś problem z tym skillem: szkodliwa treść, błędny opis albo prośba autora o usunięcie.

Podobne skille

  • 100platform-apex-logs-debug
    Analizuje logi debugowania Salesforce, przekroczenia limitów i ślady stosu, z oceną punktową każdego problemu.
  • 90sf-know
    Dostarcza wiedzę o platformie Salesforce: limity governora, wzorce Apex, LWC i Flow, bezpieczeństwo oraz integracje.
  • 100salesforce-apex-log-analyzer-skill
    Pobiera i analizuje logi debugowania Apex z podłączonego orga Salesforce: przekroczenia limitów, wzorzec N+1 w SOQL, nieobsłużone wyjątki i awarie jobów asynchronicznych.
  • 100sf-review
    Przegląda kod i dokumentację Salesforce pod kątem limitów, bezpieczeństwa CRUD i FLS, udostępniania, LWC, Flow i integracji.
  • 100salesforce-apex-lwc-code-review-skill
    Przegląda kod Apex, triggery i komponenty LWC pod kątem podatności i ryzyka limitów zarządcy, w tym SOQL i DML w pętlach. Przydaje się przed wdrożeniem zmian w Salesforce.
  • 100investigate
    Prowadzi analizę przepływu kodu tylko do odczytu: w trybie debug szuka przyczyn błędów, w trybie explain opisuje cel, przebieg i wpływ kodu.

Uwagi i zgłoszenia

Wiadomość trafi do Bartosza Sokolińskiego. Adres e-mail jest potrzebny tylko do odpowiedzi. Szczegóły w polityce prywatności.