[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill-dotnet-detect-static-dependencies":3,"mdc-sdfpj1-key":37,"related-repo-dotnet-detect-static-dependencies":1721,"related-org-dotnet-detect-static-dependencies":1826},{"slug":4,"name":4,"fn":5,"description":6,"org":7,"tags":11,"stars":25,"repoUrl":26,"updatedAt":27,"license":28,"forks":29,"topics":30,"repo":32,"sourceUrl":35,"mdContent":36},"detect-static-dependencies","detect static dependencies in C# code","Scan C# source files for hard-to-test static dependencies — DateTime.Now\u002FUtcNow, File.*, Directory.*, Environment.*, HttpClient, Console.*, Process.*, and other untestable statics. Produces a ranked report of static call sites by frequency. USE FOR: find untestable statics, scan for static dependencies, testability audit, identify hard-to-mock code, find DateTime.Now usage, detect static coupling, testability report, static analysis for testability. DO NOT USE FOR: generating wrappers (use generate-testability-wrappers), migrating code (use migrate-static-to-wrapper), general code review, or finding statics that are already behind abstractions.\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},"dotnet",".NET (Microsoft)","https:\u002F\u002Fpexgzepcugksgbtrxkhf.supabase.co\u002Fstorage\u002Fv1\u002Fobject\u002Fpublic\u002Forg-logos\u002Fdotnet.png",[12,16,19,22],{"name":13,"slug":14,"type":15},"C#","csharp","tag",{"name":17,"slug":18,"type":15},".NET","net",{"name":20,"slug":21,"type":15},"Code Analysis","code-analysis",{"name":23,"slug":24,"type":15},"Debugging","debugging",4576,"https:\u002F\u002Fgithub.com\u002Fdotnet\u002Fskills","2026-08-01T05:42:21.175964","MIT",332,[31],"agent-skills",{"repoUrl":26,"stars":25,"forks":29,"topics":33,"description":34},[31],"Repository for skills to assist AI coding agents with .NET and C#","https:\u002F\u002Fgithub.com\u002Fdotnet\u002Fskills\u002Ftree\u002FHEAD\u002Fplugins\u002Fdotnet-test\u002Fskills\u002Fdetect-static-dependencies","---\nname: detect-static-dependencies\ndescription: >\n  Scan C# source files for hard-to-test static dependencies — DateTime.Now\u002FUtcNow,\n  File.*, Directory.*, Environment.*, HttpClient, Console.*, Process.*, and other\n  untestable statics. Produces a ranked report of static call sites by frequency.\n  USE FOR: find untestable statics, scan for static dependencies, testability audit,\n  identify hard-to-mock code, find DateTime.Now usage, detect static coupling,\n  testability report, static analysis for testability.\n  DO NOT USE FOR: generating wrappers (use generate-testability-wrappers),\n  migrating code (use migrate-static-to-wrapper), general code review,\n  or finding statics that are already behind abstractions.\nlicense: MIT\n---\n\n# Detect Static Dependencies\n\nScan a C# codebase for calls to hard-to-test static APIs and produce a ranked report showing which statics appear most frequently, which files are most affected, and which abstractions already exist in the .NET ecosystem to replace them.\n\n## When to Use\n\n- Auditing a project's testability before adding unit tests\n- Understanding the scope of static coupling in a legacy codebase\n- Prioritizing which statics to wrap first (highest-frequency wins)\n- Creating a migration plan for incremental testability improvements\n\n## Response Guidelines\n\n- Scale the response to the user's request. A question about a specific category (e.g., \"find time statics\") should focus on that category with file locations and counts, not produce a full report across all categories.\n- When the user provides a specific file or directory path, scan only that scope — do not expand to the entire solution unless asked.\n- The full structured report format in Step 4 is for comprehensive audit requests. For focused questions, return only the relevant subset (e.g., category summary + affected files for the requested category).\n\n## When Not to Use\n\n- The user wants wrappers generated (hand off to `generate-testability-wrappers`)\n- The user wants mechanical migration done (hand off to `migrate-static-to-wrapper`)\n- The statics are already behind interfaces or `TimeProvider`\n- The code is not C# \u002F .NET\n\n## Inputs\n\n| Input | Required | Description |\n|-------|----------|-------------|\n| Target path | Yes | A file, directory, project (.csproj), or solution (.sln) to scan |\n| Exclusion patterns | No | Glob patterns to skip (e.g., `**\u002Fobj\u002F**`, `**\u002FMigrations\u002F**`) |\n| Category filter | No | Limit to specific categories: `time`, `filesystem`, `environment`, `network`, `console`, `process` |\n\n## Workflow\n\n### Step 1: Determine scan scope\n\nResolve the target to a set of `.cs` files:\n- If a `.cs` file, scan that single file.\n- If a directory, scan all `.cs` files recursively (excluding `obj\u002F`, `bin\u002F`).\n- If a `.csproj`, find its directory and scan `.cs` files within.\n- If a `.sln`, parse it, find all project directories, and scan `.cs` files across all projects.\n\nAlways exclude `obj\u002F`, `bin\u002F`, and any user-specified exclusion patterns.\n\n### Step 2: Search for static dependency patterns\n\nScan each file for calls matching these categories:\n\n| Category | Patterns to search for | Recommended replacement |\n|----------|----------------------|------------------------|\n| **Time** | `DateTime.Now`, `DateTime.UtcNow`, `DateTime.Today`, `DateTimeOffset.Now`, `DateTimeOffset.UtcNow`, `Task.Delay(`, `new CancellationTokenSource(TimeSpan` | `TimeProvider` (.NET 8+) |\n| **File System** | `File.ReadAllText(`, `File.WriteAllText(`, `File.Exists(`, `File.Delete(`, `File.Copy(`, `File.Move(`, `Directory.Exists(`, `Directory.CreateDirectory(`, `Directory.GetFiles(`, `Directory.Delete(`, `Path.GetTempPath(`, and instance members that hit the disk (`new FileInfo(...)`, `new DirectoryInfo(...)`, `.LastWriteTimeUtc`, `new StreamReader(path)`) | `IFileSystem` (System.IO.Abstractions NuGet) |\n| **Randomness \u002F identity** | `new Random(`, `Random.Shared`, `Guid.NewGuid(` | `TimeProvider`-style seam: inject `Random` \u002F an `IGuidProvider` |\n| **Culture \u002F serialization** | `CultureInfo.CurrentCulture`, `CultureInfo.CurrentUICulture`, `JsonSerializer.Serialize(`, `JsonSerializer.Deserialize(` | Pass culture\u002Foptions explicitly, or inject a serializer abstraction |\n| **Environment** | `Environment.GetEnvironmentVariable(`, `Environment.SetEnvironmentVariable(`, `Environment.MachineName`, `Environment.UserName`, `Environment.CurrentDirectory`, `Environment.Exit(` | Custom `IEnvironmentProvider` |\n| **Network** | `new HttpClient(`, `HttpClient.GetAsync(`, `HttpClient.PostAsync(`, `HttpClient.SendAsync(` | `IHttpClientFactory` (built-in) |\n| **Console** | `Console.WriteLine(`, `Console.ReadLine(`, `Console.Write(`, `Console.ReadKey(` | `IConsole` wrapper or `ILogger` |\n| **Process** | `Process.Start(`, `Process.GetCurrentProcess(`, `Process.GetProcessesByName(` | Custom `IProcessRunner` |\n\n### Step 3: Aggregate and rank results\n\nCount each call site across the entire scan scope — including the instance-member call sites covered by the rules below, not only `static` ones.\n\n**Counting rules — inaccurate totals are the main way this report loses to an ad-hoc scan:**\n\n- **One authoritative total.** Every call site you found belongs in the category summary and the grand total. Never park real findings in an \"additional observations\" section that the totals exclude.\n- **Classify by what the member touches, not by whether it is `static`.** Instance members that reach the same untestable resource still count and belong in the matching category (`new FileInfo(path).LastWriteTimeUtc` → File System; `httpClient.GetAsync(...)` → Network). Say \"hidden dependency\", not \"static\", when the member is an instance call.\n- **Exclude deterministic pure helpers from the \"needs wrapping\" total.** `Path.Combine`, `Path.GetExtension`, `Path.GetFileName`, and `Math.*`\u002F`string.*` statics take no ambient input and are trivially testable. List them, if at all, in a separate \"no action needed\" note — never as testability blockers.\n- **Cover every category before reporting** — time, file system, environment, network, console, process, randomness (`new Random()`, `Guid.NewGuid()`), culture (`CultureInfo.CurrentCulture`), and serialization\u002Fstatics such as `JsonSerializer`. Omitting a category that is present is an under-count.\n- **Give `file:line` for every occurrence** so the user can jump straight to it.\n- **Reconcile before publishing.** The category totals, the top-patterns table, and the per-file table must sum to the same grand total.\n\nProduce a summary with:\n\n1. **Category summary** — total call sites per category (time, filesystem, env, etc.)\n2. **Top patterns** — the 10 most frequent individual patterns ranked by count\n3. **Most affected files** — files with the highest number of static dependencies\n4. **Existing abstractions available** — for each category, note the recommended .NET abstraction:\n   - Time → `TimeProvider` (built-in since .NET 8)\n   - File system → `System.IO.Abstractions` (NuGet package)\n   - HTTP → `IHttpClientFactory` (built-in)\n   - Environment → custom `IEnvironmentProvider`\n   - Console → custom `IConsole` or `ILogger`\n   - Process → custom `IProcessRunner`\n\n### Step 4: Present the report\n\nFormat the output as a structured report:\n\n```\n## Static Dependency Report\n\n**Scope**: \u003Cproject\u002Fsolution name>\n**Files scanned**: \u003Ccount>\n**Total static call sites**: \u003Ccount>\n\n### Category Summary\n| Category     | Call Sites | Recommended Abstraction |\n|-------------|-----------|------------------------|\n| Time         | 42        | TimeProvider (.NET 8+) |\n| File System  | 31        | System.IO.Abstractions |\n| Environment  | 12        | IEnvironmentProvider   |\n| ...          | ...       | ...                    |\n\n### Top 10 Patterns\n| # | Pattern             | Count | Files |\n|---|---------------------|-------|-------|\n| 1 | DateTime.UtcNow     | 28    | 14    |\n| 2 | File.ReadAllText    | 18    | 9     |\n| ...                                      |\n\n### Most Affected Files\n| File                          | Static Calls | Categories          |\n|-------------------------------|-------------|---------------------|\n| Services\u002FOrderProcessor.cs    | 12          | Time, FileSystem    |\n| ...                                                               |\n\n### Migration Priority\n1. **Time** (42 sites) — Use `TimeProvider`, zero NuGet dependencies on .NET 8+\n2. **File System** (31 sites) — Use `System.IO.Abstractions` NuGet package\n3. ...\n```\n\n### Step 5: Suggest next steps\n\nBased on the report, recommend which category to tackle first (highest count, best built-in support). Keep this to a few lines.\n\nMention `generate-testability-wrappers` or `migrate-static-to-wrapper` only when the user's next action clearly needs them — a hand-off note, not a sales pitch. Never end an audit with promotional next-steps that dilute the findings.\n\n## Validation\n\n- [ ] All `.cs` files in scope were scanned (check count)\n- [ ] Report includes category totals, top patterns, and affected files\n- [ ] Category totals, top patterns, and per-file counts reconcile to the same grand total\n- [ ] Every occurrence carries a `file:line` location\n- [ ] No findings are held outside the totals in an \"additional\" section\n- [ ] Deterministic pure helpers (`Path.Combine`, `Math.*`) are not counted as testability blockers\n- [ ] Each detected pattern has a recommended replacement listed\n- [ ] `obj\u002F` and `bin\u002F` directories were excluded\n- [ ] Migration priority is ordered by impact (count × ease of replacement)\n\n## Common Pitfalls\n\n| Pitfall | Solution |\n|---------|----------|\n| Scanning `obj\u002F` or generated code | Always exclude `obj\u002F`, `bin\u002F`, and `*.Designer.cs` |\n| Counting wrapped calls as statics | Check if the call is behind an interface or injected service before counting |\n| Missing statics inside lambdas\u002FLINQ | Search covers all code within `.cs` files, including lambdas |\n| Recommending `TimeProvider` on \u003C .NET 8 | Check `TargetFramework` in `.csproj` — if \u003C net8.0, recommend `NodaTime.IClock` or custom `ISystemClock` |\n| Ignoring test projects | Only scan production code — exclude `*.Tests.csproj` projects from the scan |\n| Under-counting by relegating findings | Real call sites belong in the category totals, not in a trailing \"also noticed\" paragraph that the totals ignore |\n| Calling an instance member a static | `new FileInfo(p).LastWriteTimeUtc` is an instance call but still a hidden file-system dependency — count it under File System and describe it accurately |\n| Recommending a wrapper for `Path.Combine` | Pure, deterministic helpers need no seam; listing them as blockers makes the recommendations wrong |\n",{"data":38,"body":39},{"name":4,"description":6,"license":28},{"type":40,"children":41},"root",[42,50,56,63,88,94,112,118,163,169,311,317,324,337,417,435,441,446,1001,1007,1020,1028,1190,1195,1315,1321,1326,1338,1344,1349,1367,1373,1503,1509],{"type":43,"tag":44,"props":45,"children":46},"element","h1",{"id":4},[47],{"type":48,"value":49},"text","Detect Static Dependencies",{"type":43,"tag":51,"props":52,"children":53},"p",{},[54],{"type":48,"value":55},"Scan a C# codebase for calls to hard-to-test static APIs and produce a ranked report showing which statics appear most frequently, which files are most affected, and which abstractions already exist in the .NET ecosystem to replace them.",{"type":43,"tag":57,"props":58,"children":60},"h2",{"id":59},"when-to-use",[61],{"type":48,"value":62},"When to Use",{"type":43,"tag":64,"props":65,"children":66},"ul",{},[67,73,78,83],{"type":43,"tag":68,"props":69,"children":70},"li",{},[71],{"type":48,"value":72},"Auditing a project's testability before adding unit tests",{"type":43,"tag":68,"props":74,"children":75},{},[76],{"type":48,"value":77},"Understanding the scope of static coupling in a legacy codebase",{"type":43,"tag":68,"props":79,"children":80},{},[81],{"type":48,"value":82},"Prioritizing which statics to wrap first (highest-frequency wins)",{"type":43,"tag":68,"props":84,"children":85},{},[86],{"type":48,"value":87},"Creating a migration plan for incremental testability improvements",{"type":43,"tag":57,"props":89,"children":91},{"id":90},"response-guidelines",[92],{"type":48,"value":93},"Response Guidelines",{"type":43,"tag":64,"props":95,"children":96},{},[97,102,107],{"type":43,"tag":68,"props":98,"children":99},{},[100],{"type":48,"value":101},"Scale the response to the user's request. A question about a specific category (e.g., \"find time statics\") should focus on that category with file locations and counts, not produce a full report across all categories.",{"type":43,"tag":68,"props":103,"children":104},{},[105],{"type":48,"value":106},"When the user provides a specific file or directory path, scan only that scope — do not expand to the entire solution unless asked.",{"type":43,"tag":68,"props":108,"children":109},{},[110],{"type":48,"value":111},"The full structured report format in Step 4 is for comprehensive audit requests. For focused questions, return only the relevant subset (e.g., category summary + affected files for the requested category).",{"type":43,"tag":57,"props":113,"children":115},{"id":114},"when-not-to-use",[116],{"type":48,"value":117},"When Not to Use",{"type":43,"tag":64,"props":119,"children":120},{},[121,135,147,158],{"type":43,"tag":68,"props":122,"children":123},{},[124,126,133],{"type":48,"value":125},"The user wants wrappers generated (hand off to ",{"type":43,"tag":127,"props":128,"children":130},"code",{"className":129},[],[131],{"type":48,"value":132},"generate-testability-wrappers",{"type":48,"value":134},")",{"type":43,"tag":68,"props":136,"children":137},{},[138,140,146],{"type":48,"value":139},"The user wants mechanical migration done (hand off to ",{"type":43,"tag":127,"props":141,"children":143},{"className":142},[],[144],{"type":48,"value":145},"migrate-static-to-wrapper",{"type":48,"value":134},{"type":43,"tag":68,"props":148,"children":149},{},[150,152],{"type":48,"value":151},"The statics are already behind interfaces or ",{"type":43,"tag":127,"props":153,"children":155},{"className":154},[],[156],{"type":48,"value":157},"TimeProvider",{"type":43,"tag":68,"props":159,"children":160},{},[161],{"type":48,"value":162},"The code is not C# \u002F .NET",{"type":43,"tag":57,"props":164,"children":166},{"id":165},"inputs",[167],{"type":48,"value":168},"Inputs",{"type":43,"tag":170,"props":171,"children":172},"table",{},[173,197],{"type":43,"tag":174,"props":175,"children":176},"thead",{},[177],{"type":43,"tag":178,"props":179,"children":180},"tr",{},[181,187,192],{"type":43,"tag":182,"props":183,"children":184},"th",{},[185],{"type":48,"value":186},"Input",{"type":43,"tag":182,"props":188,"children":189},{},[190],{"type":48,"value":191},"Required",{"type":43,"tag":182,"props":193,"children":194},{},[195],{"type":48,"value":196},"Description",{"type":43,"tag":198,"props":199,"children":200},"tbody",{},[201,220,253],{"type":43,"tag":178,"props":202,"children":203},{},[204,210,215],{"type":43,"tag":205,"props":206,"children":207},"td",{},[208],{"type":48,"value":209},"Target path",{"type":43,"tag":205,"props":211,"children":212},{},[213],{"type":48,"value":214},"Yes",{"type":43,"tag":205,"props":216,"children":217},{},[218],{"type":48,"value":219},"A file, directory, project (.csproj), or solution (.sln) to scan",{"type":43,"tag":178,"props":221,"children":222},{},[223,228,233],{"type":43,"tag":205,"props":224,"children":225},{},[226],{"type":48,"value":227},"Exclusion patterns",{"type":43,"tag":205,"props":229,"children":230},{},[231],{"type":48,"value":232},"No",{"type":43,"tag":205,"props":234,"children":235},{},[236,238,244,246,252],{"type":48,"value":237},"Glob patterns to skip (e.g., ",{"type":43,"tag":127,"props":239,"children":241},{"className":240},[],[242],{"type":48,"value":243},"**\u002Fobj\u002F**",{"type":48,"value":245},", ",{"type":43,"tag":127,"props":247,"children":249},{"className":248},[],[250],{"type":48,"value":251},"**\u002FMigrations\u002F**",{"type":48,"value":134},{"type":43,"tag":178,"props":254,"children":255},{},[256,261,265],{"type":43,"tag":205,"props":257,"children":258},{},[259],{"type":48,"value":260},"Category filter",{"type":43,"tag":205,"props":262,"children":263},{},[264],{"type":48,"value":232},{"type":43,"tag":205,"props":266,"children":267},{},[268,270,276,277,283,284,290,291,297,298,304,305],{"type":48,"value":269},"Limit to specific categories: ",{"type":43,"tag":127,"props":271,"children":273},{"className":272},[],[274],{"type":48,"value":275},"time",{"type":48,"value":245},{"type":43,"tag":127,"props":278,"children":280},{"className":279},[],[281],{"type":48,"value":282},"filesystem",{"type":48,"value":245},{"type":43,"tag":127,"props":285,"children":287},{"className":286},[],[288],{"type":48,"value":289},"environment",{"type":48,"value":245},{"type":43,"tag":127,"props":292,"children":294},{"className":293},[],[295],{"type":48,"value":296},"network",{"type":48,"value":245},{"type":43,"tag":127,"props":299,"children":301},{"className":300},[],[302],{"type":48,"value":303},"console",{"type":48,"value":245},{"type":43,"tag":127,"props":306,"children":308},{"className":307},[],[309],{"type":48,"value":310},"process",{"type":43,"tag":57,"props":312,"children":314},{"id":313},"workflow",[315],{"type":48,"value":316},"Workflow",{"type":43,"tag":318,"props":319,"children":321},"h3",{"id":320},"step-1-determine-scan-scope",[322],{"type":48,"value":323},"Step 1: Determine scan scope",{"type":43,"tag":51,"props":325,"children":326},{},[327,329,335],{"type":48,"value":328},"Resolve the target to a set of ",{"type":43,"tag":127,"props":330,"children":332},{"className":331},[],[333],{"type":48,"value":334},".cs",{"type":48,"value":336}," files:",{"type":43,"tag":64,"props":338,"children":339},{},[340,352,379,398],{"type":43,"tag":68,"props":341,"children":342},{},[343,345,350],{"type":48,"value":344},"If a ",{"type":43,"tag":127,"props":346,"children":348},{"className":347},[],[349],{"type":48,"value":334},{"type":48,"value":351}," file, scan that single file.",{"type":43,"tag":68,"props":353,"children":354},{},[355,357,362,364,370,371,377],{"type":48,"value":356},"If a directory, scan all ",{"type":43,"tag":127,"props":358,"children":360},{"className":359},[],[361],{"type":48,"value":334},{"type":48,"value":363}," files recursively (excluding ",{"type":43,"tag":127,"props":365,"children":367},{"className":366},[],[368],{"type":48,"value":369},"obj\u002F",{"type":48,"value":245},{"type":43,"tag":127,"props":372,"children":374},{"className":373},[],[375],{"type":48,"value":376},"bin\u002F",{"type":48,"value":378},").",{"type":43,"tag":68,"props":380,"children":381},{},[382,383,389,391,396],{"type":48,"value":344},{"type":43,"tag":127,"props":384,"children":386},{"className":385},[],[387],{"type":48,"value":388},".csproj",{"type":48,"value":390},", find its directory and scan ",{"type":43,"tag":127,"props":392,"children":394},{"className":393},[],[395],{"type":48,"value":334},{"type":48,"value":397}," files within.",{"type":43,"tag":68,"props":399,"children":400},{},[401,402,408,410,415],{"type":48,"value":344},{"type":43,"tag":127,"props":403,"children":405},{"className":404},[],[406],{"type":48,"value":407},".sln",{"type":48,"value":409},", parse it, find all project directories, and scan ",{"type":43,"tag":127,"props":411,"children":413},{"className":412},[],[414],{"type":48,"value":334},{"type":48,"value":416}," files across all projects.",{"type":43,"tag":51,"props":418,"children":419},{},[420,422,427,428,433],{"type":48,"value":421},"Always exclude ",{"type":43,"tag":127,"props":423,"children":425},{"className":424},[],[426],{"type":48,"value":369},{"type":48,"value":245},{"type":43,"tag":127,"props":429,"children":431},{"className":430},[],[432],{"type":48,"value":376},{"type":48,"value":434},", and any user-specified exclusion patterns.",{"type":43,"tag":318,"props":436,"children":438},{"id":437},"step-2-search-for-static-dependency-patterns",[439],{"type":48,"value":440},"Step 2: Search for static dependency patterns",{"type":43,"tag":51,"props":442,"children":443},{},[444],{"type":48,"value":445},"Scan each file for calls matching these categories:",{"type":43,"tag":170,"props":447,"children":448},{},[449,470],{"type":43,"tag":174,"props":450,"children":451},{},[452],{"type":43,"tag":178,"props":453,"children":454},{},[455,460,465],{"type":43,"tag":182,"props":456,"children":457},{},[458],{"type":48,"value":459},"Category",{"type":43,"tag":182,"props":461,"children":462},{},[463],{"type":48,"value":464},"Patterns to search for",{"type":43,"tag":182,"props":466,"children":467},{},[468],{"type":48,"value":469},"Recommended replacement",{"type":43,"tag":198,"props":471,"children":472},{},[473,546,677,735,781,847,899,957],{"type":43,"tag":178,"props":474,"children":475},{},[476,485,536],{"type":43,"tag":205,"props":477,"children":478},{},[479],{"type":43,"tag":480,"props":481,"children":482},"strong",{},[483],{"type":48,"value":484},"Time",{"type":43,"tag":205,"props":486,"children":487},{},[488,494,495,501,502,508,509,515,516,522,523,529,530],{"type":43,"tag":127,"props":489,"children":491},{"className":490},[],[492],{"type":48,"value":493},"DateTime.Now",{"type":48,"value":245},{"type":43,"tag":127,"props":496,"children":498},{"className":497},[],[499],{"type":48,"value":500},"DateTime.UtcNow",{"type":48,"value":245},{"type":43,"tag":127,"props":503,"children":505},{"className":504},[],[506],{"type":48,"value":507},"DateTime.Today",{"type":48,"value":245},{"type":43,"tag":127,"props":510,"children":512},{"className":511},[],[513],{"type":48,"value":514},"DateTimeOffset.Now",{"type":48,"value":245},{"type":43,"tag":127,"props":517,"children":519},{"className":518},[],[520],{"type":48,"value":521},"DateTimeOffset.UtcNow",{"type":48,"value":245},{"type":43,"tag":127,"props":524,"children":526},{"className":525},[],[527],{"type":48,"value":528},"Task.Delay(",{"type":48,"value":245},{"type":43,"tag":127,"props":531,"children":533},{"className":532},[],[534],{"type":48,"value":535},"new CancellationTokenSource(TimeSpan",{"type":43,"tag":205,"props":537,"children":538},{},[539,544],{"type":43,"tag":127,"props":540,"children":542},{"className":541},[],[543],{"type":48,"value":157},{"type":48,"value":545}," (.NET 8+)",{"type":43,"tag":178,"props":547,"children":548},{},[549,557,666],{"type":43,"tag":205,"props":550,"children":551},{},[552],{"type":43,"tag":480,"props":553,"children":554},{},[555],{"type":48,"value":556},"File System",{"type":43,"tag":205,"props":558,"children":559},{},[560,566,567,573,574,580,581,587,588,594,595,601,602,608,609,615,616,622,623,629,630,636,638,644,645,651,652,658,659,665],{"type":43,"tag":127,"props":561,"children":563},{"className":562},[],[564],{"type":48,"value":565},"File.ReadAllText(",{"type":48,"value":245},{"type":43,"tag":127,"props":568,"children":570},{"className":569},[],[571],{"type":48,"value":572},"File.WriteAllText(",{"type":48,"value":245},{"type":43,"tag":127,"props":575,"children":577},{"className":576},[],[578],{"type":48,"value":579},"File.Exists(",{"type":48,"value":245},{"type":43,"tag":127,"props":582,"children":584},{"className":583},[],[585],{"type":48,"value":586},"File.Delete(",{"type":48,"value":245},{"type":43,"tag":127,"props":589,"children":591},{"className":590},[],[592],{"type":48,"value":593},"File.Copy(",{"type":48,"value":245},{"type":43,"tag":127,"props":596,"children":598},{"className":597},[],[599],{"type":48,"value":600},"File.Move(",{"type":48,"value":245},{"type":43,"tag":127,"props":603,"children":605},{"className":604},[],[606],{"type":48,"value":607},"Directory.Exists(",{"type":48,"value":245},{"type":43,"tag":127,"props":610,"children":612},{"className":611},[],[613],{"type":48,"value":614},"Directory.CreateDirectory(",{"type":48,"value":245},{"type":43,"tag":127,"props":617,"children":619},{"className":618},[],[620],{"type":48,"value":621},"Directory.GetFiles(",{"type":48,"value":245},{"type":43,"tag":127,"props":624,"children":626},{"className":625},[],[627],{"type":48,"value":628},"Directory.Delete(",{"type":48,"value":245},{"type":43,"tag":127,"props":631,"children":633},{"className":632},[],[634],{"type":48,"value":635},"Path.GetTempPath(",{"type":48,"value":637},", and instance members that hit the disk (",{"type":43,"tag":127,"props":639,"children":641},{"className":640},[],[642],{"type":48,"value":643},"new FileInfo(...)",{"type":48,"value":245},{"type":43,"tag":127,"props":646,"children":648},{"className":647},[],[649],{"type":48,"value":650},"new DirectoryInfo(...)",{"type":48,"value":245},{"type":43,"tag":127,"props":653,"children":655},{"className":654},[],[656],{"type":48,"value":657},".LastWriteTimeUtc",{"type":48,"value":245},{"type":43,"tag":127,"props":660,"children":662},{"className":661},[],[663],{"type":48,"value":664},"new StreamReader(path)",{"type":48,"value":134},{"type":43,"tag":205,"props":667,"children":668},{},[669,675],{"type":43,"tag":127,"props":670,"children":672},{"className":671},[],[673],{"type":48,"value":674},"IFileSystem",{"type":48,"value":676}," (System.IO.Abstractions NuGet)",{"type":43,"tag":178,"props":678,"children":679},{},[680,688,711],{"type":43,"tag":205,"props":681,"children":682},{},[683],{"type":43,"tag":480,"props":684,"children":685},{},[686],{"type":48,"value":687},"Randomness \u002F identity",{"type":43,"tag":205,"props":689,"children":690},{},[691,697,698,704,705],{"type":43,"tag":127,"props":692,"children":694},{"className":693},[],[695],{"type":48,"value":696},"new Random(",{"type":48,"value":245},{"type":43,"tag":127,"props":699,"children":701},{"className":700},[],[702],{"type":48,"value":703},"Random.Shared",{"type":48,"value":245},{"type":43,"tag":127,"props":706,"children":708},{"className":707},[],[709],{"type":48,"value":710},"Guid.NewGuid(",{"type":43,"tag":205,"props":712,"children":713},{},[714,719,721,727,729],{"type":43,"tag":127,"props":715,"children":717},{"className":716},[],[718],{"type":48,"value":157},{"type":48,"value":720},"-style seam: inject ",{"type":43,"tag":127,"props":722,"children":724},{"className":723},[],[725],{"type":48,"value":726},"Random",{"type":48,"value":728}," \u002F an ",{"type":43,"tag":127,"props":730,"children":732},{"className":731},[],[733],{"type":48,"value":734},"IGuidProvider",{"type":43,"tag":178,"props":736,"children":737},{},[738,746,776],{"type":43,"tag":205,"props":739,"children":740},{},[741],{"type":43,"tag":480,"props":742,"children":743},{},[744],{"type":48,"value":745},"Culture \u002F serialization",{"type":43,"tag":205,"props":747,"children":748},{},[749,755,756,762,763,769,770],{"type":43,"tag":127,"props":750,"children":752},{"className":751},[],[753],{"type":48,"value":754},"CultureInfo.CurrentCulture",{"type":48,"value":245},{"type":43,"tag":127,"props":757,"children":759},{"className":758},[],[760],{"type":48,"value":761},"CultureInfo.CurrentUICulture",{"type":48,"value":245},{"type":43,"tag":127,"props":764,"children":766},{"className":765},[],[767],{"type":48,"value":768},"JsonSerializer.Serialize(",{"type":48,"value":245},{"type":43,"tag":127,"props":771,"children":773},{"className":772},[],[774],{"type":48,"value":775},"JsonSerializer.Deserialize(",{"type":43,"tag":205,"props":777,"children":778},{},[779],{"type":48,"value":780},"Pass culture\u002Foptions explicitly, or inject a serializer abstraction",{"type":43,"tag":178,"props":782,"children":783},{},[784,792,836],{"type":43,"tag":205,"props":785,"children":786},{},[787],{"type":43,"tag":480,"props":788,"children":789},{},[790],{"type":48,"value":791},"Environment",{"type":43,"tag":205,"props":793,"children":794},{},[795,801,802,808,809,815,816,822,823,829,830],{"type":43,"tag":127,"props":796,"children":798},{"className":797},[],[799],{"type":48,"value":800},"Environment.GetEnvironmentVariable(",{"type":48,"value":245},{"type":43,"tag":127,"props":803,"children":805},{"className":804},[],[806],{"type":48,"value":807},"Environment.SetEnvironmentVariable(",{"type":48,"value":245},{"type":43,"tag":127,"props":810,"children":812},{"className":811},[],[813],{"type":48,"value":814},"Environment.MachineName",{"type":48,"value":245},{"type":43,"tag":127,"props":817,"children":819},{"className":818},[],[820],{"type":48,"value":821},"Environment.UserName",{"type":48,"value":245},{"type":43,"tag":127,"props":824,"children":826},{"className":825},[],[827],{"type":48,"value":828},"Environment.CurrentDirectory",{"type":48,"value":245},{"type":43,"tag":127,"props":831,"children":833},{"className":832},[],[834],{"type":48,"value":835},"Environment.Exit(",{"type":43,"tag":205,"props":837,"children":838},{},[839,841],{"type":48,"value":840},"Custom ",{"type":43,"tag":127,"props":842,"children":844},{"className":843},[],[845],{"type":48,"value":846},"IEnvironmentProvider",{"type":43,"tag":178,"props":848,"children":849},{},[850,858,888],{"type":43,"tag":205,"props":851,"children":852},{},[853],{"type":43,"tag":480,"props":854,"children":855},{},[856],{"type":48,"value":857},"Network",{"type":43,"tag":205,"props":859,"children":860},{},[861,867,868,874,875,881,882],{"type":43,"tag":127,"props":862,"children":864},{"className":863},[],[865],{"type":48,"value":866},"new HttpClient(",{"type":48,"value":245},{"type":43,"tag":127,"props":869,"children":871},{"className":870},[],[872],{"type":48,"value":873},"HttpClient.GetAsync(",{"type":48,"value":245},{"type":43,"tag":127,"props":876,"children":878},{"className":877},[],[879],{"type":48,"value":880},"HttpClient.PostAsync(",{"type":48,"value":245},{"type":43,"tag":127,"props":883,"children":885},{"className":884},[],[886],{"type":48,"value":887},"HttpClient.SendAsync(",{"type":43,"tag":205,"props":889,"children":890},{},[891,897],{"type":43,"tag":127,"props":892,"children":894},{"className":893},[],[895],{"type":48,"value":896},"IHttpClientFactory",{"type":48,"value":898}," (built-in)",{"type":43,"tag":178,"props":900,"children":901},{},[902,910,940],{"type":43,"tag":205,"props":903,"children":904},{},[905],{"type":43,"tag":480,"props":906,"children":907},{},[908],{"type":48,"value":909},"Console",{"type":43,"tag":205,"props":911,"children":912},{},[913,919,920,926,927,933,934],{"type":43,"tag":127,"props":914,"children":916},{"className":915},[],[917],{"type":48,"value":918},"Console.WriteLine(",{"type":48,"value":245},{"type":43,"tag":127,"props":921,"children":923},{"className":922},[],[924],{"type":48,"value":925},"Console.ReadLine(",{"type":48,"value":245},{"type":43,"tag":127,"props":928,"children":930},{"className":929},[],[931],{"type":48,"value":932},"Console.Write(",{"type":48,"value":245},{"type":43,"tag":127,"props":935,"children":937},{"className":936},[],[938],{"type":48,"value":939},"Console.ReadKey(",{"type":43,"tag":205,"props":941,"children":942},{},[943,949,951],{"type":43,"tag":127,"props":944,"children":946},{"className":945},[],[947],{"type":48,"value":948},"IConsole",{"type":48,"value":950}," wrapper or ",{"type":43,"tag":127,"props":952,"children":954},{"className":953},[],[955],{"type":48,"value":956},"ILogger",{"type":43,"tag":178,"props":958,"children":959},{},[960,968,991],{"type":43,"tag":205,"props":961,"children":962},{},[963],{"type":43,"tag":480,"props":964,"children":965},{},[966],{"type":48,"value":967},"Process",{"type":43,"tag":205,"props":969,"children":970},{},[971,977,978,984,985],{"type":43,"tag":127,"props":972,"children":974},{"className":973},[],[975],{"type":48,"value":976},"Process.Start(",{"type":48,"value":245},{"type":43,"tag":127,"props":979,"children":981},{"className":980},[],[982],{"type":48,"value":983},"Process.GetCurrentProcess(",{"type":48,"value":245},{"type":43,"tag":127,"props":986,"children":988},{"className":987},[],[989],{"type":48,"value":990},"Process.GetProcessesByName(",{"type":43,"tag":205,"props":992,"children":993},{},[994,995],{"type":48,"value":840},{"type":43,"tag":127,"props":996,"children":998},{"className":997},[],[999],{"type":48,"value":1000},"IProcessRunner",{"type":43,"tag":318,"props":1002,"children":1004},{"id":1003},"step-3-aggregate-and-rank-results",[1005],{"type":48,"value":1006},"Step 3: Aggregate and rank results",{"type":43,"tag":51,"props":1008,"children":1009},{},[1010,1012,1018],{"type":48,"value":1011},"Count each call site across the entire scan scope — including the instance-member call sites covered by the rules below, not only ",{"type":43,"tag":127,"props":1013,"children":1015},{"className":1014},[],[1016],{"type":48,"value":1017},"static",{"type":48,"value":1019}," ones.",{"type":43,"tag":51,"props":1021,"children":1022},{},[1023],{"type":43,"tag":480,"props":1024,"children":1025},{},[1026],{"type":48,"value":1027},"Counting rules — inaccurate totals are the main way this report loses to an ad-hoc scan:",{"type":43,"tag":64,"props":1029,"children":1030},{},[1031,1041,1074,1122,1162,1180],{"type":43,"tag":68,"props":1032,"children":1033},{},[1034,1039],{"type":43,"tag":480,"props":1035,"children":1036},{},[1037],{"type":48,"value":1038},"One authoritative total.",{"type":48,"value":1040}," Every call site you found belongs in the category summary and the grand total. Never park real findings in an \"additional observations\" section that the totals exclude.",{"type":43,"tag":68,"props":1042,"children":1043},{},[1044,1056,1058,1064,1066,1072],{"type":43,"tag":480,"props":1045,"children":1046},{},[1047,1049,1054],{"type":48,"value":1048},"Classify by what the member touches, not by whether it is ",{"type":43,"tag":127,"props":1050,"children":1052},{"className":1051},[],[1053],{"type":48,"value":1017},{"type":48,"value":1055},".",{"type":48,"value":1057}," Instance members that reach the same untestable resource still count and belong in the matching category (",{"type":43,"tag":127,"props":1059,"children":1061},{"className":1060},[],[1062],{"type":48,"value":1063},"new FileInfo(path).LastWriteTimeUtc",{"type":48,"value":1065}," → File System; ",{"type":43,"tag":127,"props":1067,"children":1069},{"className":1068},[],[1070],{"type":48,"value":1071},"httpClient.GetAsync(...)",{"type":48,"value":1073}," → Network). Say \"hidden dependency\", not \"static\", when the member is an instance call.",{"type":43,"tag":68,"props":1075,"children":1076},{},[1077,1082,1084,1090,1091,1097,1098,1104,1106,1112,1114,1120],{"type":43,"tag":480,"props":1078,"children":1079},{},[1080],{"type":48,"value":1081},"Exclude deterministic pure helpers from the \"needs wrapping\" total.",{"type":48,"value":1083}," ",{"type":43,"tag":127,"props":1085,"children":1087},{"className":1086},[],[1088],{"type":48,"value":1089},"Path.Combine",{"type":48,"value":245},{"type":43,"tag":127,"props":1092,"children":1094},{"className":1093},[],[1095],{"type":48,"value":1096},"Path.GetExtension",{"type":48,"value":245},{"type":43,"tag":127,"props":1099,"children":1101},{"className":1100},[],[1102],{"type":48,"value":1103},"Path.GetFileName",{"type":48,"value":1105},", and ",{"type":43,"tag":127,"props":1107,"children":1109},{"className":1108},[],[1110],{"type":48,"value":1111},"Math.*",{"type":48,"value":1113},"\u002F",{"type":43,"tag":127,"props":1115,"children":1117},{"className":1116},[],[1118],{"type":48,"value":1119},"string.*",{"type":48,"value":1121}," statics take no ambient input and are trivially testable. List them, if at all, in a separate \"no action needed\" note — never as testability blockers.",{"type":43,"tag":68,"props":1123,"children":1124},{},[1125,1130,1132,1138,1139,1145,1147,1152,1154,1160],{"type":43,"tag":480,"props":1126,"children":1127},{},[1128],{"type":48,"value":1129},"Cover every category before reporting",{"type":48,"value":1131}," — time, file system, environment, network, console, process, randomness (",{"type":43,"tag":127,"props":1133,"children":1135},{"className":1134},[],[1136],{"type":48,"value":1137},"new Random()",{"type":48,"value":245},{"type":43,"tag":127,"props":1140,"children":1142},{"className":1141},[],[1143],{"type":48,"value":1144},"Guid.NewGuid()",{"type":48,"value":1146},"), culture (",{"type":43,"tag":127,"props":1148,"children":1150},{"className":1149},[],[1151],{"type":48,"value":754},{"type":48,"value":1153},"), and serialization\u002Fstatics such as ",{"type":43,"tag":127,"props":1155,"children":1157},{"className":1156},[],[1158],{"type":48,"value":1159},"JsonSerializer",{"type":48,"value":1161},". Omitting a category that is present is an under-count.",{"type":43,"tag":68,"props":1163,"children":1164},{},[1165,1178],{"type":43,"tag":480,"props":1166,"children":1167},{},[1168,1170,1176],{"type":48,"value":1169},"Give ",{"type":43,"tag":127,"props":1171,"children":1173},{"className":1172},[],[1174],{"type":48,"value":1175},"file:line",{"type":48,"value":1177}," for every occurrence",{"type":48,"value":1179}," so the user can jump straight to it.",{"type":43,"tag":68,"props":1181,"children":1182},{},[1183,1188],{"type":43,"tag":480,"props":1184,"children":1185},{},[1186],{"type":48,"value":1187},"Reconcile before publishing.",{"type":48,"value":1189}," The category totals, the top-patterns table, and the per-file table must sum to the same grand total.",{"type":43,"tag":51,"props":1191,"children":1192},{},[1193],{"type":48,"value":1194},"Produce a summary with:",{"type":43,"tag":1196,"props":1197,"children":1198},"ol",{},[1199,1209,1219,1229],{"type":43,"tag":68,"props":1200,"children":1201},{},[1202,1207],{"type":43,"tag":480,"props":1203,"children":1204},{},[1205],{"type":48,"value":1206},"Category summary",{"type":48,"value":1208}," — total call sites per category (time, filesystem, env, etc.)",{"type":43,"tag":68,"props":1210,"children":1211},{},[1212,1217],{"type":43,"tag":480,"props":1213,"children":1214},{},[1215],{"type":48,"value":1216},"Top patterns",{"type":48,"value":1218}," — the 10 most frequent individual patterns ranked by count",{"type":43,"tag":68,"props":1220,"children":1221},{},[1222,1227],{"type":43,"tag":480,"props":1223,"children":1224},{},[1225],{"type":48,"value":1226},"Most affected files",{"type":48,"value":1228}," — files with the highest number of static dependencies",{"type":43,"tag":68,"props":1230,"children":1231},{},[1232,1237,1239],{"type":43,"tag":480,"props":1233,"children":1234},{},[1235],{"type":48,"value":1236},"Existing abstractions available",{"type":48,"value":1238}," — for each category, note the recommended .NET abstraction:\n",{"type":43,"tag":64,"props":1240,"children":1241},{},[1242,1254,1267,1278,1288,1305],{"type":43,"tag":68,"props":1243,"children":1244},{},[1245,1247,1252],{"type":48,"value":1246},"Time → ",{"type":43,"tag":127,"props":1248,"children":1250},{"className":1249},[],[1251],{"type":48,"value":157},{"type":48,"value":1253}," (built-in since .NET 8)",{"type":43,"tag":68,"props":1255,"children":1256},{},[1257,1259,1265],{"type":48,"value":1258},"File system → ",{"type":43,"tag":127,"props":1260,"children":1262},{"className":1261},[],[1263],{"type":48,"value":1264},"System.IO.Abstractions",{"type":48,"value":1266}," (NuGet package)",{"type":43,"tag":68,"props":1268,"children":1269},{},[1270,1272,1277],{"type":48,"value":1271},"HTTP → ",{"type":43,"tag":127,"props":1273,"children":1275},{"className":1274},[],[1276],{"type":48,"value":896},{"type":48,"value":898},{"type":43,"tag":68,"props":1279,"children":1280},{},[1281,1283],{"type":48,"value":1282},"Environment → custom ",{"type":43,"tag":127,"props":1284,"children":1286},{"className":1285},[],[1287],{"type":48,"value":846},{"type":43,"tag":68,"props":1289,"children":1290},{},[1291,1293,1298,1300],{"type":48,"value":1292},"Console → custom ",{"type":43,"tag":127,"props":1294,"children":1296},{"className":1295},[],[1297],{"type":48,"value":948},{"type":48,"value":1299}," or ",{"type":43,"tag":127,"props":1301,"children":1303},{"className":1302},[],[1304],{"type":48,"value":956},{"type":43,"tag":68,"props":1306,"children":1307},{},[1308,1310],{"type":48,"value":1309},"Process → custom ",{"type":43,"tag":127,"props":1311,"children":1313},{"className":1312},[],[1314],{"type":48,"value":1000},{"type":43,"tag":318,"props":1316,"children":1318},{"id":1317},"step-4-present-the-report",[1319],{"type":48,"value":1320},"Step 4: Present the report",{"type":43,"tag":51,"props":1322,"children":1323},{},[1324],{"type":48,"value":1325},"Format the output as a structured report:",{"type":43,"tag":1327,"props":1328,"children":1332},"pre",{"className":1329,"code":1331,"language":48},[1330],"language-text","## Static Dependency Report\n\n**Scope**: \u003Cproject\u002Fsolution name>\n**Files scanned**: \u003Ccount>\n**Total static call sites**: \u003Ccount>\n\n### Category Summary\n| Category     | Call Sites | Recommended Abstraction |\n|-------------|-----------|------------------------|\n| Time         | 42        | TimeProvider (.NET 8+) |\n| File System  | 31        | System.IO.Abstractions |\n| Environment  | 12        | IEnvironmentProvider   |\n| ...          | ...       | ...                    |\n\n### Top 10 Patterns\n| # | Pattern             | Count | Files |\n|---|---------------------|-------|-------|\n| 1 | DateTime.UtcNow     | 28    | 14    |\n| 2 | File.ReadAllText    | 18    | 9     |\n| ...                                      |\n\n### Most Affected Files\n| File                          | Static Calls | Categories          |\n|-------------------------------|-------------|---------------------|\n| Services\u002FOrderProcessor.cs    | 12          | Time, FileSystem    |\n| ...                                                               |\n\n### Migration Priority\n1. **Time** (42 sites) — Use `TimeProvider`, zero NuGet dependencies on .NET 8+\n2. **File System** (31 sites) — Use `System.IO.Abstractions` NuGet package\n3. ...\n",[1333],{"type":43,"tag":127,"props":1334,"children":1336},{"__ignoreMap":1335},"",[1337],{"type":48,"value":1331},{"type":43,"tag":318,"props":1339,"children":1341},{"id":1340},"step-5-suggest-next-steps",[1342],{"type":48,"value":1343},"Step 5: Suggest next steps",{"type":43,"tag":51,"props":1345,"children":1346},{},[1347],{"type":48,"value":1348},"Based on the report, recommend which category to tackle first (highest count, best built-in support). Keep this to a few lines.",{"type":43,"tag":51,"props":1350,"children":1351},{},[1352,1354,1359,1360,1365],{"type":48,"value":1353},"Mention ",{"type":43,"tag":127,"props":1355,"children":1357},{"className":1356},[],[1358],{"type":48,"value":132},{"type":48,"value":1299},{"type":43,"tag":127,"props":1361,"children":1363},{"className":1362},[],[1364],{"type":48,"value":145},{"type":48,"value":1366}," only when the user's next action clearly needs them — a hand-off note, not a sales pitch. Never end an audit with promotional next-steps that dilute the findings.",{"type":43,"tag":57,"props":1368,"children":1370},{"id":1369},"validation",[1371],{"type":48,"value":1372},"Validation",{"type":43,"tag":64,"props":1374,"children":1377},{"className":1375},[1376],"contains-task-list",[1378,1398,1407,1416,1432,1441,1463,1472,1494],{"type":43,"tag":68,"props":1379,"children":1382},{"className":1380},[1381],"task-list-item",[1383,1389,1391,1396],{"type":43,"tag":1384,"props":1385,"children":1388},"input",{"disabled":1386,"type":1387},true,"checkbox",[],{"type":48,"value":1390}," All ",{"type":43,"tag":127,"props":1392,"children":1394},{"className":1393},[],[1395],{"type":48,"value":334},{"type":48,"value":1397}," files in scope were scanned (check count)",{"type":43,"tag":68,"props":1399,"children":1401},{"className":1400},[1381],[1402,1405],{"type":43,"tag":1384,"props":1403,"children":1404},{"disabled":1386,"type":1387},[],{"type":48,"value":1406}," Report includes category totals, top patterns, and affected files",{"type":43,"tag":68,"props":1408,"children":1410},{"className":1409},[1381],[1411,1414],{"type":43,"tag":1384,"props":1412,"children":1413},{"disabled":1386,"type":1387},[],{"type":48,"value":1415}," Category totals, top patterns, and per-file counts reconcile to the same grand total",{"type":43,"tag":68,"props":1417,"children":1419},{"className":1418},[1381],[1420,1423,1425,1430],{"type":43,"tag":1384,"props":1421,"children":1422},{"disabled":1386,"type":1387},[],{"type":48,"value":1424}," Every occurrence carries a ",{"type":43,"tag":127,"props":1426,"children":1428},{"className":1427},[],[1429],{"type":48,"value":1175},{"type":48,"value":1431}," location",{"type":43,"tag":68,"props":1433,"children":1435},{"className":1434},[1381],[1436,1439],{"type":43,"tag":1384,"props":1437,"children":1438},{"disabled":1386,"type":1387},[],{"type":48,"value":1440}," No findings are held outside the totals in an \"additional\" section",{"type":43,"tag":68,"props":1442,"children":1444},{"className":1443},[1381],[1445,1448,1450,1455,1456,1461],{"type":43,"tag":1384,"props":1446,"children":1447},{"disabled":1386,"type":1387},[],{"type":48,"value":1449}," Deterministic pure helpers (",{"type":43,"tag":127,"props":1451,"children":1453},{"className":1452},[],[1454],{"type":48,"value":1089},{"type":48,"value":245},{"type":43,"tag":127,"props":1457,"children":1459},{"className":1458},[],[1460],{"type":48,"value":1111},{"type":48,"value":1462},") are not counted as testability blockers",{"type":43,"tag":68,"props":1464,"children":1466},{"className":1465},[1381],[1467,1470],{"type":43,"tag":1384,"props":1468,"children":1469},{"disabled":1386,"type":1387},[],{"type":48,"value":1471}," Each detected pattern has a recommended replacement listed",{"type":43,"tag":68,"props":1473,"children":1475},{"className":1474},[1381],[1476,1479,1480,1485,1487,1492],{"type":43,"tag":1384,"props":1477,"children":1478},{"disabled":1386,"type":1387},[],{"type":48,"value":1083},{"type":43,"tag":127,"props":1481,"children":1483},{"className":1482},[],[1484],{"type":48,"value":369},{"type":48,"value":1486}," and ",{"type":43,"tag":127,"props":1488,"children":1490},{"className":1489},[],[1491],{"type":48,"value":376},{"type":48,"value":1493}," directories were excluded",{"type":43,"tag":68,"props":1495,"children":1497},{"className":1496},[1381],[1498,1501],{"type":43,"tag":1384,"props":1499,"children":1500},{"disabled":1386,"type":1387},[],{"type":48,"value":1502}," Migration priority is ordered by impact (count × ease of replacement)",{"type":43,"tag":57,"props":1504,"children":1506},{"id":1505},"common-pitfalls",[1507],{"type":48,"value":1508},"Common Pitfalls",{"type":43,"tag":170,"props":1510,"children":1511},{},[1512,1528],{"type":43,"tag":174,"props":1513,"children":1514},{},[1515],{"type":43,"tag":178,"props":1516,"children":1517},{},[1518,1523],{"type":43,"tag":182,"props":1519,"children":1520},{},[1521],{"type":48,"value":1522},"Pitfall",{"type":43,"tag":182,"props":1524,"children":1525},{},[1526],{"type":48,"value":1527},"Solution",{"type":43,"tag":198,"props":1529,"children":1530},{},[1531,1568,1581,1601,1650,1671,1684,1703],{"type":43,"tag":178,"props":1532,"children":1533},{},[1534,1546],{"type":43,"tag":205,"props":1535,"children":1536},{},[1537,1539,1544],{"type":48,"value":1538},"Scanning ",{"type":43,"tag":127,"props":1540,"children":1542},{"className":1541},[],[1543],{"type":48,"value":369},{"type":48,"value":1545}," or generated code",{"type":43,"tag":205,"props":1547,"children":1548},{},[1549,1550,1555,1556,1561,1562],{"type":48,"value":421},{"type":43,"tag":127,"props":1551,"children":1553},{"className":1552},[],[1554],{"type":48,"value":369},{"type":48,"value":245},{"type":43,"tag":127,"props":1557,"children":1559},{"className":1558},[],[1560],{"type":48,"value":376},{"type":48,"value":1105},{"type":43,"tag":127,"props":1563,"children":1565},{"className":1564},[],[1566],{"type":48,"value":1567},"*.Designer.cs",{"type":43,"tag":178,"props":1569,"children":1570},{},[1571,1576],{"type":43,"tag":205,"props":1572,"children":1573},{},[1574],{"type":48,"value":1575},"Counting wrapped calls as statics",{"type":43,"tag":205,"props":1577,"children":1578},{},[1579],{"type":48,"value":1580},"Check if the call is behind an interface or injected service before counting",{"type":43,"tag":178,"props":1582,"children":1583},{},[1584,1589],{"type":43,"tag":205,"props":1585,"children":1586},{},[1587],{"type":48,"value":1588},"Missing statics inside lambdas\u002FLINQ",{"type":43,"tag":205,"props":1590,"children":1591},{},[1592,1594,1599],{"type":48,"value":1593},"Search covers all code within ",{"type":43,"tag":127,"props":1595,"children":1597},{"className":1596},[],[1598],{"type":48,"value":334},{"type":48,"value":1600}," files, including lambdas",{"type":43,"tag":178,"props":1602,"children":1603},{},[1604,1616],{"type":43,"tag":205,"props":1605,"children":1606},{},[1607,1609,1614],{"type":48,"value":1608},"Recommending ",{"type":43,"tag":127,"props":1610,"children":1612},{"className":1611},[],[1613],{"type":48,"value":157},{"type":48,"value":1615}," on \u003C .NET 8",{"type":43,"tag":205,"props":1617,"children":1618},{},[1619,1621,1627,1629,1634,1636,1642,1644],{"type":48,"value":1620},"Check ",{"type":43,"tag":127,"props":1622,"children":1624},{"className":1623},[],[1625],{"type":48,"value":1626},"TargetFramework",{"type":48,"value":1628}," in ",{"type":43,"tag":127,"props":1630,"children":1632},{"className":1631},[],[1633],{"type":48,"value":388},{"type":48,"value":1635}," — if \u003C net8.0, recommend ",{"type":43,"tag":127,"props":1637,"children":1639},{"className":1638},[],[1640],{"type":48,"value":1641},"NodaTime.IClock",{"type":48,"value":1643}," or custom ",{"type":43,"tag":127,"props":1645,"children":1647},{"className":1646},[],[1648],{"type":48,"value":1649},"ISystemClock",{"type":43,"tag":178,"props":1651,"children":1652},{},[1653,1658],{"type":43,"tag":205,"props":1654,"children":1655},{},[1656],{"type":48,"value":1657},"Ignoring test projects",{"type":43,"tag":205,"props":1659,"children":1660},{},[1661,1663,1669],{"type":48,"value":1662},"Only scan production code — exclude ",{"type":43,"tag":127,"props":1664,"children":1666},{"className":1665},[],[1667],{"type":48,"value":1668},"*.Tests.csproj",{"type":48,"value":1670}," projects from the scan",{"type":43,"tag":178,"props":1672,"children":1673},{},[1674,1679],{"type":43,"tag":205,"props":1675,"children":1676},{},[1677],{"type":48,"value":1678},"Under-counting by relegating findings",{"type":43,"tag":205,"props":1680,"children":1681},{},[1682],{"type":48,"value":1683},"Real call sites belong in the category totals, not in a trailing \"also noticed\" paragraph that the totals ignore",{"type":43,"tag":178,"props":1685,"children":1686},{},[1687,1692],{"type":43,"tag":205,"props":1688,"children":1689},{},[1690],{"type":48,"value":1691},"Calling an instance member a static",{"type":43,"tag":205,"props":1693,"children":1694},{},[1695,1701],{"type":43,"tag":127,"props":1696,"children":1698},{"className":1697},[],[1699],{"type":48,"value":1700},"new FileInfo(p).LastWriteTimeUtc",{"type":48,"value":1702}," is an instance call but still a hidden file-system dependency — count it under File System and describe it accurately",{"type":43,"tag":178,"props":1704,"children":1705},{},[1706,1716],{"type":43,"tag":205,"props":1707,"children":1708},{},[1709,1711],{"type":48,"value":1710},"Recommending a wrapper for ",{"type":43,"tag":127,"props":1712,"children":1714},{"className":1713},[],[1715],{"type":48,"value":1089},{"type":43,"tag":205,"props":1717,"children":1718},{},[1719],{"type":48,"value":1720},"Pure, deterministic helpers need no seam; listing them as blockers makes the recommendations wrong",{"items":1722,"total":1825},[1723,1736,1751,1769,1783,1801,1811],{"slug":1724,"name":1724,"fn":1725,"description":1726,"org":1727,"tags":1728,"stars":25,"repoUrl":26,"updatedAt":1735},"analyzing-dotnet-performance","analyze .NET code for performance anti-patterns","Scans .NET code for ~50 performance anti-patterns across async, memory, strings, collections, LINQ, regex, serialization, and I\u002FO with tiered severity classification. Use when analyzing .NET code for optimization opportunities, reviewing hot paths, or auditing allocation-heavy patterns.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1729,1730,1731,1732],{"name":17,"slug":18,"type":15},{"name":20,"slug":21,"type":15},{"name":23,"slug":24,"type":15},{"name":1733,"slug":1734,"type":15},"Performance","performance","2026-07-12T08:23:25.400375",{"slug":1737,"name":1737,"fn":1738,"description":1739,"org":1740,"tags":1741,"stars":25,"repoUrl":26,"updatedAt":1750},"android-tombstone-symbolication","symbolicate .NET runtime frames in Android tombstones","Symbolicate the .NET runtime frames in an Android tombstone file. Extracts BuildIds and PC offsets from the native backtrace, downloads debug symbols from the Microsoft symbol server, and runs llvm-symbolizer to produce function names with source file and line numbers. USE FOR triaging a .NET MAUI or Mono Android app crash from a tombstone, resolving native backtrace frames in libmonosgen-2.0.so or libcoreclr.so to .NET runtime source code, or investigating SIGABRT, SIGSEGV, or other native signals originating from the .NET runtime on Android. DO NOT USE FOR pure Java\u002FKotlin crashes, managed .NET exceptions that are already captured in logcat, or iOS crash logs. INVOKES Symbolicate-Tombstone.ps1 script, llvm-symbolizer, Microsoft symbol server.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1742,1743,1746,1747],{"name":17,"slug":18,"type":15},{"name":1744,"slug":1745,"type":15},"Android","android",{"name":23,"slug":24,"type":15},{"name":1748,"slug":1749,"type":15},"Microsoft","microsoft","2026-07-12T08:23:21.595572",{"slug":1752,"name":1752,"fn":1753,"description":1754,"org":1755,"tags":1756,"stars":25,"repoUrl":26,"updatedAt":1768},"apple-crash-symbolication","symbolicate .NET runtime frames in crash logs","Symbolicate .NET runtime frames in Apple platform .ips crash logs (iOS, tvOS, Mac Catalyst, macOS). Extracts UUIDs and addresses from the native backtrace, locates dSYM debug symbols, and runs atos to produce function names with source file and line numbers. Automatically downloads .dwarf symbols from the Microsoft symbol server using Mach-O UUIDs. USE FOR triaging a .NET MAUI or Mono app crash from an .ips file on any Apple platform, resolving native backtrace frames in libcoreclr or libmonosgen-2.0 to .NET runtime source code, retrieving .ips crash logs from a connected iOS device or iPhone, or investigating EXC_CRASH, EXC_BAD_ACCESS, SIGABRT, or SIGSEGV originating from the .NET runtime. DO NOT USE FOR pure Swift\u002FObjective-C crashes with no .NET components, or Android tombstone files. INVOKES Symbolicate-Crash.ps1 script, atos, dwarfdump, idevicecrashreport.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1757,1758,1759,1762,1765],{"name":17,"slug":18,"type":15},{"name":23,"slug":24,"type":15},{"name":1760,"slug":1761,"type":15},"iOS","ios",{"name":1763,"slug":1764,"type":15},"macOS","macos",{"name":1766,"slug":1767,"type":15},"Observability","observability","2026-07-12T08:23:20.369986",{"slug":1770,"name":1770,"fn":1771,"description":1772,"org":1773,"tags":1774,"stars":25,"repoUrl":26,"updatedAt":1782},"assertion-quality","evaluate assertion quality in test suites","Analyzes the variety and depth of assertions across test suites in any language. Use when the user asks to evaluate assertion quality, find shallow tests, identify assertion-free tests (no assertions or only trivial ones like Assert.IsNotNull \u002F toBeTruthy()), flag self-referential or tautological assertions, measure assertion diversity, or audit whether tests verify different facets of behavior. Polyglot: .NET, Python, TS\u002FJS, Java, Go, Ruby, Rust, Swift, Kotlin, PowerShell, C++. DO NOT USE FOR: writing new tests (use code-testing-agent \u002F writing-mstest-tests), mutation reasoning about whether tests would catch a bug (use test-gap-analysis), or a general severity-ranked anti-pattern audit (use test-anti-patterns), fixing or rewriting assertions, or writing, fixing, or modernizing MSTest tests, assertions, or attributes (use writing-mstest-tests).",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1775,1776,1779],{"name":20,"slug":21,"type":15},{"name":1777,"slug":1778,"type":15},"QA","qa",{"name":1780,"slug":1781,"type":15},"Testing","testing","2026-07-12T08:23:51.277743",{"slug":1784,"name":1784,"fn":1785,"description":1786,"org":1787,"tags":1788,"stars":25,"repoUrl":26,"updatedAt":1800},"author-component","create and review Blazor components","Create or review Blazor components (.razor files) with correct architecture. USE FOR: writing new Blazor components that do NOT involve JavaScript interop, implementing parameters and EventCallback, RenderFragment slots, component lifecycle (OnInitializedAsync, OnParametersSet), async patterns, IAsyncDisposable, CancellationToken, CSS isolation, code-behind. DO NOT USE FOR: creating new projects (use create-blazor-project), JavaScript interop or calling browser APIs from Blazor (use use-js-interop), forms and validation (use collect-user-input), prerendering issues (use support-prerendering), HTTP data fetching patterns (use fetch-and-send-data), coordinating state between unrelated components (use coordinate-components).\n",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1789,1790,1793,1794,1797],{"name":17,"slug":18,"type":15},{"name":1791,"slug":1792,"type":15},"Blazor","blazor",{"name":13,"slug":14,"type":15},{"name":1795,"slug":1796,"type":15},"UI Components","ui-components",{"name":1798,"slug":1799,"type":15},"Web Development","web-development","2026-07-15T06:03:29.216359",{"slug":1802,"name":1802,"fn":1803,"description":1804,"org":1805,"tags":1806,"stars":25,"repoUrl":26,"updatedAt":1810},"binlog-failure-analysis","analyze MSBuild binary logs","Analyze MSBuild binary logs to diagnose build failures. USE FOR: build errors that are unclear from console output, diagnosing cascading failures across multi-project builds, tracing MSBuild target execution order, and generally any MSBuild build issues. Requires an existing .binlog file. DO NOT USE FOR: generating binlogs (use binlog-generation), non-MSBuild build systems.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1807,1808,1809],{"name":20,"slug":21,"type":15},{"name":23,"slug":24,"type":15},{"name":1748,"slug":1749,"type":15},"2026-07-12T08:21:34.637923",{"slug":1812,"name":1812,"fn":1813,"description":1814,"org":1815,"tags":1816,"stars":25,"repoUrl":26,"updatedAt":1824},"binlog-generation","generate MSBuild binary logs for diagnostics","Generate MSBuild binary logs (binlogs) for build diagnostics and analysis. USE FOR: adding \u002Fbl:{} to any dotnet build, test, pack, publish, or restore command to capture a full build execution trace, prerequisite for binlog-failure-analysis and build-perf-diagnostics skills, enabling post-build investigation of errors or performance. Requires MSBuild 17.8+ \u002F .NET 8 SDK+ for {} placeholder; PowerShell needs -bl:{{}}. DO NOT USE FOR: non-MSBuild build systems (npm, Maven, CMake), analyzing an existing binlog (use binlog-failure-analysis instead).",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1817,1820,1821],{"name":1818,"slug":1819,"type":15},"Build","build",{"name":23,"slug":24,"type":15},{"name":1822,"slug":1823,"type":15},"Engineering","engineering","2026-07-19T05:38:19.340791",96,{"items":1827,"total":1932},[1828,1840,1847,1854,1862,1868,1876,1882,1888,1898,1911,1922],{"slug":1829,"name":1829,"fn":1830,"description":1831,"org":1832,"tags":1833,"stars":1837,"repoUrl":1838,"updatedAt":1839},"multithreaded-task-migration","migrate MSBuild tasks to multithreaded mode","Guide for migrating MSBuild tasks to multithreaded mode support, including compatibility red-team review. Use this when converting tasks to thread-safe versions, implementing IMultiThreadableTask, adding TaskEnvironment support, or auditing migrations for behavioral compatibility.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1834,1835,1836],{"name":17,"slug":18,"type":15},{"name":1822,"slug":1823,"type":15},{"name":1733,"slug":1734,"type":15},5535,"https:\u002F\u002Fgithub.com\u002Fdotnet\u002Fmsbuild","2026-07-22T05:37:33.965588",{"slug":1724,"name":1724,"fn":1725,"description":1726,"org":1841,"tags":1842,"stars":25,"repoUrl":26,"updatedAt":1735},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1843,1844,1845,1846],{"name":17,"slug":18,"type":15},{"name":20,"slug":21,"type":15},{"name":23,"slug":24,"type":15},{"name":1733,"slug":1734,"type":15},{"slug":1737,"name":1737,"fn":1738,"description":1739,"org":1848,"tags":1849,"stars":25,"repoUrl":26,"updatedAt":1750},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1850,1851,1852,1853],{"name":17,"slug":18,"type":15},{"name":1744,"slug":1745,"type":15},{"name":23,"slug":24,"type":15},{"name":1748,"slug":1749,"type":15},{"slug":1752,"name":1752,"fn":1753,"description":1754,"org":1855,"tags":1856,"stars":25,"repoUrl":26,"updatedAt":1768},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1857,1858,1859,1860,1861],{"name":17,"slug":18,"type":15},{"name":23,"slug":24,"type":15},{"name":1760,"slug":1761,"type":15},{"name":1763,"slug":1764,"type":15},{"name":1766,"slug":1767,"type":15},{"slug":1770,"name":1770,"fn":1771,"description":1772,"org":1863,"tags":1864,"stars":25,"repoUrl":26,"updatedAt":1782},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1865,1866,1867],{"name":20,"slug":21,"type":15},{"name":1777,"slug":1778,"type":15},{"name":1780,"slug":1781,"type":15},{"slug":1784,"name":1784,"fn":1785,"description":1786,"org":1869,"tags":1870,"stars":25,"repoUrl":26,"updatedAt":1800},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1871,1872,1873,1874,1875],{"name":17,"slug":18,"type":15},{"name":1791,"slug":1792,"type":15},{"name":13,"slug":14,"type":15},{"name":1795,"slug":1796,"type":15},{"name":1798,"slug":1799,"type":15},{"slug":1802,"name":1802,"fn":1803,"description":1804,"org":1877,"tags":1878,"stars":25,"repoUrl":26,"updatedAt":1810},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1879,1880,1881],{"name":20,"slug":21,"type":15},{"name":23,"slug":24,"type":15},{"name":1748,"slug":1749,"type":15},{"slug":1812,"name":1812,"fn":1813,"description":1814,"org":1883,"tags":1884,"stars":25,"repoUrl":26,"updatedAt":1824},{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1885,1886,1887],{"name":1818,"slug":1819,"type":15},{"name":23,"slug":24,"type":15},{"name":1822,"slug":1823,"type":15},{"slug":1889,"name":1889,"fn":1890,"description":1891,"org":1892,"tags":1893,"stars":25,"repoUrl":26,"updatedAt":1897},"build-parallelism","optimize MSBuild build parallelism","Diagnose and fix under-parallelized MSBuild builds. USE WHEN a multi-project solution build is slower than expected, doesn't speed up when you add cores, pegs a single core while others idle, or you want to know why `-m` isn't helping. Note: `\u002Fmaxcpucount` default is 1 (sequential) — always pass `-m` for parallel builds. Covers finding the critical path (longest serial ProjectReference chain), graph build (`\u002Fgraph`), BuildInParallel, and solution filters (`.slnf`). DO NOT USE FOR: single-project builds, incremental issues (use incremental-build), compilation slowness inside one project (use build-perf-diagnostics), non-MSBuild build systems.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1894,1895,1896],{"name":17,"slug":18,"type":15},{"name":1822,"slug":1823,"type":15},{"name":1733,"slug":1734,"type":15},"2026-07-19T05:38:18.364937",{"slug":1899,"name":1899,"fn":1900,"description":1901,"org":1902,"tags":1903,"stars":25,"repoUrl":26,"updatedAt":1910},"build-perf-baseline","establish and optimize build performance baselines","Establish build performance baselines and apply systematic optimization techniques. USE FOR: diagnosing slow builds, establishing before\u002Fafter measurements (cold, warm, no-op scenarios), applying optimization strategies like MSBuild Server, static graph builds, artifacts output, and dependency graph trimming. Start here before diving into build-perf-diagnostics, incremental-build, or build-parallelism. DO NOT USE FOR: non-MSBuild build systems, detailed bottleneck analysis (use build-perf-diagnostics after baselining).",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1904,1905,1908,1909],{"name":1822,"slug":1823,"type":15},{"name":1906,"slug":1907,"type":15},"Monitoring","monitoring",{"name":1733,"slug":1734,"type":15},{"name":1780,"slug":1781,"type":15},"2026-07-12T08:21:35.865649",{"slug":1912,"name":1912,"fn":1913,"description":1914,"org":1915,"tags":1916,"stars":25,"repoUrl":26,"updatedAt":1921},"build-perf-diagnostics","diagnose MSBuild build performance bottlenecks","Diagnose MSBuild build performance bottlenecks using binary log analysis. USE FOR: identifying why builds are slow by analyzing binlog performance summaries, detecting ResolveAssemblyReference (RAR) taking >5s, Roslyn analyzers consuming >30% of Csc time, single targets dominating >50% of build time, node utilization below 80%, excessive Copy tasks, NuGet restore running every build. Covers timeline analysis, Target\u002FTask Performance Summary interpretation, and 7 common bottleneck categories. Use after build-perf-baseline has established measurements. DO NOT USE FOR: establishing initial baselines (use build-perf-baseline first), fixing incremental build issues (use incremental-build), parallelism tuning (use build-parallelism), non-MSBuild build systems.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1917,1918,1919,1920],{"name":17,"slug":18,"type":15},{"name":23,"slug":24,"type":15},{"name":1822,"slug":1823,"type":15},{"name":1733,"slug":1734,"type":15},"2026-07-12T08:21:40.961722",{"slug":1923,"name":1923,"fn":1924,"description":1925,"org":1926,"tags":1927,"stars":25,"repoUrl":26,"updatedAt":1931},"check-bin-obj-clash","detect MSBuild output path conflicts","Detects MSBuild projects with conflicting OutputPath or IntermediateOutputPath. USE FOR: builds failing with 'Cannot create a file when that file already exists', 'The process cannot access the file because it is being used by another process', intermittent build failures that succeed on retry, or missing\u002Foverwritten outputs in multi-project or multi-targeting builds where bin\u002Fobj (or project.assets.json) collide. Common causes: shared OutputPath, missing AppendTargetFrameworkToOutputPath, extra global properties (e.g. PublishReadyToRun), or SetTargetFramework on a ProjectReference to a single-targeting project. DO NOT USE FOR: file access errors unrelated to MSBuild (OS-level locking), single-project single-TFM builds, non-MSBuild build systems.",{"slug":8,"name":9,"logoUrl":10,"githubOrg":8},[1928,1929,1930],{"name":23,"slug":24,"type":15},{"name":1822,"slug":1823,"type":15},{"name":1777,"slug":1778,"type":15},"2026-07-19T05:38:14.336279",144]