reviewing-restate-handlers — community reviewing-restate-handlers, community, ide skills, Claude Code, Cursor, Windsurf

v1.0.0
GitHub

About this Skill

Ideal for Deterministic API Agents requiring precise restate handler code review and audit capabilities. The Developer Platform for Modern APIs

unkeyed unkeyed
[0]
[0]
Updated: 3/5/2026

Agent Capability Analysis

The reviewing-restate-handlers skill by unkeyed is an open-source community AI agent skill for Claude Code and other IDE workflows, helping agents execute tasks with better context, repeatability, and domain-specific guidance.

Ideal Agent Persona

Ideal for Deterministic API Agents requiring precise restate handler code review and audit capabilities.

Core Value

Empowers agents to ensure deterministic replay by auditing restate handler code, preventing outer restate context usage inside restate.Run, restate.RunVoid, or restate.RunAsync closures, and handling non-deterministic side effects like DB queries and HTTP calls.

Capabilities Granted for reviewing-restate-handlers

Auditing restate handler code for deterministic replay
Debugging non-deterministic side effects in restate handlers
Validating restate handler context usage inside closures

! Prerequisites & Limits

  • Requires knowledge of restate handler code and deterministic replay
  • Limited to auditing restate handler code inside restate.Run, restate.RunVoid, or restate.RunAsync closures
Labs Demo

Browser Sandbox Environment

⚡️ Ready to unleash?

Experience this Agent in a zero-setup browser environment powered by WebContainers. No installation required.

Boot Container Sandbox

reviewing-restate-handlers

Install reviewing-restate-handlers, an AI agent skill for AI agent workflows and automation. Works with Claude Code, Cursor, and Windsurf with one-command...

SKILL.md
Readonly

Reviewing Restate Handlers

Audit restate handler code to ensure the outer restate context is never used inside restate.Run, restate.RunVoid, or restate.RunAsync closures.

Background

Restate journals every interaction with its context for deterministic replay. The restate.Run / restate.RunVoid / restate.RunAsync functions wrap non-deterministic side effects (DB queries, HTTP calls, etc.) into a single journaled step. Inside these closures, the only context available is restate.RunContext, which is a plain context.Context — it has no restate capabilities.

If the outer restate context (the handler's ctx parameter, typed as restate.Context, restate.ObjectContext, restate.WorkflowContext, restate.WorkflowSharedContext, etc.) is used inside a Run closure, it can break replay determinism and cause subtle bugs that are very hard to diagnose.

What to check

Scan all .go files under svc/ctrl/worker/ for closures passed to:

  • restate.Run(ctx, func(rc restate.RunContext) ...)
  • restate.RunVoid(ctx, func(rc restate.RunContext) ...)
  • restate.RunAsync(ctx, func(rc restate.RunContext) ...)

Inside each closure body, flag any reference to the outer restate context variable. The outer context is typically the handler function's first parameter (often named ctx) whose type is one of:

  • restate.Context
  • restate.ObjectContext
  • restate.ObjectSharedContext
  • restate.WorkflowContext
  • restate.WorkflowSharedContext

Violations — using the outer ctx inside the closure

These are forbidden inside restate.Run / restate.RunVoid / restate.RunAsync:

  1. Service calls via the restate context: e.g., hydrav1.NewVersioningServiceClient(ctx, ...) — the first argument to generated service client constructors is the restate context
  2. State access: restate.Get(ctx, ...), restate.Set(ctx, ...)
  3. Sleep: restate.Sleep(ctx, ...)
  4. Nested Run: restate.Run(ctx, ...) inside another restate.Run
  5. Key access: restate.Key(ctx)
  6. Async operations: restate.RunAsync(ctx, ...), sending messages via .Send()
  7. Any other method or function that takes the outer ctx where ctx is a restate context type

Allowed — using the closure's RunContext

Inside the closure, code should use the restate.RunContext parameter (often named rc, runCtx, or stepCtx) for:

  • Database queries: db.Query.Something(runCtx, ...)
  • Transactions: db.TxRetry(runCtx, ...)
  • External API calls: s.vault.Encrypt(runCtx, ...)
  • Any operation that needs a context.Context

Not a violation

  • Using the outer ctx outside of restate.Run closures is correct and expected
  • Passing plain values (not the context) captured from outer scope into the closure is fine
  • Using restate.TerminalError(...) inside a closure is fine (it doesn't take a context)

Procedure

  1. Use Grep to find all files containing restate.Run, restate.RunVoid, or restate.RunAsync under svc/ctrl/worker/
  2. Read each file
  3. For each closure passed to Run/RunVoid/RunAsync, identify:
    • The outer restate context variable name and type (from the enclosing handler function signature)
    • The closure's RunContext parameter name
  4. Check if the outer context variable appears anywhere in the closure body
  5. Report each violation with file, line, and what the fix should be (either move the call outside the closure, or replace ctx with the closure's RunContext if the call only needs a context.Context)

Output format

For each violation found, report:

FILE:LINE — `ctx` used inside restate.Run/RunVoid/RunAsync
  Outer context: `ctx restate.ObjectContext` (from handler function signature)
  Violation: `someFunction(ctx, ...)` should use `runCtx` or be moved outside the closure

If no violations are found, report: "No restate context violations found."

FAQ & Installation Steps

These questions and steps mirror the structured data on this page for better search understanding.

? Frequently Asked Questions

What is reviewing-restate-handlers?

Ideal for Deterministic API Agents requiring precise restate handler code review and audit capabilities. The Developer Platform for Modern APIs

How do I install reviewing-restate-handlers?

Run the command: npx killer-skills add unkeyed/unkey/reviewing-restate-handlers. It works with Cursor, Windsurf, VS Code, Claude Code, and 19+ other IDEs.

What are the use cases for reviewing-restate-handlers?

Key use cases include: Auditing restate handler code for deterministic replay, Debugging non-deterministic side effects in restate handlers, Validating restate handler context usage inside closures.

Which IDEs are compatible with reviewing-restate-handlers?

This skill is compatible with Cursor, Windsurf, VS Code, Trae, Claude Code, OpenClaw, Aider, Codex, OpenCode, Goose, Cline, Roo Code, Kiro, Augment Code, Continue, GitHub Copilot, Sourcegraph Cody, and Amazon Q Developer. Use the Killer-Skills CLI for universal one-command installation.

Are there any limitations for reviewing-restate-handlers?

Requires knowledge of restate handler code and deterministic replay. Limited to auditing restate handler code inside restate.Run, restate.RunVoid, or restate.RunAsync closures.

How To Install

  1. 1. Open your terminal

    Open the terminal or command line in your project directory.

  2. 2. Run the install command

    Run: npx killer-skills add unkeyed/unkey/reviewing-restate-handlers. The CLI will automatically detect your IDE or AI agent and configure the skill.

  3. 3. Start using the skill

    The skill is now active. Your AI agent can use reviewing-restate-handlers immediately in the current project.

Related Skills

Looking for an alternative to reviewing-restate-handlers or another community skill for your workflow? Explore these related open-source skills.

View All

widget-generator

Logo of f
f

f.k.a. Awesome ChatGPT Prompts. Share, discover, and collect prompts from the community. Free and open source — self-host for your organization with complete privacy.

149.6k
0
AI

flags

Logo of vercel
vercel

flags is a Next.js feature management skill that enables developers to efficiently add or modify framework feature flags, streamlining React application development.

138.4k
0
Browser

zustand

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
AI

data-fetching

Logo of lobehub
lobehub

The ultimate space for work and life — to find, build, and collaborate with agent teammates that grow with you. We are taking agent harness to the next level — enabling multi-agent collaboration, effortless agent team design, and introducing agents as the unit of work interaction.

72.8k
0
AI