Closed lambdakris closed 5 years ago
Thanks for the report.
I think this is the new spans support, can you add output from dotnet --info
please?
Can you give 3.0.1 a spin?
On Sun, May 12, 2019 at 9:50 AM Yevgeniy Tolmachev eugene@tolmachev.ca wrote:
Thanks for the report. I think this is the new spans support, can you add output from
dotnet --info
please?
I am unable to get the build working so I can't verify if the changes introduced in 3.0.1 fixed it. Just in case, below is the dotnet --info in case you still need it...
.NET Core SDK (reflecting any global.json):
Version: 3.0.100-preview5-011568
Commit: b487ff10aa
Runtime Environment:
OS Name: Windows
OS Version: 10.0.17763
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\3.0.100-preview5-011568\
Host (useful for support):
Version: 3.0.0-preview5-27626-15
Commit: 61f30f5a23
.NET Core SDKs installed:
2.1.600 [C:\Program Files\dotnet\sdk]
2.1.602 [C:\Program Files\dotnet\sdk]
2.2.105 [C:\Program Files\dotnet\sdk]
2.2.200 [C:\Program Files\dotnet\sdk]
2.2.202 [C:\Program Files\dotnet\sdk]
3.0.100-preview5-011568 [C:\Program Files\dotnet\sdk]
.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.1.8 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.1.9 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.2.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.2.3 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.1.8 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.1.9 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.2.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.2.3 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 3.0.0-preview5-19227-01 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.1.8 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.1.9 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.2.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.2.3 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.0.0-preview5-27626-15 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.0.0-preview5-27626-15 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
To install additional .NET Core runtimes or SDKs:
https://aka.ms/dotnet-download
I finally got the change to get the elmish/browser build working, but when I tried referencing the Fable.Elmish.Browser.dll directly from the example to test the change, I got additional errors about missing references. I guess I should wait until you have time to update the nuget package.
Are you saying package 3.0.1 doesn't fix it for you? In any case you can switch your build to use sdk version to 2.2.x and it should work for now.
Ahh, thing is, I don't see the 3.0.1 package on NuGet.org. That's what threw me off initially, and why I was trying to build Fable.Elmish.Browser myself and reference directly...
Oh, just to clarify, the error is there when targeting netcoreapp2.2 and netcoreapp2.1 as well. Only netcoreapp2.0 and lower compiles without error. I think this is still consistent with your diagnosis that it is due to the introduction of Span.
It's not really what you target, it's the complier you use, you have beta of v3 as the default. Create this file in the root of your solution to use v2.2 sdk: https://docs.microsoft.com/en-us/dotnet/core/tools/global-json
Well, I tried pinning the SDK to 2.2 and 2.1 in the global.json file as well, but it doesn't get rid of the error (I can confirm that it picks up the pinned SDK with dotnet --version
). However, if the issue is like you say due to Span, then that is still what one would expect to see since I believe Span was introduced with .NET Core 2.1, is that about right?
I also tried to pin the SDK, it didn't work.
What solved the problem was specifying that value is a string, not a span. https://github.com/elmish/browser/blob/cc55f78bffbc3fb4aeed7cac3259cf49a089cb81/src/parser.fs#L269
edit: I've noticed it was fixed in the 3.0.1 version, but I was pulling 3.0.0 from nuget.
Sorry for the inconvenience.
Config:
.NET Core SDK (reflecting any global.json):
Version: 2.2.200
Commit: 27f814f6ba
Runtime Environment:
OS Name: Windows
OS Version: 6.1.7601
OS Platform: Windows
RID: win7-x64
Base Path: C:\Program Files\dotnet\sdk\2.2.200\
Host (useful for support):
Version: 2.2.5
Commit: 0a3c9209c0
.NET Core SDKs installed:
2.0.0 [C:\Program Files\dotnet\sdk]
2.2.101 [C:\Program Files\dotnet\sdk]
2.2.107 [C:\Program Files\dotnet\sdk]
2.2.200 [C:\Program Files\dotnet\sdk]
.NET Core runtimes installed:
Microsoft.AspNetCore.All 2.2.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.2.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.All 2.2.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.All]
Microsoft.AspNetCore.App 2.2.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.2.2 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 2.2.5 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 2.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.2.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.2.2 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 2.2.5 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Sounds like 3.0.1 solves the problem, released the package.
Description
Hello, I am getting some sort of Fable error during the compilation phase but it does not seem to actually prevent the build from completing and the program from running correctly. The error is the following:
Repro code
Here is a minimal example.
example.zip
Expected and actual results
The expected result would be for there to be no Fable compilation error. The actual result is the error specified above during the Fable compilation process.
Related information
Sneaky question while I'm at it...
How would one do nested routing? I can't envision how that would work with the whole composed MVU architecture thing. Do you know of any examples in the wild that I might check out?