Copilot commented on code in PR #110:
URL: https://github.com/apache/activemq-nms-amqp/pull/110#discussion_r3292374003
##########
Directory.Build.props:
##########
@@ -1,6 +1,6 @@
<Project>
<PropertyGroup>
<LangVersion>12</LangVersion>
- <TargetFramework>net8.0</TargetFramework>
+ <TargetFrameworks>net8.0;net10.0</TargetFrameworks>
Review Comment:
`Directory.Build.props` now sets `TargetFrameworks` unconditionally.
Projects that explicitly set `TargetFramework` (e.g.,
`src/NMS.AMQP/Apache-NMS-AMQP.csproj` targets `netstandard2.0`) will end up
with *both* `TargetFramework` and `TargetFrameworks` defined, which can break
SDK evaluation and/or unintentionally change that project’s target frameworks.
Consider guarding this with a condition so `TargetFrameworks` is only set when
neither `TargetFramework` nor `TargetFrameworks` is already defined (or
explicitly clearing `TargetFrameworks` in the netstandard project).
##########
.github/workflows/build.yml:
##########
@@ -19,15 +26,15 @@ jobs:
- name: Run ActiveMQ Artemis
run: docker compose up -V -d
working-directory: ./test
- - name: Setup .NET 8
+ - name: Setup .NET ${{ matrix.dotnet-version }}
uses: actions/setup-dotnet@v4
with:
- dotnet-version: '8.0.x'
+ dotnet-version: ${{ matrix.dotnet-version }}
- name: Restore dependencies
run: dotnet restore apache-nms-amqp.sln
Review Comment:
With `TargetFrameworks` including `net10.0`, the `dotnet-version: '8.0.x'`
job will run `dotnet restore apache-nms-amqp.sln` using the .NET 8 SDK, which
generally cannot restore/build projects targeting a newer TFM (it will fail
once it encounters `net10.0`). To keep the matrix, the restore/build/test steps
need to avoid evaluating `net10.0` in the .NET 8 job (or alternatively, drop
the .NET 8 SDK leg and run both TFMs under a single SDK that supports them).
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information, visit: https://activemq.apache.org/contact