Open tmcgilchrist opened 1 year ago
According to this StackOverflow answer, this could be a mismatch of ocaml compiler versions used in the voodoo-prep job and in the voodoo-do job.
This sounds like a thing ocaml-docs-ci must ensure: that the same ocaml compiler version is used for both steps? :thinking:
The problem is occurring while processing the package ocaml-src
, which contains a copy of the ocaml source tree. The problem is that there's a cmi
file embedded in the source tree in a test directory - and prep has plucked this out and handed it over to voodoo-do
for processing. I don't quite know why odoc is failing to read it, but whatever the reason there's nothing good going to come out of it. We've dealt with a similar issue in the past by blacklisting ocaml-secondary-compiler
(https://github.com/ocaml-doc/voodoo/blob/main/src/voodoo-prep/main.ml#L20) and we could do a similar thing here - there will never be any use in running odoc on the contents of the ocaml-src
!
This appears to have popped up again - now in the context of the Melange team wanting to know why their docs are not available. The issue occurs in this failure https://docs.ci.ocaml.org/job/2023-06-04/162831-voodoo-do-7aa510 and has a similar stack trace to what is posted above.
The package blacklisting is probably too blunt an instrument for this. We should either check the cmi is valid in voodoo or just catch the error returned from odoc and remove it from the list.
Indeed, let's check that the cmi is valid during voodoo-prep
, so that only valid cmi's (those matching the ocaml compiler version) are part of the output of voodoo-prep
Found when building vchan.6.0.0 Build logs at https://docs.ci.ocaml.org/job/2023-02-14/101944-voodoo-do-24e042