fslaborg / zzarchive-FsLab

A collection of packages for data science with F#
http://fslab.org
Other
159 stars 42 forks source link

FsJournal does not use the newtonsoft.json.dll that I reference in my script #120

Closed kflu closed 3 years ago

kflu commented 7 years ago

Fake is used by fslab journal's build command. I have a journal that uses newtonsoft.json for deserialization. However no matter what I do to reference a desired version of the DLL, the fsjournal's build run command always insists to use the one that's in FAKE/tools/newtonsoft.json.dll, which targets .NET v40. This is the actual deserialization problem I run into. And can only be solved by having the newtonsoft.json.dll that targets .NET 4.5.

Here's my script that shows my reference to the DLL on the very first line.

// even if I specifically ask to load my desired DLL, the actually loaded one in FSLab journal uses the one
// in Fake/tools/newtonsoft.json.dll, which is older and buggy.
#r @"newtonsoft.json.9.0.1\net45\Newtonsoft.Json.dll" 
#load "packages/FsLab/FsLab.fsx"

open Newtonsoft.Json
open Deedle
open System.Collections.Generic

(**
This will fail deserialization due to undesired Newtonsoft.Json.dll loaded
*)
let x = JsonConvert.DeserializeObject<IReadOnlyDictionary<string,string>>("""
{
      "Something": "1.8",
      "Something2": "0.10000000000000001",
      "Something3": "answer3",
}""")
dsyme commented 3 years ago

FsLab is now changing to be an incubation space for F# data science projects, per discussion in https://github.com/fslaborg/zzarchive-FsLab/issues/137#issuecomment-741093688

Closing this out as it relates to the old FsLab package collection.