From 73a970dab98084c650113e49b0cf0cc644f38d32 Mon Sep 17 00:00:00 2001 From: Graeme Grant Date: Sun, 19 Apr 2026 22:12:19 +1000 Subject: [PATCH] fix: address Copilot PR #7 review feedback MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - release.yml: add concurrency group to prevent race conditions when multiple pushes to master happen close together; cancel-in-progress is false so a running release is never aborted mid-way - release.yml: add explicit 'Fail if this version was already released' step after tag_check so a duplicate-version push to master fails loudly with ::error:: rather than silently succeeding with no publish - CollectionDefinitions.cs: fix XML doc cref targets — qualify DisableParallelization as Xunit.CollectionDefinitionAttribute.DisableParallelization and remove the space in ConcurrentDictionary{TKey,TValue} to avoid CS1574 warnings when doc generation is enabled --- .github/workflows/release.yml | 10 ++++++++++ .../CollectionDefinitions.cs | 4 ++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index c6acda8..f8c4a7c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -5,6 +5,10 @@ on: branches: - master +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: false + jobs: release: name: Build, Test & Publish to NuGet @@ -53,6 +57,12 @@ jobs: echo "exists=false" >> $GITHUB_OUTPUT fi + - name: Fail if this version was already released + if: steps.tag_check.outputs.exists == 'true' + run: | + echo "::error::Release tag ${{ steps.version.outputs.tag }} already exists. Bump the project version before pushing to master." + exit 1 + - name: Pack NuGet package if: steps.tag_check.outputs.exists == 'false' run: | diff --git a/tests/Blazing.Json.Queryable.Tests/CollectionDefinitions.cs b/tests/Blazing.Json.Queryable.Tests/CollectionDefinitions.cs index 8e75ac7..acb51d5 100644 --- a/tests/Blazing.Json.Queryable.Tests/CollectionDefinitions.cs +++ b/tests/Blazing.Json.Queryable.Tests/CollectionDefinitions.cs @@ -7,12 +7,12 @@ namespace Blazing.Json.Queryable.Tests; /// /// /// -/// is set to so that when any +/// is set to so that when any /// test in this collection executes, no other test collection runs concurrently. /// /// /// This is required because -/// uses a process-wide static +/// uses a process-wide static /// cache. Tests in this collection call ClearCache() and assert on CacheCount — /// assertions that are only valid when no other test is concurrently populating the cache. ///