nfdi4plants / ARCtrl

Library for management of Annotated Research Contexts (ARCs) using an in-memory representation and runtime-agnostic contract systems.
MIT License
11 stars 8 forks source link

[BUG] Unable to use ARCtrl.Json in fable JavaScript environment #373

Open Freymaurer opened 3 months ago

Freymaurer commented 3 months ago

We use conditional references for environment targetet json libs:

image

This works for native transpilation and testing, but not when referenced in another fable environment.

Freymaurer commented 3 months ago

More: image

Freymaurer commented 3 months ago

we hotfixed this with ARCtrl.alpha.6.swate hotfix. This version does not include conditional python/javascript json dependency, instead it always depens on thoth.json.javascript

Freymaurer commented 2 months ago

To publish swate prerelease, you can use:

  1. change ARCtrl.Json.fsproj dependencies to
    <ItemGroup>
    <PackageReference Include="NJsonSchema" Version="10.8.0" />
    <PackageReference Include="Thoth.Json.Core" Version="0.2.1" />
    <PackageReference Include="Thoth.Json.Newtonsoft" Version="0.1.0" />
    <PackageReference Include="Thoth.Json.JavaScript" Version="0.1.0" />
    </ItemGroup>
  2. Comment out all runtests references
  3. build.cmd publishNugetPrerelease
  4. on request type swate.b
  5. on request give prerelease version
HLWeil commented 1 month ago

I'm currently investigating why it doesn't work in Fable. '

The problem lies already with the dependency resolver they use, https://github.com/phmonte/Buildalyzer.