Now It Compiles! Certified Automatic Repair of Uncompilable Protocols
Luís Cruz-Filipe, Fabrizio Montesi
[2023].
In proceedings of ITP 2023, pp. 11:1-11:19.
Choreographic programming is a paradigm where developers write the global specification (called choreography) of a communicating system, and then a correct-by-construction distributed implementation is compiled automatically. Unfortunately, it is possible to write choreographies that cannot be compiled, because of issues related to an agreement property known as knowledge of choice. This forces programmers to reason manually about implementation details that may be orthogonal to the protocol that they are writing.
Amendment is an automatic procedure for repairing uncompilable choreographies. We present a formalisation of amendment from the literature, built upon an existing formalisation of choreographic programming. However, in the process of formalising the expected properties of this procedure, we discovered a subtle counterexample that invalidates the original published and peer-reviewed pen-and-paper theory. We discuss how using a theorem prover led us to both finding the issue, and stating and proving a correct formulation of the properties of amendment.
@inproceedings{DBLP:conf/itp/Cruz-FilipeM23, author = {Lu{\'{\i}}s Cruz{-}Filipe and Fabrizio Montesi}, editor = {Adam Naumowicz and Ren{\'{e}} Thiemann}, title = {Now It Compiles! Certified Automatic Repair of Uncompilable Protocols}, booktitle = {14th International Conference on Interactive Theorem Proving, {ITP} 2023, July 31 to August 4, 2023, Bia{\l}ystok, Poland}, series = {LIPIcs}, volume = {268}, pages = {11:1--11:19}, publisher = {Schloss Dagstuhl - Leibniz-Zentrum f{\"{u}}r Informatik}, year = {2023}, url = {https://doi.org/10.4230/LIPIcs.ITP.2023.11}, doi = {10.4230/LIPICS.ITP.2023.11}, timestamp = {Wed, 21 Aug 2024 22:46:00 +0200}, biburl = {https://dblp.org/rec/conf/itp/Cruz-FilipeM23.bib}, bibsource = {dblp computer science bibliography, https://dblp.org} }
A PDF is available (possibly a preprint):