Paket icon indicating copy to clipboard operation
Paket copied to clipboard

Running paket as a dotnet tool from dotnet 6.0.202 results in an error HRESULT: 0x80004005

Open 7sharp9 opened this issue 2 years ago • 7 comments

Description

running paket from dotnet 6 results in an error HRESULT: 0x80004005

Repro steps

Have paket as a local tool in a repo, then:

dotnet tool restore
dotnet paket restore

Expected behavior

paket runs ok

Actual behavior

paket crashes with the following:

➜ dotnet paket
Failed to initialize CoreCLR, HRESULT: 0x80004005
(base) myriad on 🌱 master [$!] .NET v6.0.202

Known workarounds

Apparently you can replace the dotnet CLI from dotnet6 with the one from dotnet5 see: https://github.com/dotnet/sdk/issues/24648

Other info

OS: macOS Monterey 12.3.1 sdk installed: dotnet 6.0.202 only

7sharp9 avatar Apr 29 '22 12:04 7sharp9

I have removed all versions of dotnet with the uninstall tool then solely installed dotnet 6.0.202

7sharp9 avatar Apr 29 '22 12:04 7sharp9

  "tools": {
    "paket": {
      "version": "7.1.5",
      "commands": [
        "paket"
      ]
    },

7sharp9 avatar Apr 29 '22 13:04 7sharp9

Also tried on all versions of paket 6.x, all exhibit same error.

7sharp9 avatar Apr 29 '22 13:04 7sharp9

I fixed my problem with this by (re)installing dotnet 5 after installing 6.

jberzy avatar Apr 29 '22 16:04 jberzy

While the SDK/Runtime issue is being investigated, (putting my SDK hat on) I'd recommend that Paket update its TFM from netcoreapp2.1 to at least netcoreapp3.1. 2.1 runtimes aren't in support anymore, and 3.1 is in support until December of this year, so you're less likely to get a 'you're holding it wrong' answer from the team if you're targeting a supported runtime.

baronfel avatar Apr 29 '22 16:04 baronfel

I updated my runtimes to: framework: net60, netstandard21, netcoreapp31 but only for compatibility for those using myriad from those targets, nothing I need is tied to those.

7sharp9 avatar Apr 29 '22 16:04 7sharp9

@baronfel I have the myriad CLI set as: <TargetFrameworks>net6.0;netcoreapp3.1</TargetFrameworks> I guess the netcoreapp3.1 is only needed for older consumers of the CLI tool. I forget the details after a few months :-(

7sharp9 avatar Apr 29 '22 16:04 7sharp9