I want to use the precompiled dar of the contingent-claims (CC) library, downloaded from here: Releases · digital-asset/contingent-claims · GitHub
The CC library uses as dependency the daml-ctl
library, but I guess it’s already packaged in the CC dar. Is that right?
When I try to use a module from the daml-ctl
library, I get this message:
How can run :set package daml-ctl
?
This seems to be a GHCI command.
gyorgybalazsi:
:set package daml-ctl
Not entirely sure on this one, but saw another thread here where perhaps you can manually expose the dep you need.
You can also manually expose transitive deps by adding --package flags, e.g.,
build-options:
- --package=nameofdep-versionofdep
Thanks, tried and doesn’t seem to work. I think I’m doing something wrong.
Again: I only have the contingent-claims dar in my lib
folder (more precisely, this time, unlike in the original question, contingent-claims-test, which contains the modules of the original contingent-claims library and also examples).
With this in the daml.yaml
sdk-version: 2.1.0
name: sandbox
source: daml
init-script: Main:setup
version: 0.0.1
dependencies:
- daml-prim
- daml-stdlib
- daml-script
data-dependencies:
- ../lib/contingent-claims-test-2.0.0.dar
build-options:
- --package=daml-ctl-2.0.0
the daml build
succeeds, but I get the following error:
Maybe @cocreature can help, based on his answer in the thread Problem with transitive dependencies - #2 by akrmn
You need to restart the language server after changes to dependencies. Ctrl/Cmd-Shift-P → reload window is what I usually use for that.
2 Likes