What parts of the .daml directory are cached and influence a build?
For example, in a Daml project that has other dependencies.
triggers git:(develop) ✗ daml build
2022-09-02 00:34:29.78 [INFO] [build]
Compiling top-secret-triggers to a DAR.
2022-09-02 00:34:31.64 [INFO] [build]
Created .daml/dist/top-secret-triggers-0.0.2.dar
➜ triggers git:(develop) ✗ daml damlc inspect-dar --json .daml/dist/top-secret-triggers-0.0.2.dar | jq -r .main_package_id
fa33e26ff5a74d0d2735699723aaa7403e0a3aacf7c48725d0534ea5a7ae5376
➜ triggers git:(develop) ✗ rm -rf .daml
➜ triggers git:(develop) ✗ daml build
2022-09-02 00:34:59.53 [INFO] [build]
Compiling top-secret-triggers to a DAR.
2022-09-02 00:35:01.30 [INFO] [build]
Created .daml/dist/top-secret-triggers-0.0.2.dar
➜ triggers git:(develop) ✗ daml damlc inspect-dar --json .daml/dist/top-secret-triggers-0.0.2.dar | jq -r .main_package_id
54f9d30d5547382281eed2125a299352fb4259d0c56f651804b65b9840075a09
That sounds like a bug to me. damlc checks if it needs to clear part of .daml usually so this should never have an effect. The one other reason I can imagine is if you enabled custom build options in particular anything related to incremental & paralllel builds. In that case, the build is just non-deterministic. Those should only be used for development.
I don’t think that I enabled those build options as I don’t know about them,
. I did have a top-secret-triggers-0.0.1.dar left over inside of .daml which was what I first thought was causing the error. But then I got rid of it and was able to replicate this odd behavior.
Can you still replicate the behaviour? Do you have instructions I could try to reproduce?
Provided off-discuss ![]()