fsprojects / IfSharp

F# for Jupyter Notebooks
Other
442 stars 71 forks source link

Using Angara.Charting fails on missing files #220

Closed cgravill closed 5 years ago

cgravill commented 5 years ago

Description

Using Angara.Charting fails on missing files e.g. https://cdn.rawgit.com/predictionmachines/Angara/0.3.4/dist/Angara.Html.css

Repro steps

#load "Angara.Charting.Paket.fsx"
#load "Angara.Charting.fsx"
let x = [| for i in 0..99 -> float(i) / 10.0 |]
let y = x |> Array.map (fun x -> sin x)
let z = x |> Array.map (fun x -> cos x)

[ Angara.Charting.Plot.line(x, y); Angara.Charting.Plot.markers(x, z) ] |> Angara.Charting.Chart.ofList

various errors on console and breaks codemirror

cgravill commented 5 years ago

@dgrechka have the files been moved? The closest I can see is https://github.com/predictionmachines/Angara/

dgrechka commented 5 years ago

Hi @cgravill , I believe this is because cdn.rawgit has reached its end of life.

Perhaps, we should switch to https://www.jsdelivr.com/rawgit

Adding @sergey-b-berezin, @msdmkats, @dvoits, @msdvoits to be aware of the issue.

cgravill commented 5 years ago

Ah interesting thanks @dgrechka yes switching sounds like a great idea!

I made an interesting discovery: https://cdn.rawgit.com/predictionmachines/Angara/0.3.3/dist/Angara.Html.css correctly resolves. Did 0.3.4 get moved?

dgrechka commented 5 years ago

@cgravill , we've pushed the corresponding release tag to the github (it was missing). Thus everything should work now with v0.3.4. At least until October 2019 while rawgit.com still works

cgravill commented 5 years ago

Great, yes that's working for me now. Thanks for quickly addressing it.

I'll be able to add support in the experimental .NET Core version too now.

Is the dependency on rawgit.com a general issue for Angara or specific to the integration in IF#? The only place I can see rawgit.com in this repository used explicitly in Angara.Charting.Dynamic.fsx which we're not using here. I'll fix that one, but otherwise are the changes needed inside Angara?

cgravill commented 5 years ago

I'll assume you folks have it handled in Angara specifically.

I've moved the rawgit calls over to jsdelivr within IF#.