Can I disable the compilation step with daml start?

In my development workflow I have a makefile with the following target:

build:
  daml build
  daml codegen js -o daml.js .daml/dist/*.dar
  cd ui && yarn install --force --frozen-lockfile

I invoke this whenever my DAML model changed and I have to rerun the code generation. After that I always use daml start to start up the sandbox and JSON API. This does another compilation, which in my large project takes a bit. Is there a way to disable the compilation step in daml start or is there another easy way to reduce to a single compilation (other than separately starting sandbox and JSON API manually - I like the convenience of daml start)?

A related question: does it even make sense to compile as part of daml start? I guess it makes it easier for newcomers only having to execute a single command, but from the command name start itself I wouldn’t expect this to also compile my code.

1 Like

At the moment, you cannot disable it. We have plans to make compilation a noop if nothing changed which would address the perfomance aspect.

As for whether daml start should do compilation imho yes. I’ve seen too many issues caused by outdated DARs both in my own projects and for others. Having a single command that makes sure everything is up2date is very useful to avoid this.

2 Likes