.NET SDK used when respecting global.json should respect rollForward option #34135
Replies: 2 comments 5 replies
-
|
Hi there, Get your discussion fixed faster by creating a minimal reproduction. This means a repository dedicated to reproducing this issue with the minimal dependencies and config possible. Before we start working on your issue we need to know exactly what's causing the current behavior. A minimal reproduction helps us with this. Discussions without reproductions are less likely to be converted to Issues. Please follow these steps:
If you need help with running renovate on your minimal reproduction repository, please refer to our Running Renovate guide. The Renovate team |
Beta Was this translation helpful? Give feedback.
-
|
Hi there, This Discussion has been flagged previously as needing a minimal reproduction, but one does not yet exist. This is a reminder that the reproduction is still needed in order to progress to next steps. If you have provided a minimal reproduction which satisfies our definitions above, but it went unnoticed, please reply to this message to help us find it. Thanks, the Renovate team |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
How are you running Renovate?
Self-hosted Renovate
If you're self-hosting Renovate, tell us which platform (GitHub, GitLab, etc) and which version of Renovate.
Bitbucket Server
Please tell us more about your question or problem
When using a global.json file in your repository, the SDK version used for running
dotnet restoreshould respect the rollForward flag if it is set, and if it is, the SDK version used for restoration should be the latest available, according to the base version and the rollForward option chosen. It is not currently doing so and just using the version directly: https://github.com/renovatebot/renovate/blob/main/lib/modules/manager/nuget/artifacts.ts#L64Example global.json
{ "sdk": "8.0.0", "rollForward": "latestMinor" }You would expect the SDK version chosen to be the latest (v8) SDK version, 8.0.405 (https://builds.dotnet.microsoft.com/dotnet/Sdk/8.0.405/dotnet-sdk-8.0.405-linux-x64.tar.gz)
However instead we get 8.0.0. Sadly for us, no artefact exists with this version (https://builds.dotnet.microsoft.com/dotnet/Sdk/8.0.0/dotnet-sdk-8.0.0-linux-x64.tar.gz), so it cannot install the tool properly.
The impact of this is it breaks lock file restoration for these projects, causing build failures when comparing the project file version against the lock file version.
The current workaround for now is to upgrade the version in the global.json file to the latest acceptable version.
Logs (if relevant)
No response
Beta Was this translation helpful? Give feedback.
All reactions