Open carlpulley-da opened 8 months ago
To simplify dependency package management in multi-package projects, it would be very useful if the daml.yaml
files supported environment variables.
That way build systems (e.g. Gradle, sbt, etc) could pass in environment variables defining module/project paths. This would then allow easier looking paths rather than the noisier looking ../
prefixes.
In addition, having environment variables set by the location of a parent multi-package.yaml
file might also help eliminate some of the path noise when defining package path dependencies.
Wider use of environment variables could allow some DRYing up of SDK package versions.
Ref slack conversation:
Improve documentation around using DAML_SDK_VERSION
for CI environments where a bootstrapping daml SDK is initially required. Documentation should prefer this approach over the use of a daml.yaml
against the multi-package.yaml
file.
Ref slack conversation:
Multi-package support for daml test
is currently missing.
Work arounds are either:
find . -name "*-tests-[0-9\.]*\.dar" -exec daml script --dar {} --all --ide-ledger --static-time \;
- assumes that tests are packaged into their own dar filesfor pkg in $(yq e '.packages[]' ./multi-package.yaml); do
pushd ${pkg}
daml test
popd
done
Multi-package testing (when supported) could do with improved dar file test integration. At the moment, one has to know to use daml script
(with the right magic CLI options) in order to run a test dar file.
Doing this would encourage end users to separate script code out of their main dars and into test dars.
Ref slack conversation:
Tracking ticket on potential issues and Slack discussion regarding issues encountered with integrating multi-package functionality into Gradle