question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

`DotNetCoreCLIV2` should respect `rollForward` in `global.json`

See original GitHub issue

Required Information

Entering this information will route you directly to the right team and expedite traction.

Question, Bug, or Feature?
Type: Feature

Enter Task Name: DotNetCoreCLIV2

Environment

  • Server - Azure Pipelines or TFS on-premises?

Using Azure Pipelines but this isn’t environment specific

  • Agent - Hosted or Private:

Using self hosted agents but this isn’t environment specific

Issue Description

When using DotNetCoreCLIV2 and pulling the information from a global.json file, it’s not considering [rollForward[(https://docs.microsoft.com/en-us/dotnet/core/tools/global-json?tabs=netcore3x). Example, if specifying "version": "3.1.100" with "rollForward": "latestPatch", it should be able to install 3.1.106 (or whichever is the latest at that time)

It might be possible to do something similar using 3.1.x as a version number, but that doesn’t seem to be valid within global.json.

Task logs

Starting: UseDotNet
==============================================================================
Task         : Use .NET Core
Description  : Acquires a specific version of the .NET Core SDK from the internet or the local cache and adds it to the PATH. Use this task to change the version of .NET Core used in subsequent tasks. Additionally provides proxy support.
Version      : 2.171.0
Author       : Microsoft Corporation
Help         : https://aka.ms/AA4xgy0
==============================================================================
Found version 3.1.100 in channel 3.1 for user specified version spec: 3.1.100
Getting URL to download .NET Core sdk version: 3.1.100.
Detecting OS platform to find correct download package for the OS.
/home/vsts/work/_tasks/UseDotNet_b0ce7256-7898-45d3-9cb5-176b752bfea6/2.171.0/externals/get-os-distro.sh
Primary:linux-x64
Legacy:ubuntu.18.04-x64
Detected platform (Primary): linux-x64
Detected platform (Legacy): ubuntu.18.04-x64
Version 3.1.100 was not found in cache.
Downloading: https://download.visualstudio.microsoft.com/download/pr/d731f991-8e68-4c7c-8ea0-fad5605b077a/49497b5420eecbd905158d86d738af64/dotnet-sdk-3.1.100-linux-x64.tar.gz
Extracting downloaded package /home/vsts/work/_temp/4f922889-2d5d-47d8-9904-cfaaebd08953.
Extracting archive
/bin/tar xzC /home/vsts/work/_temp/c44417c1-deba-40ec-9856-2fa4c4a3c1f8 -f /home/vsts/work/_temp/4f922889-2d5d-47d8-9904-cfaaebd08953
Successfully installed .NET Core sdk version 3.1.100.
Creating global tool path and pre-pending to PATH.
Finishing: UseDotNet

logs_32.zip

Troubleshooting

Checkout how to troubleshoot failures and collect debug logs: https://docs.microsoft.com/en-us/vsts/build-release/actions/troubleshooting

Error logs

[Insert error from the logs here for a quick overview]

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Reactions:3
  • Comments:5 (1 by maintainers)

github_iconTop GitHub Comments

1reaction
bishal-pdMSFTcommented, Mar 2, 2021

We are not planning to make this enhancement. A workaround exists to use a well tested complete version in global.json.

0reactions
Herve-Mcommented, Nov 16, 2022

@bishal-pdMSFT Would it be possible to share how to A workaround exists to use a well tested complete version in global.json. ?

Read more comments on GitHub >

github_iconTop Results From Across the Web

Exploring the new rollForward and allowPrerelease settings in ...
In this post I explore the new rollForward and allowPrerelease settings added to the global.json file in .NET Core 3.0 and how they...
Read more >
DotNetCoreCLI@2 - .NET Core v2 task - Microsoft Learn
The restore command respects the feedRestore and vstsFeed arguments. Why should I check in a NuGet.config? Checking a NuGet.config into source ...
Read more >
rollForward (global.json / .NET Core) does not work - YouTrack
Changing the global.json to the correct version works, but it feels like Rider should respect the rollForward here and accept an up-level SDK...
Read more >
ray [Bug] Ray Client ray.tune.run fails on remote workers with ...
It seems remote_run calls run() underneath, so remote_run should indeed pass in the ... `DotNetCoreCLIV2` should respect `rollForward` in `global.json` ...
Read more >
Specifying .NET versions - Compositional IT
The global.json file is used to specify which . ... The rollForward property specifies which later SDK versions are also permissible, ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found