Agent skill

clr-activation-debugging

Diagnoses .NET Framework CLR activation issues using CLR activation logs (CLRLoad logs) produced by mscoree.dll. Use when: the shim picks the wrong runtime, fails to load any runtime, shows unexpected .NET 3.5 Feature-on-Demand (FOD) dialogs, unexpectedly does NOT show FOD dialogs, loads both v2 and v4 into the same process causing failures, or any time someone is wondering "what is happening with .NET Framework activation?"

dotnetgithub.com/dotnetGitHub ↗
claude-codeMIT
Install
npx skills add dotnet/skills --skill clr-activation-debugging --agent claude-code

Same command for any agent — swap --agent for codex, cursor, copilot.

Facts
Files in the skill folder: 4
SKILL.md size: 20 KB
Bundled scripts: none
Path: plugins/dotnet-diag/skills/clr-activation-debugging/SKILL.md
Open the folder on GitHub →
Where it comes from
Stars: 4,927
Language: C#
Read our review of the source →

Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.

Review
written from the skill's own SKILL.md · Aug 5, 2026

What it does

Diagnoses .NET Framework CLR activation issues by analyzing CLR activation logs (CLRLoad logs) produced by the shim (mscoree.dll). These logs record every decision the shim makes when selecting and loading a CLR version.

How it works

  • When to use: apply to cases where the process cannot load a CLR, the shim selects the wrong CLR (e.g., v2.0 vs v4.0), unexpected or missing .NET 3.5 FOD dialogs, or when activation questions arise about the runtime.
  • Prerequisites: CLR activation logging must be enabled to produce log files via environment variable or registry settings, with logs named "{ProcessName}.CLRLoad{NN}.log" and only readable after process exit.
  • Inputs: CLR activation log files, symptom description, and expected behavior.
  • Workflow:
    1. Load reference material (log format, activation flow, COM activation).
    2. Survey log files by grouping per process, identify outcomes like "Decided on runtime: vX.Y.Z", "ERROR:", "Launching feature-on-demand", or "Could have launched feature-on-demand".
    3. Analyze problematic logs tracing entry points (e.g., _CorExeMain, DllGetClassObject. Clsid: {guid}, ClrCreateInstance, CorBindToRuntimeEx, ICLRMetaHostPolicy::GetRequestedRuntime, LoadLibraryShim).
    4. Inspect input parameters such as IsLegacyBind, IsCapped, SkuCheckFlags, ShouldEmulateExeLaunch, and LegacyBindRequired.
    5. Process config file results, noting presence/absence and effects like UseLegacyV2RuntimeActivationPolicy.
    6. Review version resolution outputs (e.g., Installed Runtime: vX.Y.Z, Decided on runtime: vX.Y.Z).
    7. If failure, follow the path showing FOD behavior and SEM_FAILCRITICALERRORS state to determine whether FOD was shown or suppressed.
    8. For multiple activations in one process, understand sequence patterns (e.g., first activation succeeds, subsequent fails under legacy cap).
    9. Optional system checks for CLSID registrations, installed runtimes, and SEM_FAILCRITICALERRORS inheritance.
  • Output: A diagnosis describing what happened, why it happened, which inputs controlled the behavior, and what changed if applicable.

When to use it

  • When a process fails to load the CLR, the shim selects the wrong CLR, FOD dialogs appear unexpectedly or not at all, multiple runtimes load in one process, or a COM object fails to activate due to shim runtime resolution.

What it can touch

  • Logs and references described in the workflow; explicit commands and file names are used as written in the logs and steps (e.g., CLRLoad logs, fondue.exe, fondue.exe /enable-feature:NetFx3, fuslogvw.exe).

Caveats

  • Modern .NET (CoreCLR / .NET 5+) are not covered by this skill.
  • Runtime crashes after the CLR has loaded are outside activation troubleshooting.
  • Logs must be read after the process exits; the log file is held open during runtime. Logs directory must exist; the shim will not create it.
From the SKILL.md

# CLR Activation Debugging Diagnose .NET Framework runtime activation issues by analyzing CLR activation logs (CLRLoad logs) produced by the shim (mscoree.dll). These logs record every decision the shim makes when selecting and loading a CLR version. ## When to Use - A process fails to load the CLR at all ("Unable to find a version of the runtime to use") - The shim picks the wrong CLR version (e.g., v2.0 instead of v4.0) - Unexpected .NET 3.5 Feature-on-Demand (FOD) install dialogs appear - FOD dialogs are expected but do NOT appear - Both CLR v2 and CLR v4 load into the same process, causing failures - A COM object fails to activate because the shim can't resolve the runtime - Legacy hosting APIs (CorBindToRuntime) bind to an unexpected version ## When Not to Use - **Modern .NET (CoreCLR / .NET 5+)** — this skill covers .NET Framework only (the mscoree.dll shim) - **Assembly binding failures** — use Fusion logs (fuslogvw.exe), not CLR activation logs - **Runtime crashes after the CLR has loaded** — activation succeeded; the problem is elsewhere ## Background ### The Shim Architecture The .NET Framework shim has two layers: - **mscoree.dll** (the "shell shim") — the public-facing

What's inside
Steps it walks through
  1. When to Use
  2. When Not to Use
  3. Background
  4. The Shim Architecture
  5. .NET 3.5 / v2.0.50727 Version Mapping
  6. .NET 3.5 Availability on Recent Windows
  7. Shim HRESULT Codes
  8. Prerequisites
  9. Inputs
  10. Workflow
  11. Step 1: Load Reference Material
  12. Step 2: Survey the Log Files
  13. Step 3: Analyze Problematic Logs
  14. Step 4: Check System State (if needed)
Ships with 3 files
  • references/activation-flow.md
  • references/com-activation.md
  • references/log-format.md
More from skills
All skills →
About this skill
What does the clr-activation-debugging skill do?

Diagnoses .NET Framework CLR activation issues using CLR activation logs (CLRLoad logs) produced by mscoree.dll. Use when: the shim picks the wrong runtime, fails to load any runtime, shows unexpected .NET 3.5 Feature-on-Demand (FOD) dialogs, unexpectedly does NOT show FOD dialogs, loads both v2 and v4 into the same process causing failures, or any time someone is wondering "what is happening with .NET Framework activation?"

How do I install it?

Run `npx skills add dotnet/skills --skill clr-activation-debugging --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.

Where does this skill come from?

From dotnet/skills, a repository with 4,927 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.

Is a popular skill a good skill?

Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.

Keep going