Hi everyone,

I have collected a list of 50 or so packages on opam-repository whose

build is currently broken on 4.07.1. I would like to crowd-source

fixes for these packages, so that either their build is fixed or they

are marked as unbuildable. I’m posting the list in a second post

below. Please consider contributing by taking one of the packages in

the list with a TODO marker and trying to fix the issue.

Workflow

The post below is a wiki. You can edit it to mark that you are working

on one of the issues.

TODO => WIP(@user) => DONE(@user, link to change/report)

Some issues don’t have a TODO marker, because it’s unclear what to

do. Feel free to add one if you have a suggestion for what to do.

How?

I have marked some hypotheses of mine on what the issue probably is,

and how it could be fixed. Some common issues:

The package is missing an upper bound on one of its dependencies;

this shows up as build failures asking for library functions that

don’t exist anymore. You have to inspect the dependencies of older

and newer versions of the package, possibly the changelog of the

dependency, to guess what the upper bound should be; then test it.

The package is broken due to an incompatibility between ‘bytes’ and

‘string’, often in an _oasis file; you can just add a dependency on

the virtual package ‘base-unsafe-string’, which will mark it

uninstallable on safe-string versions of OCaml.

The archive where the package can be found has changed; opam files

for newer versions will lead you to the new URLs – if the new place

doesn’t have archives for older versions, you could ask the

maintainer and/or remove the package.

The checksum for an archive has changed. Inspecting the new archive

to ensure that it is correct helps.

Why?

The failing packages are often older versions of existing, non-failing

packages. While many of us may not care about the buildability of

older versions, it does matter for the good health of the repository:

Some users have pinned older versions for stability reasons. If they

want to, for example, upgrade the OCaml version but preserve the

version of their dependencies, this should still work – or be

clearly marked as uninstallable, not a confusing error in the middle

of the build.

Old packages show up in the “revdeps” of new opam-repository

submissions – when we upload a new version of a package, its

dependencies are automatically tested. Each build failure in the

revdeps requires human investigation, to understand if the issue is

due to the new package or is irrelevant. Irrelevant failures consume

time and should be reduced as much as possible.

In the future we want to keep getting more aggressive on CI testing,

for example test OCaml packages against the development version of

OCaml on a regular basis. Again, broken builds slow us down and make

it harder to spot the true issues.

Also

If you have encountered other packages that fail to build on the opam

CI, feel free to make a post of your own to list them, with build

logs, and encourage us all to contribute in fixing the issue.