fsprojects / fsharp-language-server

Other
219 stars 37 forks source link

Unable to build fsharp-language-server #22

Closed Disco-Dave closed 5 years ago

Disco-Dave commented 5 years ago

Operating system

Versions

I get the following errors after running npm install && dotnet build -c Release

Copyright (C) Microsoft Corporation. All rights reserved.

  Restore completed in 505.72 ms for /home/disco/Documents/code/fsharp-language-server/src/LSP/LSP.fsproj.
  Restore completed in 1.39 sec for /home/disco/Documents/code/fsharp-language-server/tests/LSP.Tests/LSP.Tests.fsproj.
  Restore completed in 1.42 sec for /home/disco/Documents/code/fsharp-language-server/tests/ProjectCracker.Tests/ProjectCracker.Tests.fsproj.
  Restore completed in 1.42 sec for /home/disco/Documents/code/fsharp-language-server/src/FSharpLanguageServer/FSharpLanguageServer.fsproj.
  Restore completed in 1.39 sec for /home/disco/Documents/code/fsharp-language-server/tests/FSharpLanguageServer.Tests/FSharpLanguageServer.Tests.fsproj.
  Restore completed in 1.33 sec for /home/disco/Documents/code/fsharp-language-server/src/ProjectCracker/ProjectCracker.fsproj.
  Restore completed in 1.43 sec for /home/disco/Documents/code/fsharp-language-server/tests/ProjectInfo/ProjectInfo.csproj.
error FS3031 : The type provider '/home/disco/.nuget/packages/fsharp.data/3.0.0-beta3/lib/netstandard2.0/FSharp.Data.dll' reported an error : Assembly attribute 'TypeProviderAssemblyAttribute' refers to a designer assembly 'FSharp.Data.DesignTime' which cannot be loaded or doesn't exist. Could not load file or assembly 'FSharp.Core, Version=4.4.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. The system cannot find the file specified. [/home/disco/Documents/code/fsharp-language-server/src/LSP/LSP.fsproj]
FSC : warning FS3005: Referenced assembly '/home/disco/.nuget/packages/fsharp.data/3.0.0-beta3/lib/netstandard2.0/FSharp.Data.dll' has assembly level attribute 'Microsoft.FSharp.Core.CompilerServices.TypeProviderAssemblyAttribute' but no public type provider classes were found [/home/disco/Documents/code/fsharp-language-server/src/LSP/LSP.fsproj]
  ProjectInfo -> /home/disco/Documents/code/fsharp-language-server/tests/ProjectInfo/bin/Release/netcoreapp2.1/ProjectInfo.dll

Build FAILED.

FSC : warning FS3005: Referenced assembly '/home/disco/.nuget/packages/fsharp.data/3.0.0-beta3/lib/netstandard2.0/FSharp.Data.dll' has assembly level attribute 'Microsoft.FSharp.Core.CompilerServices.TypeProviderAssemblyAttribute' but no public type provider classes were found [/home/disco/Documents/code/fsharp-language-server/src/LSP/LSP.fsproj]
error FS3031 : The type provider '/home/disco/.nuget/packages/fsharp.data/3.0.0-beta3/lib/netstandard2.0/FSharp.Data.dll' reported an error : Assembly attribute 'TypeProviderAssemblyAttribute' refers to a designer assembly 'FSharp.Data.DesignTime' which cannot be loaded or doesn't exist. Could not load file or assembly 'FSharp.Core, Version=4.4.1.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. The system cannot find the file specified. [/home/disco/Documents/code/fsharp-language-server/src/LSP/LSP.fsproj]
    1 Warning(s)
    1 Error(s)

Time Elapsed 00:00:05.89

Any suggestions?

NatElkins commented 5 years ago

What directory are you doing it in?

You could try following the exact steps from the CI: https://github.com/georgewfraser/fsharp-language-server/blob/master/.circleci/config.yml

Disco-Dave commented 5 years ago

I'm running these in the root fsharp-language-server directory. Following the exact steps, failed as well with the same errors after running the dotnet build step.

georgewfraser commented 5 years ago

This is surprising because the CircleCI build is on linux. Could be a dotnet version problem.

trbjo commented 5 years ago

I had the same problem. Instead of the community version, try installing the dotnet-sdk-preview from the AUR.

georgewfraser commented 5 years ago

I've built in on multiple linux distros and dotnet versions and never been able to reproduce this. Could you try building with latest dotnet? That should work.

Disco-Dave commented 5 years ago

Unfortunately it still does not work. However I don't think it's for any reason within anyone's control here.

It's a bug related to Arch Linux only. https://bugs.archlinux.org/task/60718

Sorry for the confusion, and thanks for all the help.