Skip to content

Improve OpenAPI parse + codegen throughput by removing avoidable allocations and repeated regex work#937

Merged
christianhelle merged 4 commits into
mainfrom
copilot/improve-refitter-performance-again
Mar 5, 2026
Merged

Improve OpenAPI parse + codegen throughput by removing avoidable allocations and repeated regex work#937
christianhelle merged 4 commits into
mainfrom
copilot/improve-refitter-performance-again

Conversation

Copilot AI commented Mar 5, 2026

Copy link
Copy Markdown
Contributor

Description:

Refitter’s parse/generation pipeline accumulated avoidable per-operation and per-document overhead. This PR reduces hot-path CPU/allocation cost in Refitter.Core without changing generated API shape.

  • Core generation hot paths

    • Cached IsApiResponseType regexes (static readonly Regex) and reused the computed result per operation.
    • Replaced Accept-header content-type dedup (GroupBy/SelectMany/Distinct) with a single HashSet<string> pass.
    • Updated multi-interface generators to use the optimized header path.
  • Contract sanitization + filtering

    • Reworked SanitizeGeneratedContracts from split/per-line regex matching to a single precompiled multiline regex replace.
    • Reduced path-filter matching overhead by avoiding delegate-heavy TrueForAll flow in favor of a tight loop.
  • Schema cleanup

    • Compiled keepSchemaPatterns once in SchemaCleaner constructor and reused compiled regexes during traversal.
  • OpenAPI load/merge path

    • Reused a static decompression-enabled HttpClient instead of creating one per request.
    • Optimized merge loops (for over Skip(1)) and tag dedup (HashSet instead of repeated All scans).
    • Made HTTP/YAML detection case-insensitive (OrdinalIgnoreCase) to avoid extension/protocol casing misses.
  • Behavior safety coverage

    • Added regression assertions for uppercase YAML extensions (.YAML, .YML).
    • Extended inline-json-converter test to assert removal of fully-qualified JsonStringEnumConverter attributes as well.
  • Implementation excerpt

private static readonly Regex HttpResponseMessageTypeRegex =
    new("(Task|IObservable)<HttpResponseMessage>", RegexOptions.Compiled, TimeSpan.FromSeconds(1));

private static readonly Regex ApiResponseTypeRegex =
    new("(Task|IObservable)<(I)?ApiResponse(<[\\w<>]+>)?>", RegexOptions.Compiled, TimeSpan.FromSeconds(1));

protected static bool IsApiResponseType(string typeName) =>
    HttpResponseMessageTypeRegex.IsMatch(typeName) || ApiResponseTypeRegex.IsMatch(typeName);

Example OpenAPI Specifications:

openapi: 3.0.0
info:
  title: Perf sample
  version: 1.0.0
paths:
  /users/{id}:
    get:
      operationId: GetUser
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: ok
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/User'
components:
  schemas:
    User:
      type: object
      properties:
        id:
          type: string

Example generated Refit interface

public partial interface IPerfSample
{
    [Get("/users/{id}")]
    Task<User> GetUser(string id);
}

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • collector.exceptionless.io
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/9f70c89a00074e64b86b7fa13cef06b4 (dns block)
    • Triggering command: /usr/bin/dotnet dotnet src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests.dll --no-progress (dns block)
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter/bin/Release/net9.0/refitter /home/REDACTED/work/refitter/refitter/src/Refitter/bin/Release/net9.0/refitter ./test/OpenAPI/v3.0/petstore.json --output /tmp/refitter-perf-output.cs --namespace PerfCheck (dns block)
  • config.exceptionless.io
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/9f70c89a00074e64b86b7fa13cef06b4 (dns block)
    • Triggering command: /usr/bin/dotnet dotnet src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests.dll --no-progress (dns block)
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/5559119fb74b4ddb8878b6555f6685d8 /var/lib/dpkg/info/libpam-modules-bin.list /var/lib/dpkg/info/libthai-data.list /var/lib/dpkg/info/libzip4t64:amd64.list /var/lib/dpkg/info/libtirpc-common.list /var/lib/dpkg/info/crun.list /var/lib/dpkg/info/lld-18.list /var/lib/dpkg/info/libacl1:amd64.list (dns block)
  • developers.intellihr.io
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/9f70c89a00074e64b86b7fa13cef06b4 (dns block)
    • Triggering command: /usr/bin/dotnet dotnet src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests.dll --no-progress (dns block)
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/5559119fb74b4ddb8878b6555f6685d8 /var/lib/dpkg/info/libpam-modules-bin.list /var/lib/dpkg/info/libthai-data.list /var/lib/dpkg/info/libzip4t64:amd64.list /var/lib/dpkg/info/libtirpc-common.list /var/lib/dpkg/info/crun.list /var/lib/dpkg/info/lld-18.list /var/lib/dpkg/info/libacl1:amd64.list (dns block)
  • heartbeat.exceptionless.io
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/9f70c89a00074e64b86b7fa13cef06b4 (dns block)
    • Triggering command: /usr/bin/dotnet dotnet src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests.dll --no-progress (dns block)
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter/bin/Release/net9.0/refitter /home/REDACTED/work/refitter/refitter/src/Refitter/bin/Release/net9.0/refitter ./test/OpenAPI/v3.0/petstore.json --output /tmp/refitter-perf-output.cs --namespace PerfCheck (dns block)
  • petstore.swagger.io
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/9f70c89a00074e64b86b7fa13cef06b4 (dns block)
    • Triggering command: /usr/bin/dotnet dotnet src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests.dll --no-progress (dns block)
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/5559119fb74b4ddb8878b6555f6685d8 /var/lib/dpkg/info/libpam-modules-bin.list /var/lib/dpkg/info/libthai-data.list /var/lib/dpkg/info/libzip4t64:amd64.list /var/lib/dpkg/info/libtirpc-common.list /var/lib/dpkg/info/crun.list /var/lib/dpkg/info/lld-18.list /var/lib/dpkg/info/libacl1:amd64.list (dns block)
  • petstore3.swagger.io
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/9f70c89a00074e64b86b7fa13cef06b4 (dns block)
    • Triggering command: /usr/bin/dotnet dotnet src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests.dll --no-progress (dns block)
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests /home/REDACTED/work/refitter/refitter/src/Refitter.Tests/bin/Release/net10.0/Refitter.Tests --server dotnettestcli --dotnet-test-pipe /tmp/5559119fb74b4ddb8878b6555f6685d8 /var/lib/dpkg/info/libpam-modules-bin.list /var/lib/dpkg/info/libthai-data.list /var/lib/dpkg/info/libzip4t64:amd64.list /var/lib/dpkg/info/libtirpc-common.list /var/lib/dpkg/info/crun.list /var/lib/dpkg/info/lld-18.list /var/lib/dpkg/info/libacl1:amd64.list (dns block)
  • westeurope-5.in.applicationinsights.azure.com
    • Triggering command: /home/REDACTED/work/refitter/refitter/src/Refitter/bin/Release/net9.0/refitter /home/REDACTED/work/refitter/refitter/src/Refitter/bin/Release/net9.0/refitter ./test/OpenAPI/v3.0/petstore.json --output /tmp/refitter-perf-output.cs --namespace PerfCheck (dns block)

If you need me to access, download, or install something from one of these locations, you can either:


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Co-authored-by: christianhelle <710400+christianhelle@users.noreply.github.com>
Copilot AI changed the title [WIP] Improve performance of Refitter when generating code Improve OpenAPI parse + codegen throughput by removing avoidable allocations and repeated regex work Mar 5, 2026
@christianhelle
christianhelle marked this pull request as ready for review March 5, 2026 11:32
Copilot AI review requested due to automatic review settings March 5, 2026 11:32

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR optimizes Refitter’s OpenAPI load/merge and C# code-generation hot paths by reducing per-operation allocations and repeated regex work, while aiming to keep the generated API surface unchanged.

Changes:

  • Reduced overhead in interface generation (cached ApiResponse-type checks; optimized Accept header dedup; updated multi-interface generators to use the optimized path).
  • Reduced regex/iteration overhead in contract sanitization and path filtering.
  • Optimized OpenAPI loading/merging (static decompression-enabled HttpClient, faster merge loops, case-insensitive HTTP/YAML detection) and added targeted regressions.

Reviewed changes

Copilot reviewed 8 out of 8 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/Refitter.Tests/OpenApiDocumentFactoryTests.cs Adds regression coverage for uppercase .YAML/.YML format detection.
src/Refitter.Tests/Examples/InlineJsonConvertersTests.cs Extends assertions to ensure fully-qualified JsonStringEnumConverter attributes are removed when disabled.
src/Refitter.Core/SchemaCleaner.cs Compiles keep-schema regex patterns once in the constructor and reuses them during traversal.
src/Refitter.Core/RefitMultipleInterfaceGenerator.cs Updates header generation call to the optimized signature/path.
src/Refitter.Core/RefitMultipleInterfaceByTagGenerator.cs Updates header generation call to the optimized signature/path.
src/Refitter.Core/RefitInterfaceGenerator.cs Adds static cached regexes for ApiResponse detection and replaces Accept header dedup with a single-pass set.
src/Refitter.Core/RefitGenerator.cs Uses a precompiled multiline regex for contract sanitization and streamlines path-filter matching.
src/Refitter.Core/OpenApiDocumentFactory.cs Introduces a shared decompressing HttpClient, optimizes merge loops/tag dedup, and makes HTTP/YAML detection case-insensitive.
Comments suppressed due to low confidence (2)

src/Refitter.Core/RefitInterfaceGenerator.cs:271

  • uniqueContentTypes is a HashSet, and its enumeration order isn’t guaranteed. Since this is fed directly into string.Join for the generated Accept header, the emitted header value order can become nondeterministic across runs/frameworks, which is undesirable for code generation and can cause noisy diffs. Consider preserving insertion order (e.g., track a List<string> plus a membership HashSet) or sorting the set before joining.
            var uniqueContentTypes = new HashSet<string>(StringComparer.OrdinalIgnoreCase);
            foreach (var response in operations.Value.Responses.Values)
            {
                foreach (var contentType in response.Content.Keys)
                {
                    uniqueContentTypes.Add(contentType);
                }
            }

            if (uniqueContentTypes.Any())
            {
                headers.Add($"\"Accept: {string.Join(", ", uniqueContentTypes)}\"");
            }

src/Refitter.Core/OpenApiDocumentFactory.cs:18

  • The private static field is named HttpClient, which shadows the HttpClient type name within this class and makes the code harder to read/maintain (e.g., future additions can’t reference the type unqualified). Consider renaming it to something like sharedHttpClient / decompressingHttpClient to avoid the name collision.
    private static readonly HttpClient HttpClient = new(
        new HttpClientHandler
        {
            AutomaticDecompression = DecompressionMethods.GZip | DecompressionMethods.Deflate
        });

You can also share your feedback on Copilot code review. Take the survey.

@codecov

codecov Bot commented Mar 5, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 96.61017% with 2 lines in your changes missing coverage. Please review.
✅ Project coverage is 89.41%. Comparing base (87e227d) to head (c97f994).
⚠️ Report is 365 commits behind head on main.

Files with missing lines Patch % Lines
src/Refitter.Core/OpenApiDocumentFactory.cs 88.88% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #937   +/-   ##
=======================================
  Coverage   89.41%   89.41%           
=======================================
  Files          26       26           
  Lines        1511     1521   +10     
=======================================
+ Hits         1351     1360    +9     
  Misses         85       85           
- Partials       75       76    +1     
Flag Coverage Δ
unittests 89.41% <96.61%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@christianhelle
christianhelle force-pushed the copilot/improve-refitter-performance-again branch from 31834d1 to c97f994 Compare March 5, 2026 12:37
@sonarqubecloud

sonarqubecloud Bot commented Mar 5, 2026

Copy link
Copy Markdown

@christianhelle
christianhelle merged commit fe2f428 into main Mar 5, 2026
13 checks passed
@christianhelle
christianhelle deleted the copilot/improve-refitter-performance-again branch March 5, 2026 13:20
@christianhelle christianhelle added the enhancement New feature, bug fix, or request label May 2, 2026
hwinther pushed a commit to hwinther/test that referenced this pull request May 6, 2026
Updated [refitter](https://github.com/christianhelle/refitter) from
1.7.1 to 2.0.0.

<details>
<summary>Release notes</summary>

_Sourced from [refitter's
releases](https://github.com/christianhelle/refitter/releases)._

## 2.0.0

## What's Changed

* Fix numeric format with pattern quirk - infer type from format for all
numeric types by @​Copilot in
christianhelle/refitter#869
* Read group documentation from document tags. by @​DJ4ddi in
christianhelle/refitter#887
* Fix null reference and XML escaping in XmlDocumentationGenerator by
@​Copilot in christianhelle/refitter#890
* Fix build workflow: add dotnet restore before dotnet msbuild in
Prepare step by @​Copilot in
christianhelle/refitter#892
christianhelle/refitter#895
* Fix MSBuild workflow by @​christianhelle in
christianhelle/refitter#898
* Add support for generating a single client from multiple OpenAPI
specifications by @​Copilot in
christianhelle/refitter#904
* Migrate from Microsoft.OpenApi.Readers 1.x to Microsoft.OpenApi 3.x by
@​vgmello in christianhelle/refitter#907
* Improve Smoke Tests execution time by @​christianhelle in
christianhelle/refitter#915
* Fix #​580: Nullable strings marked correctly by @​christianhelle in
christianhelle/refitter#921
* Fix #​672: MultipleInterfaces ByTag method naming scoped per-interface
by @​christianhelle in
christianhelle/refitter#922
* Fix #​635: Refactor source generator to use context.AddSource() by
@​christianhelle in christianhelle/refitter#923
* Add custom format mappings configuration by @​christianhelle in
christianhelle/refitter#927
* Fix multipart form-data parameter extraction by @​christianhelle in
christianhelle/refitter#928
christianhelle/refitter#911
christianhelle/refitter#902
* Fix smoke tests: --interface-only variant missing using directive for
contract types by @​Copilot in
christianhelle/refitter#933
* Fix SonarCloud Code Quality Issues by @​Copilot in
christianhelle/refitter#932
* Add debug logging for source generator when searching for .refitter
files by @​codymullins in
christianhelle/refitter#743
* Fix: Base type not generated for types using oneOf with discriminator
by @​Copilot in christianhelle/refitter#906
* Add option for Method Level Authorization header attribute by
@​Roflincopter in christianhelle/refitter#897
* Fix PR #​897 review feedback and add comprehensive bearer auth tests
by @​christianhelle in
christianhelle/refitter#936
* Fix numeric suffix added to interface method names in ByTag mode by
@​Copilot in christianhelle/refitter#914
* Improve OpenAPI parse + codegen throughput by removing avoidable
allocations and repeated regex work by @​Copilot in
christianhelle/refitter#937
* Move [JsonConverter] from enum properties to enum types by
@​christianhelle in christianhelle/refitter#938
* Fix broken CLI tool help text by @​christianhelle in
christianhelle/refitter#940
* Improve code coverage to >90% by @​christianhelle in
christianhelle/refitter#941
* Microsoft.OpenApi v3.4 by @​christianhelle in
christianhelle/refitter#945
* Add Unicode support for XML doc comment generation by @​christianhelle
in christianhelle/refitter#948
* Add PropertyNamingPolicy support for JSON property naming by
@​christianhelle in christianhelle/refitter#969
christianhelle/refitter#966
* Fix recursive schema stack overflows by @​christianhelle in
christianhelle/refitter#971
* Made Header Parameters for Security Schemes safe to use as C# variable
name by @​smoerijf in
christianhelle/refitter#977
* Enhance schema alias handling and property name generation by
@​christianhelle in christianhelle/refitter#996
* Verify alias handling and sanitize PascalCase properties by
@​christianhelle in christianhelle/refitter#997
* Harden .refitter settings deserialization and output path handling by
@​christianhelle in christianhelle/refitter#1000
* Special-case the default .refitter filename before deriving
OutputFilename by @​coderabbitai[bot] in
christianhelle/refitter#1002
* [v2.0 audit] Fix pre-release regressions from #​1057 by
@​christianhelle in christianhelle/refitter#1064
* Resolve high-severity audit findings from #​1057 by @​christianhelle
in christianhelle/refitter#1067
* [v2.0 audit] Close remaining verified #​1057 regressions by
@​christianhelle in christianhelle/refitter#1070
* Harden generation flows by @​christianhelle in
christianhelle/refitter#1071
* Breaking changes and Migration Guide for v2.0.0 by @​christianhelle in
christianhelle/refitter#1009
* Handle equivalent duplicate schemas in multi-spec merge by
@​christianhelle in christianhelle/refitter#1076
* Tighten warning handling across Refitter builds by @​christianhelle in
christianhelle/refitter#1079
* Fix default solution path and update .NET version in VS Code config by
@​christianhelle in christianhelle/refitter#1082
* Fix docker smoke tests by @​christianhelle in
christianhelle/refitter#1081
* Sanitize malformed schema type names without renaming clean schemas by
@​christianhelle in christianhelle/refitter#1085

 ... (truncated)

## 1.7.3

## What's Changed
* Add support for systems running only .NET 10.0 (without .NET 8.0 or
9.0) in Refitter.MSBuild by @​christianhelle in
christianhelle/refitter#882
* Update to return HttpResponseMessage for file downloads by @​frogcrush
in christianhelle/refitter#877

## New Contributors
* @​frogcrush made their first contribution in
christianhelle/refitter#877

**Full Changelog**:
christianhelle/refitter@1.7.2...1.7.3

## 1.7.2

**Implemented enhancements:**

- Improve Immutable Records ergonomics
[\#​844](christianhelle/refitter#844)
- Omit certain operation headers and include all others
[\#​840](christianhelle/refitter#840)
- Create .refitter settings file as part of output
[\#​859](christianhelle/refitter#859) by
@[christianhelle
- Fix integerType enum deserialization issue
[\#​855](christianhelle/refitter#855)
([christianhelle](https://github.com/christianhelle))
- support custom nswag template directory \#​844
[\#​854](christianhelle/refitter#854) by
@​kmc059000
- Fix missing method parameter XML code-documentation
[\#​850](christianhelle/refitter#850)
([christianhelle](https://github.com/christianhelle))

**Fixed bugs:**

- integerType parsing in settings file fails
[\#​851](christianhelle/refitter#851)
- CS1573 : Method parameter has no matching XML comment
[\#​846](christianhelle/refitter#846)

**Merged pull requests:**

- docs: add frogcrush as a contributor for code
[\#​878](christianhelle/refitter#878)
([allcontributors[bot]](https://github.com/apps/allcontributors))
- Migrate solution files from .sln to .slnx format
[\#​876](christianhelle/refitter#876)
([Copilot](https://github.com/apps/copilot-swe-agent))
- Fix issue with randomly failing tests to due parallel execution
[\#​872](christianhelle/refitter#872)
([christianhelle](https://github.com/christianhelle))
- chore\(deps\): update dependency tunit to 1.9.2
[\#​863](christianhelle/refitter#863)
([renovate[bot]](https://github.com/apps/renovate))
- chore\(deps\): update dependency tunit to 1.7.7
[\#​862](christianhelle/refitter#862)
([renovate[bot]](https://github.com/apps/renovate))
- Add unit tests for WriteRefitterSettingsFile functionality
[\#​860](christianhelle/refitter#860)
([Copilot](https://github.com/apps/copilot-swe-agent))
- chore\(deps\): update dependency ruby to v4
[\#​858](christianhelle/refitter#858)
([renovate[bot]](https://github.com/apps/renovate))
- chore\(deps\): update dependency tunit to 1.6.28
[\#​857](christianhelle/refitter#857)
([renovate[bot]](https://github.com/apps/renovate))
- docs: add 0x2badc0de as a contributor for bug
[\#​856](christianhelle/refitter#856)
([allcontributors[bot]](https://github.com/apps/allcontributors))
- chore\(deps\): update dependency swashbuckle.aspnetcore to 10.1.0
[\#​853](christianhelle/refitter#853)
([renovate[bot]](https://github.com/apps/renovate))
- chore\(deps\): update dependency tunit to 1.6.0
[\#​852](christianhelle/refitter#852)
([renovate[bot]](https://github.com/apps/renovate))
- docs: add lilinus as a contributor for code
[\#​849](christianhelle/refitter#849)
([allcontributors[bot]](https://github.com/apps/allcontributors))
- chore\(deps\): update dependency ruby to v3.4.8
[\#​845](christianhelle/refitter#845)
([renovate[bot]](https://github.com/apps/renovate))
- chore\(deps\): update dependency tunit to 1.5.70
[\#​837](christianhelle/refitter#837)
([renovate[bot]](https://github.com/apps/renovate))


**Full Changelog**:
christianhelle/refitter@1.7.1...1.7.2

Commits viewable in [compare
view](christianhelle/refitter@1.7.1...2.0.0).
</details>

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=refitter&package-manager=nuget&previous-version=1.7.1&new-version=2.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
vgmello pushed a commit to vgmello/momentum that referenced this pull request May 10, 2026
Updated [Refitter.MSBuild](https://github.com/christianhelle/refitter)
from 1.7.3 to 2.0.0.

<details>
<summary>Release notes</summary>

_Sourced from [Refitter.MSBuild's
releases](https://github.com/christianhelle/refitter/releases)._

## 2.0.0

## What's Changed

* Fix numeric format with pattern quirk - infer type from format for all
numeric types by @​Copilot in
christianhelle/refitter#869
* Read group documentation from document tags. by @​DJ4ddi in
christianhelle/refitter#887
* Fix null reference and XML escaping in XmlDocumentationGenerator by
@​Copilot in christianhelle/refitter#890
* Fix build workflow: add dotnet restore before dotnet msbuild in
Prepare step by @​Copilot in
christianhelle/refitter#892
christianhelle/refitter#895
* Fix MSBuild workflow by @​christianhelle in
christianhelle/refitter#898
* Add support for generating a single client from multiple OpenAPI
specifications by @​Copilot in
christianhelle/refitter#904
* Migrate from Microsoft.OpenApi.Readers 1.x to Microsoft.OpenApi 3.x by
@​vgmello in christianhelle/refitter#907
* Improve Smoke Tests execution time by @​christianhelle in
christianhelle/refitter#915
* Fix #​580: Nullable strings marked correctly by @​christianhelle in
christianhelle/refitter#921
* Fix #​672: MultipleInterfaces ByTag method naming scoped per-interface
by @​christianhelle in
christianhelle/refitter#922
* Fix #​635: Refactor source generator to use context.AddSource() by
@​christianhelle in christianhelle/refitter#923
* Add custom format mappings configuration by @​christianhelle in
christianhelle/refitter#927
* Fix multipart form-data parameter extraction by @​christianhelle in
christianhelle/refitter#928
christianhelle/refitter#911
christianhelle/refitter#902
* Fix smoke tests: --interface-only variant missing using directive for
contract types by @​Copilot in
christianhelle/refitter#933
* Fix SonarCloud Code Quality Issues by @​Copilot in
christianhelle/refitter#932
* Add debug logging for source generator when searching for .refitter
files by @​codymullins in
christianhelle/refitter#743
* Fix: Base type not generated for types using oneOf with discriminator
by @​Copilot in christianhelle/refitter#906
* Add option for Method Level Authorization header attribute by
@​Roflincopter in christianhelle/refitter#897
* Fix PR #​897 review feedback and add comprehensive bearer auth tests
by @​christianhelle in
christianhelle/refitter#936
* Fix numeric suffix added to interface method names in ByTag mode by
@​Copilot in christianhelle/refitter#914
* Improve OpenAPI parse + codegen throughput by removing avoidable
allocations and repeated regex work by @​Copilot in
christianhelle/refitter#937
* Move [JsonConverter] from enum properties to enum types by
@​christianhelle in christianhelle/refitter#938
* Fix broken CLI tool help text by @​christianhelle in
christianhelle/refitter#940
* Improve code coverage to >90% by @​christianhelle in
christianhelle/refitter#941
* Microsoft.OpenApi v3.4 by @​christianhelle in
christianhelle/refitter#945
* Add Unicode support for XML doc comment generation by @​christianhelle
in christianhelle/refitter#948
* Add PropertyNamingPolicy support for JSON property naming by
@​christianhelle in christianhelle/refitter#969
christianhelle/refitter#966
* Fix recursive schema stack overflows by @​christianhelle in
christianhelle/refitter#971
* Made Header Parameters for Security Schemes safe to use as C# variable
name by @​smoerijf in
christianhelle/refitter#977
* Enhance schema alias handling and property name generation by
@​christianhelle in christianhelle/refitter#996
* Verify alias handling and sanitize PascalCase properties by
@​christianhelle in christianhelle/refitter#997
* Harden .refitter settings deserialization and output path handling by
@​christianhelle in christianhelle/refitter#1000
* Special-case the default .refitter filename before deriving
OutputFilename by @​coderabbitai[bot] in
christianhelle/refitter#1002
* [v2.0 audit] Fix pre-release regressions from #​1057 by
@​christianhelle in christianhelle/refitter#1064
* Resolve high-severity audit findings from #​1057 by @​christianhelle
in christianhelle/refitter#1067
* [v2.0 audit] Close remaining verified #​1057 regressions by
@​christianhelle in christianhelle/refitter#1070
* Harden generation flows by @​christianhelle in
christianhelle/refitter#1071
* Breaking changes and Migration Guide for v2.0.0 by @​christianhelle in
christianhelle/refitter#1009
* Handle equivalent duplicate schemas in multi-spec merge by
@​christianhelle in christianhelle/refitter#1076
* Tighten warning handling across Refitter builds by @​christianhelle in
christianhelle/refitter#1079
* Fix default solution path and update .NET version in VS Code config by
@​christianhelle in christianhelle/refitter#1082
* Fix docker smoke tests by @​christianhelle in
christianhelle/refitter#1081
* Sanitize malformed schema type names without renaming clean schemas by
@​christianhelle in christianhelle/refitter#1085

 ... (truncated)

Commits viewable in [compare
view](christianhelle/refitter@1.7.3...2.0.0).
</details>

[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=Refitter.MSBuild&package-manager=nuget&previous-version=1.7.3&new-version=2.0.0)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore <dependency name> major version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's major version (unless you unignore this specific
dependency's major version or upgrade to it yourself)
- `@dependabot ignore <dependency name> minor version` will close this
group update PR and stop Dependabot creating any more for the specific
dependency's minor version (unless you unignore this specific
dependency's minor version or upgrade to it yourself)
- `@dependabot ignore <dependency name>` will close this group update PR
and stop Dependabot creating any more for the specific dependency
(unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore <dependency name>` will remove all of the ignore
conditions of the specified dependency
- `@dependabot unignore <dependency name> <ignore condition>` will
remove the ignore condition of the specified dependency and ignore
conditions


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature, bug fix, or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants