Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

roslyn-analyzers build failure #2911

Closed
tamlin-mike opened this issue Oct 7, 2019 · 5 comments
Closed

roslyn-analyzers build failure #2911

tamlin-mike opened this issue Oct 7, 2019 · 5 comments

Comments

@tamlin-mike
Copy link

tamlin-mike commented Oct 7, 2019

roslyn-analyzers git version: 707ae40
VS 16.3

Cloned into W:\Roslyn\roslyn-analyzers

In cmd.exe:
Restore.cmd - Works
Build.cmd - Fails.

Last non-red line of output is

Restore completed in 19,5 ms for W:\Roslyn\roslyn-analyzers\src\Text.Analyzers\UnitTests\Text.Analyzers.UnitTests.csproj.

After that many, many screenfuls of

%USERPROFILE%\.nuget\packages\microsoft.sourcelink.common\1.0.0-beta-63201-01\build\Microsoft.SourceLink.Common.targets(40,5): error : SourceRoot.SourceLinkUrl is empty: 'W:\Roslyn\roslyn-analyzers\' [W:\Roslyn\roslyn-analyzers\src\TestReferenceAssembly\TestReferenceAssembly.csproj]
%USERPROFILE%\.nuget\packages\microsoft.sourcelink.common\1.0.0-beta-63201-01\build\Microsoft.SourceLink.Common.targets(40,5): error : SourceRoot.SourceLinkUrl is empty: 'W:\Roslyn\roslyn-analyzers\' [W:\Roslyn\roslyn-analyzers\src\Microsoft.CodeAnalysis.Analyzers\Core\Microsoft.CodeAnalysis.Analyzers.csproj]
%USERPROFILE%\.nuget\packages\microsoft.sourcelink.common\1.0.0-beta-63201-01\build\Microsoft.SourceLink.Common.targets(40,5): error : SourceRoot.SourceLinkUrl is empty: 'W:\Roslyn\roslyn-analyzers\' [W:\Roslyn\roslyn-analyzers\src\Text.Analyzers\Core\Text.Analyzers.csproj]
%USERPROFILE%\.nuget\packages\microsoft.sourcelink.common\1.0.0-beta-63201-01\build\Microsoft.SourceLink.Common.targets(40,5): error : SourceRoot.SourceLinkUrl is empty: 'W:\Roslyn\roslyn-analyzers\' [W:\Roslyn\roslyn-analyzers\src\Roslyn.Diagnostics.Analyzers\Core\Roslyn.Diagnostics.Analyzers.csproj]
... [much, much error-text removed as redundant]

(%USERPROFILE% is not literal, the actual string displayed is what this env var expands to)

Ideas?

EDIT/addition:
In case it could provid a clue; trying to build roslyn (not -analyzers), I get many similar messages, but not as errors but as warnings. They follow the same style but sees to refer to a different version of sourcelink (one could question the wisdom of depending on beta-versions of moving targets for production libraries, but that's a different can of worms):

%USERPROFILE%\.nuget\packages\microsoft.sourcelink.common\1.0.0-beta2-19367-01\build\Microsoft.SourceLink.Common.targets(50,5): warning : Source control information is not available - the generated source link is emp
ty. [W:\Roslyn\roslyn\src\ExpressionEvaluator\Core\Test\FunctionResolver\Microsoft.CodeAnalysis.FunctionResolver.UnitTests.csproj]
@333fred
Copy link
Member

333fred commented Oct 7, 2019

This is generally a sign of missing git remote information in your clone. What does a git remote -v output?

@tamlin-mike
Copy link
Author

I have a two-staged working repo. A bare clone from github, then a working clone from the bare. Anyway, since it seems I was barking up the wrong tree trying to build this repo, I'm closing the issue. Sorry for the noise.

@tamlin-mike
Copy link
Author

Reopening after additional information from tmat.

The problem is indeed that sourcelink does not (yet, tmat is working on it) handle local-only git upstream repo of the kind I used.

However, the issue remains that this is a build error in roslyn-analyzers, while roslyn handles it, more properly I believe, as a warning.

@tamlin-mike tamlin-mike reopened this Oct 7, 2019
@mavasani
Copy link
Contributor

mavasani commented May 5, 2020

@tamlin-mike Is this still value issue? Can it be closed?

@tamlin-mike
Copy link
Author

@mavasani While I haven't tested since, the following suggests it was fixed just the day after my last comment:

dotnet/sourcelink#438

Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants