(for PR #25720)

2024-04-26 13:17.10: New job: build ppx_deriving_yojson.3.8.0, using opam dev
                              from https://github.com/ocaml/opam-repository.git#refs/pull/25720/head (7edd88808a339b9f4b325cc31d3b5cfbee2ddf5b)
                              on debian-12-ocaml-4.03/amd64

To reproduce locally:

cd $(mktemp -d)
git clone --recursive "https://github.com/ocaml/opam-repository.git" && cd "opam-repository" && git fetch origin "refs/pull/25720/head" && git reset --hard 7edd8880
git fetch origin master
git merge --no-edit 01db0f1d8c7b59beff7b97ab33a28f2a46de9d77
cat > ../Dockerfile <<'END-OF-DOCKERFILE'
FROM ocaml/opam:debian-12-ocaml-4.03@sha256:af0445b1832ae64cb5bad3ed80318fb61b334ada500787c0c14a8a81f36ed11e
USER 1000:1000
WORKDIR /home/opam
RUN sudo ln -f /usr/bin/opam-dev /usr/bin/opam
RUN opam init --reinit -ni
RUN uname -rs && opam exec -- ocaml -version && opam --version
ENV OPAMDOWNLOADJOBS="1"
ENV OPAMERRLOGLEN="0"
ENV OPAMSOLVERTIMEOUT="500"
ENV OPAMPRECISETRACKING="1"
ENV CI="true"
ENV OPAM_REPO_CI="true"
RUN rm -rf opam-repository/
COPY --chown=1000:1000 . opam-repository/
RUN opam repository set-url --strict default opam-repository/
RUN opam update --depexts || true
ENV OPAMCRITERIA="-removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed"
ENV OPAMFIXUPCRITERIA="-removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed"
ENV OPAMUPGRADECRITERIA="-removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed"
RUN opam pin add -k version -yn ppx_deriving_yojson.3.8.0 3.8.0
RUN opam reinstall ppx_deriving_yojson.3.8.0; \
    res=$?; \
    test "$res" != 31 && exit "$res"; \
    export OPAMCLI=2.0; \
    build_dir=$(opam var prefix)/.opam-switch/build; \
    failed=$(ls "$build_dir"); \
    partial_fails=""; \
    for pkg in $failed; do \
    if opam show -f x-ci-accept-failures: "$pkg" | grep -qF "\"debian-12\""; then \
    echo "A package failed and has been disabled for CI using the 'x-ci-accept-failures' field."; \
    fi; \
    test "$pkg" != 'ppx_deriving_yojson.3.8.0' && partial_fails="$partial_fails $pkg"; \
    done; \
    test "${partial_fails}" != "" && echo "opam-repo-ci detected dependencies failing: ${partial_fails}"; \
    exit 1

END-OF-DOCKERFILE
docker build -f ../Dockerfile .

2024-04-26 13:17.10: Using cache hint "ocaml/opam:debian-12-ocaml-4.03@sha256:af0445b1832ae64cb5bad3ed80318fb61b334ada500787c0c14a8a81f36ed11e-ppx_deriving_yojson.3.8.0-7edd88808a339b9f4b325cc31d3b5cfbee2ddf5b"
2024-04-26 13:17.10: Using OBuilder spec:
((from ocaml/opam:debian-12-ocaml-4.03@sha256:af0445b1832ae64cb5bad3ed80318fb61b334ada500787c0c14a8a81f36ed11e)
 (user (uid 1000) (gid 1000))
 (workdir /home/opam)
 (run (shell "sudo ln -f /usr/bin/opam-dev /usr/bin/opam"))
 (run (network host)
      (shell "opam init --reinit --config .opamrc-sandbox -ni"))
 (run (shell "uname -rs && opam exec -- ocaml -version && opam --version"))
 (env OPAMDOWNLOADJOBS 1)
 (env OPAMERRLOGLEN 0)
 (env OPAMSOLVERTIMEOUT 500)
 (env OPAMPRECISETRACKING 1)
 (env CI true)
 (env OPAM_REPO_CI true)
 (run (shell "rm -rf opam-repository/"))
 (copy (src .) (dst opam-repository/))
 (run (shell "opam repository set-url --strict default opam-repository/"))
 (run (network host)
      (shell "opam update --depexts || true"))
 (env OPAMCRITERIA -removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed)
 (env OPAMFIXUPCRITERIA -removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed)
 (env OPAMUPGRADECRITERIA -removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed)
 (run (shell "opam pin add -k version -yn ppx_deriving_yojson.3.8.0 3.8.0"))
 (run (cache (opam-archives (target /home/opam/.opam/download-cache)))
      (network host)
      (shell  "opam reinstall ppx_deriving_yojson.3.8.0;\
             \n        res=$?;\
             \n        test \"$res\" != 31 && exit \"$res\";\
             \n        export OPAMCLI=2.0;\
             \n        build_dir=$(opam var prefix)/.opam-switch/build;\
             \n        failed=$(ls \"$build_dir\");\
             \n        partial_fails=\"\";\
             \n        for pkg in $failed; do\
             \n          if opam show -f x-ci-accept-failures: \"$pkg\" | grep -qF \"\\\"debian-12\\\"\"; then\
             \n            echo \"A package failed and has been disabled for CI using the 'x-ci-accept-failures' field.\";\
             \n          fi;\
             \n          test \"$pkg\" != 'ppx_deriving_yojson.3.8.0' && partial_fails=\"$partial_fails $pkg\";\
             \n        done;\
             \n        test \"${partial_fails}\" != \"\" && echo \"opam-repo-ci detected dependencies failing: ${partial_fails}\";\
             \n        exit 1"))
)

2024-04-26 13:17.10: Waiting for resource in pool OCluster
2024-04-26 14:03.12: Waiting for worker…
2024-04-26 14:07.36: Got resource from pool OCluster
Building on x86-bm-c14.sw.ocaml.org
All commits already cached
Updating files:  78% (26418/33561)
Updating files:  79% (26514/33561)
Updating files:  80% (26849/33561)
Updating files:  81% (27185/33561)
Updating files:  82% (27521/33561)
Updating files:  83% (27856/33561)
Updating files:  84% (28192/33561)
Updating files:  85% (28527/33561)
Updating files:  86% (28863/33561)
Updating files:  87% (29199/33561)
Updating files:  88% (29534/33561)
Updating files:  89% (29870/33561)
Updating files:  90% (30205/33561)
Updating files:  91% (30541/33561)
Updating files:  92% (30877/33561)
Updating files:  93% (31212/33561)
Updating files:  94% (31548/33561)
Updating files:  95% (31883/33561)
Updating files:  96% (32219/33561)
Updating files:  97% (32555/33561)
Updating files:  98% (32890/33561)
Updating files:  99% (33226/33561)
Updating files: 100% (33561/33561)
Updating files: 100% (33561/33561), done.
HEAD is now at 01db0f1d8c Merge pull request #25712 from toots/opam-publish-mad.0.5.3
Updating 01db0f1d8c..7edd88808a
Fast-forward
 .../ppx_deriving_yojson.3.8.0/opam                 | 34 ++++++++++++++++++++++
 packages/safemoney/safemoney.0.1.0/opam            |  2 +-
 packages/safemoney/safemoney.0.1.1/opam            |  2 +-
 3 files changed, 36 insertions(+), 2 deletions(-)
 create mode 100644 packages/ppx_deriving_yojson/ppx_deriving_yojson.3.8.0/opam

(from ocaml/opam:debian-12-ocaml-4.03@sha256:af0445b1832ae64cb5bad3ed80318fb61b334ada500787c0c14a8a81f36ed11e)
2024-04-26 14:08.35 ---> saved as "c783b8e1a6c826c09febac741a9cf96e1fb4bc9d8374f82c073ddde0dd8e1c2f"

/: (user (uid 1000) (gid 1000))

/: (workdir /home/opam)

/home/opam: (run (shell "sudo ln -f /usr/bin/opam-dev /usr/bin/opam"))
2024-04-26 14:08.36 ---> saved as "34678f2916246e4deead625eb2291813f091fce37a9d086260f724447d71b750"

/home/opam: (run (network host)
                 (shell "opam init --reinit --config .opamrc-sandbox -ni"))
Configuring from /home/opam/.opamrc-sandbox, then /home/opam/.opamrc, and finally from built-in defaults.
Checking for available remotes: rsync and local, git.
  - you won't be able to use mercurial repositories unless you install the hg command on your system.
  - you won't be able to use darcs repositories unless you install the darcs command on your system.

This development version of opam requires an update to the layout of /home/opam/.opam from version 2.0 to version 2.2~alpha, which can't be reverted.
You may want to back it up before going further.

Continue? [y/n] y
[NOTE] The 'jobs' option was reset, its value was 255 and its new value will vary according to the current number of cores on your machine. You can restore the fixed value using:
           opam option jobs=255 --global
Format upgrade done.

<><> Updating repositories ><><><><><><><><><><><><><><><><><><><><><><><><><><>
[default] synchronised from file:///home/opam/opam-repository
2024-04-26 14:10.06 ---> saved as "94b2ea97a09408d20eb72e816009a6b2ff92ea697780c5de139b20aafbb50c40"

/home/opam: (run (shell "uname -rs && opam exec -- ocaml -version && opam --version"))
Linux 5.15.0-101-generic
The OCaml toplevel, version 4.03.0
2.2.0~beta3~dev
2024-04-26 14:10.06 ---> saved as "380b2472286ecb5395aac0613406277375d56b4741e51817f82417b168d2f691"

/home/opam: (env OPAMDOWNLOADJOBS 1)

/home/opam: (env OPAMERRLOGLEN 0)

/home/opam: (env OPAMSOLVERTIMEOUT 500)

/home/opam: (env OPAMPRECISETRACKING 1)

/home/opam: (env CI true)

/home/opam: (env OPAM_REPO_CI true)

/home/opam: (run (shell "rm -rf opam-repository/"))
2024-04-26 14:10.19 ---> saved as "6c858250182fca74bc5183ad9c5c8424bdc588f7057e3c0fda18ed39b27fc403"

/home/opam: (copy (src .) (dst opam-repository/))
2024-04-26 14:10.30 ---> saved as "00f7aa2b95b8014ecacbd9ab2022a5739debb879d7f100be91f9adfe192f7e4e"

/home/opam: (run (shell "opam repository set-url --strict default opam-repository/"))
[default] Initialised
2024-04-26 14:11.23 ---> saved as "23e0726da8bd3251370e82821b98470dbeaa843cf411575493d9159ad5f6de10"

/home/opam: (run (network host)
                 (shell "opam update --depexts || true"))
+ /usr/bin/sudo "apt-get" "update"
- Hit:1 http://deb.debian.org/debian bookworm InRelease
- Get:2 http://deb.debian.org/debian bookworm-updates InRelease [55.4 kB]
- Get:3 http://deb.debian.org/debian-security bookworm-security InRelease [48.0 kB]
- Get:4 http://deb.debian.org/debian bookworm-updates/main amd64 Packages.diff/Index [10.6 kB]
- Get:5 http://deb.debian.org/debian bookworm-updates/main amd64 Packages T-2024-04-23-2036.10-F-2024-04-23-2036.10.pdiff [1595 B]
- Get:5 http://deb.debian.org/debian bookworm-updates/main amd64 Packages T-2024-04-23-2036.10-F-2024-04-23-2036.10.pdiff [1595 B]
- Get:6 http://deb.debian.org/debian-security bookworm-security/main amd64 Packages [155 kB]
- Fetched 270 kB in 0s (1013 kB/s)
- Reading package lists...
2024-04-26 14:11.24 ---> saved as "9e37084a649d7896dc29edcda7e84ffddc5109a8deb7dfe95cbc505a25d27daf"

/home/opam: (env OPAMCRITERIA -removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed)

/home/opam: (env OPAMFIXUPCRITERIA -removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed)

/home/opam: (env OPAMUPGRADECRITERIA -removed,-count[avoid-version,changed],-count[version-lag,request],-count[version-lag,changed],-count[missing-depexts,changed],-changed)

/home/opam: (run (shell "opam pin add -k version -yn ppx_deriving_yojson.3.8.0 3.8.0"))
ppx_deriving_yojson is now pinned to version 3.8.0
2024-04-26 14:11.25 ---> saved as "0e620052e668e210b60848763500b352dc4a71f0f3d35670ac28142a93c517c8"

/home/opam: (run (cache (opam-archives (target /home/opam/.opam/download-cache)))
                 (network host)
                 (shell  "opam reinstall ppx_deriving_yojson.3.8.0;\
                        \n        res=$?;\
                        \n        test \"$res\" != 31 && exit \"$res\";\
                        \n        export OPAMCLI=2.0;\
                        \n        build_dir=$(opam var prefix)/.opam-switch/build;\
                        \n        failed=$(ls \"$build_dir\");\
                        \n        partial_fails=\"\";\
                        \n        for pkg in $failed; do\
                        \n          if opam show -f x-ci-accept-failures: \"$pkg\" | grep -qF \"\\\"debian-12\\\"\"; then\
                        \n            echo \"A package failed and has been disabled for CI using the 'x-ci-accept-failures' field.\";\
                        \n          fi;\
                        \n          test \"$pkg\" != 'ppx_deriving_yojson.3.8.0' && partial_fails=\"$partial_fails $pkg\";\
                        \n        done;\
                        \n        test \"${partial_fails}\" != \"\" && echo \"opam-repo-ci detected dependencies failing: ${partial_fails}\";\
                        \n        exit 1"))
ppx_deriving_yojson.3.8.0 is not installed. Install it? [y/n] y
  * No agreement on the version of ocaml:
    - (invariant) -> ocaml-base-compiler = 4.03.0 -> ocaml = 4.03.0
    - ppx_deriving_yojson >= 3.8.0 -> ocaml >= 4.05.0
    You can temporarily relax the switch invariant with `--update-invariant'
  * Incompatible packages:
    - (invariant) -> ocaml-base-compiler = 4.03.0
    - ppx_deriving_yojson >= 3.8.0 -> ocaml >= 4.05.0 -> ocaml-variants >= 5.1.1~

No solution found, exiting
"/usr/bin/env" "bash" "-c" "opam reinstall ppx_deriving_yojson.3.8.0;
        res=$?;
        test "$res" != 31 && exit "$res";
        export OPAMCLI=2.0;
        build_dir=$(opam var prefix)/.opam-switch/build;
        failed=$(ls "$build_dir");
        partial_fails="";
        for pkg in $failed; do
          if opam show -f x-ci-accept-failures: "$pkg" | grep -qF "\"debian-12\""; then
            echo "A package failed and has been disabled for CI using the 'x-ci-accept-failures' field.";
          fi;
          test "$pkg" != 'ppx_deriving_yojson.3.8.0' && partial_fails="$partial_fails $pkg";
        done;
        test "${partial_fails}" != "" && echo "opam-repo-ci detected dependencies failing: ${partial_fails}";
        exit 1" failed with exit status 20
2024-04-26 14:11.54: Job failed: Failed: Build failed
2024-04-26 14:11.54: Log analysis:
2024-04-26 14:11.54: >>> 
No solution found, exiting
 (score = 100)
2024-04-26 14:11.54: [SKIP] Package not available