Cannot pack netcore project
See original GitHub issueDescription
As per the title 😃
Repro steps
git clone https://github.com/fable-compiler/Fable
cd Fable
git checkout 19ff181
cd src/dotnet/Fable.Compiler
dotnet restore
dotnet pack
Expected behavior
A .nupkg is created
Actual behavior
The command fails with the following error:
~/d/F/s/d/Fable.Compiler ❯❯❯ dotnet pack
Microsoft (R) Build Engine version 15.1.1012.6693
Copyright (C) Microsoft Corporation. All rights reserved.
Fable.Core -> /Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Core/bin/Debug/netstandard1.6/Fable.Co
re.dll
Fable.Compiler -> /Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/bin/Debug/netstandard1.6/
Fable.Compiler.dll
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: The "PackTask" taskfailed unexpectedly. [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: System.IO.DirectoryNotFoundException: Could not find a part of the path '/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/obj/Fable.Compiler.1.1.10.nuspec;/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/obj'. [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at Interop.ThrowExceptionForIoErrno(ErrorInfo errorInfo, String path, Boolean isDirectory, Func`2 errorRewriter) [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at Interop.CheckIo(Int64 result, String path, Boolean isDirectory, Func`2 errorRewriter) [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at System.IO.UnixFileSystem.SetCurrentDirectory(String fullPath) [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at System.IO.Directory.SetCurrentDirectory(String path) [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at NuGet.Commands.PackCommandRunner.SetupCurrentDirectory(PackArgs packArgs) [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at NuGet.Build.Tasks.Pack.PackTaskLogic.GetPackArgs(IPackTaskRequest`1 request) [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at NuGet.Build.Tasks.Pack.PackTask.Execute() [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute() [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
/Users/alfonsogarciacaronunez/dev/Fable/.paket/Paket.Restore.targets(89,5): error MSB4018: at Microsoft.Build.BackEnd.TaskBuilder.<ExecuteInstantiatedTask>d__25.MoveNext() [/Users/alfonsogarciacaronunez/dev/Fable/src/dotnet/Fable.Compiler/Fable.Compiler.fsproj]
Known workarounds
Haven’t found any yet 😦
Paket 5.6.9 dotnet SDK 1.0.4 macOS 10.12.5
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:8 (4 by maintainers)
Top Results From Across the Web
dotnet pack creates package that is not compatible with . ...
I am creating a NuGet package which contains a .Net Standard DLL and a config file. This project is supposed to support both...
Read more >dotnet pack command - .NET CLI
The dotnet pack command builds the project and creates NuGet packages. The result of this command is a NuGet package (that is, a...
Read more >dotnet pack does not produce package on net core 2.0.0 ...
Steps to reproduce Install net core 2.0.0 sdk Create a basic Web project with net461 target framework and referencing AspNetCore 2.0.0 ...
Read more >NETSDK1079: The Microsoft.AspNetCore.All package is ...
You retarget an ASP.NET Core project from .NET Core 2.2 or earlier to .NET Core 3.0 or later. The project uses the Microsoft.AspNetCore.All ......
Read more >Build failing - Currently, 'dotnet pack' command does not ...
NET Core projects we recently enabled. Quick workaround for now is to disable/comment platform: Any CPU in your appveyor.yml . Meanwhile we are ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Closing, origin issue was fixed
Some options:
NuGetToolVersion
4.0.0
4.3.0
BundledNETStandardTargetFrameworkVersion
2.0
afaik is better check
NuGetToolVersion
, i dont think will change with a minor update of sdk 1.0that’s done just checking the props, like
dotnet build -v diag > log.txt
(ormsbuild /t:Build /v:diag > log.txt
) if can be useful laterfor set it, usual
Condition
on prop