fsprojects / fsprojects/Paket

Paket fails when adding <IncludeSymbols>true</IncludeSymbols> for SourceLink

Open
#3,521 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug needs triage
Dominant language
F#
Stars
2.1k
Forks
528
Avg merge
1d 12m
Merged PRs (30d)
54

Description

Description

Paket version 5.194.0

I'm trying to add SourceLink to a NuGet package. When I add the following line to my .fsproj:

<IncludeSymbols>true</IncludeSymbols>

makes Paket.Restore.targets fail on line 253:

Repro steps

Please provide the steps required to reproduce the problem

  1. Add this to the .fsproj file:
<IncludeSymbols>true</IncludeSymbols>
  1. Run dotnet pack

See https://github.com/atlemann/MyNuget for repro. Uses Fake and Paket as global tools.

Expected behavior

The pack command to succeed and a NuGet package and symbols package to be built.

Actual behavior

Paket errors with:

C:\Users\aru\Documents\src\MyNuget\.paket\Paket.Restore.targets(253,5): error : The filename, directory name, or volume label syntax is incorrect : 'C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release\MyFsNuget.1.2.3.nuspec;C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release' [C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\MyFsNuget.fsproj]
PackTask: C:\Users\aru\Documents\src\MyNuget\.paket\Paket.Restore.targets(253,5): error : The filename, directory name, or volume label syntax is incorrect : 'C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release\MyFsNuget.1.2.3.nuspec;C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release'

or

C:\Users\aru\Documents\src\MyNuget\.paket\Paket.Restore.targets(253,5): error : The path 'C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release\MyFsNuget.1.0.0.nuspec;C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release\MyFsNuget.1.0.0.symbols.nuspec;C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release\MyFsNuget.1.2.3.nuspec;C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\obj\Release' is too long, or a component of the specified path is too long. [C:\Users\aru\Documents\src\MyNuget\src\MyFsNuget\MyFsNuget.fsproj]
Known workarounds

None

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the repro repository and the .fsproj entry containing IncludeSymbols, then inspect .paket/Paket.Restore.targets around line 253 while running dotnet pack. Compare the generated paths in the reported error with the expected pack inputs. Done means dotnet pack succeeds and produces both the NuGet package and symbols package.

Written by the indexing model from the issue text.

Assessment

Tech stack
fsharp
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.