purescript / registry-dev

Development work related to the PureScript Registry
https://github.com/purescript/registry
97 stars 80 forks source link

Add caching to compile-versions #640

Closed thomashoneyman closed 1 year ago

thomashoneyman commented 1 year ago

The compile-versions script has no caching right now, which means every run will try solving and compilation anew for, in the worst case, every compiler * every package version, or hundreds of thousands of compiler / package / version combinations.

This PR adds caching to compile-versions based on the package, version, and compiler version, so we don't recompile already-visited package versions. In the future we could take this back out by using the metadata files themselves as the "cache", but until we add compiler versions to the metadata files this is the only way we have to save run results.

thomashoneyman commented 1 year ago

@f-f I requested your review because Colin is on PTO until next week.