vb6-trace-pattern

vb6-trace-pattern is a skill for Claude Code from alexcassol/claude-vb6-skills. It costs 198 tokens per session (2,553 once invoked), scanned A, original, MIT.

A logging pattern for Visual Basic 6 programs, which manually records which methods are entered and exited. VB6 has no built-in call stack that application code can use to show the chain of calls after an error.

In plain words
What is it for?
Adding entry and exit logging to non-trivial VB6 procedures, especially code that uses databases, files, networks, or structured error handling.
Why use it?
An error message may say what went wrong without showing how the program reached that point. The recorded method stack adds call depth and serialized parameters to production logs.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the claude-vb6-skills plugin — 5 skills shipped together

Good fit Adding entry and exit logging to non-trivial VB6 procedures, especially code that uses databases, files, networks, or structured error handling.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/alexcassol/claude-vb6-skills/vb6-trace-pattern
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add alexcassol/claude-vb6-skills --skill vb6-trace-pattern
Clone the repo
git clone --depth 1 https://github.com/alexcassol/claude-vb6-skills

Made for: Claude Code.

Or install claude-vb6-skills, the plugin that ships this one along with the rest of its 5 skills.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for vb6-trace-pattern

README.md
[![agentmods](https://agentmods.dev/badge/skills/alexcassol/claude-vb6-skills/vb6-trace-pattern/github.svg)](https://agentmods.dev/skills/alexcassol/claude-vb6-skills/vb6-trace-pattern)
Your own site
<a href="https://agentmods.dev/skills/alexcassol/claude-vb6-skills/vb6-trace-pattern"><img src="https://agentmods.dev/badge/skills/alexcassol/claude-vb6-skills/vb6-trace-pattern/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for vb6-trace-pattern

Your own site · 80×15
<a href="https://agentmods.dev/skills/alexcassol/claude-vb6-skills/vb6-trace-pattern"><img src="https://agentmods.dev/badge/skills/alexcassol/claude-vb6-skills/vb6-trace-pattern.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 198 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,553 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00198 $0.02553
Opus 5 $0.00099 $0.01277
Sonnet 5 $0.00040 $0.00511
Haiku 4.5 $0.00020 $0.00255

Measured 9d ago against content hash 89b4e3b4a131, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

vb6-trace-pattern scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/vb6-trace-pattern/SKILL.md · 255 lines

How it starts

The opening of the file, as written. The whole thing — 255 lines — stays where its author put it; the contents beside it link to each section on GitHub.

VB6 Trace Pattern

VB6 has no native call stack accessible to user code. When an error fires in production, Err.Description tells you what but not where in the chain of calls. This pattern solves that by maintaining a manual stack in a module-level array, pushed by EnterMethod on entry and popped by ExitMethod on exit.

The pattern is one of the most useful additions you can make to a long-lived VB6 codebase. The cost is one line at the top and one line in each exit path of every instrumented procedure.

1. When to instrument

Every non-trivial new procedure gets EnterMethod/ExitMethod. "Non-trivial" means any of:

  • More than ~5 lines of logic
  • Has On Error GoTo (CSEH style)
  • Accesses database, file, or network
  • Called from more than one place

Skip for:

  • Trivial getters/setters (Property Get/Let that just reads/assigns a field)
  • One-line utility functions
  • Stateless pure helpers (string formatting, math)

When in doubt, instrument. The overhead is negligible compared to the diagnostic value when something fails in production.

2. Canonical placement

The pattern is paired with the CSEH error-handling pattern:

'CSEH: ErrRaise
Public Function GetActiveCustomer(ByVal lngCustomerID As Long) As Object

        '<EhHeader>
        On Error GoTo GetActiveCustomer_Err

        EnterMethod "modDB", "GetActiveCustomer"
        '</EhHeader>

        ' ... body ...

    '<EhFooter>
        On Error GoTo 0

GetActiveCustomer_Exit:
        ' cleanup
        ExitMethod "modDB", "GetActiveCustomer"
        Exit Function

GetActiveCustomer_Err:
        ' Capture Err FIRST — the cleanup and ExitMethod below reset the Err object
        Dim lGetActiveCustomer_ErrNum As Long
        Dim sGetActiveCustomer_Err    As String
        lGetActiveCustomer_ErrNum = Err.Number
        sGetActiveCustomer_Err = "Error: " & Err.Number & " - " & Err.Description & " (" & Erl & ")"

        ' cleanup
        ExitMethod "modDB", "GetActiveCustomer"

        Err.Raise lGetActiveCustomer_ErrNum, "SampleApp.modDB.GetActiveCustomer", sGetActiveCustomer_Err
    '</EhFooter>
End Function

Read the full file on GitHub · 255 lines

Files

What ships with it

1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 9d ago First seen · 255 lines · 198 tokens per session scan A 89b4e3b4a131

Subscribe to this mod's changes

vb6-trace-pattern is a skill published in the GitHub repository alexcassol/claude-vb6-skills (4 stars, last pushed 2mo ago), licensed MIT. It adds 198 tokens to every session and 2,553 once invoked, about $0.0010 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

bootstrap-xcode-workspace

Create, adopt, extend, and align one Swift product workspace with app, extension, package, and service components under one permanent Xcode entrypoint.

gaelic-ghost/socket · 36 tokens

bootstrap-solution

Bootstrap or guide a reproducible .NET solution with explicit F# or C# language choice, SDK selection, project layout, test project setup, and initial validation commands.

gaelic-ghost/socket · 38 tokens

build-kotlin-android

Implement Kotlin-first Android app or library changes, including activities, fragments, services, receivers, Compose UI, XML/AppCompat UI, AndroidX, lifecycle-aware coroutines, state, persistence touchpoints, resources, accessibility labels, navigation touchpoints, tests, lint, and validation while preserving repo…

gaelic-ghost/socket · 66 tokens

build-csharp-project

Build or modify idiomatic C# .NET projects using nullable-aware APIs, records/classes, async/task behavior, analyzer conventions, tests, and repo-local validation.

gaelic-ghost/socket · 37 tokens

build-fsharp-project

Build or modify idiomatic F# .NET projects using explicit modules, domain types, functional data flow, file ordering, async/task interop, tests, and repo-local validation.

gaelic-ghost/socket · 41 tokens

fsharp-csharp-interop

Design and maintain explicit F# and C# boundaries in mixed .NET solutions, including project references, public API shape, async/task interop, nullability, options, records, and package-facing contracts.

gaelic-ghost/socket · 48 tokens