AdaCore / RecordFlux

Formal specification and generation of verifiable binary parsers, message generators and protocol state machines
Apache License 2.0
104 stars 6 forks source link

Drop submodules #1188

Closed senier closed 1 year ago

senier commented 2 years ago

Right now we use submodules to tie together the main repository with the python-style and the specifications repositories. This setup makes it hard to maintain a mirror where the remotes are different while keeping builds reproducible.

Idea: Drop the submodules and replace them by a logic in the Makefile which checks out the desired revisions. Remotes could be selected by a variable. The Makefile could also be extended to check whether the desired version is currently checked out to avoid testing with an outdated version.

To make building released particularly easy, we could provide a symlink to a minimal default pyproject.toml which is contained in the main repository (and later overwritten by the Makefile). The specifications repository is only needed during development and can be left unpopulated for release builds.

treiher commented 2 years ago

I think we should consider merging the specifications into the main repository. This would remove the dependency cycle between the tests of the main repository and the specifications repository and thus would make it easier to change the language. Due to the dependency cycle, a syntax change requires three steps:

  1. Implement an intermediate solution in the parser and main repository that allows the old and the new syntax, so that the tests are kept compatible to the specifications repository.
  2. Adapt the specifications repository to the new syntax.
  3. Implement the final solution, which supports only the new syntax, in the parser and main repository and update the specifications submodule/revision.

If the specifications were part of the main repository, a syntax change could be realized in one step.