(for PR #27887)

2025-05-19 10:14.10: New job: build ocaml-variants.5.3.0+BER, using opam 2.0
                              from https://github.com/ocaml/opam-repository.git#refs/pull/27887/head (433941096ba89ee82e098993795b9cda9a1179d6)
                              on debian-12-ocaml-5.3/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/27887/head" && git reset --hard 43394109
git fetch origin master
git merge --no-edit 55711315d054c8d83610afaedab4b5cbd30de09d
cat > ../Dockerfile <<'END-OF-DOCKERFILE'
FROM ocaml/opam:debian-12-ocaml-5.3@sha256:601a187e2900fccdc210cf20312e1bb4b7d0d219d790e3a816c5bf992c14e3e6
USER 1000:1000
WORKDIR /home/opam
RUN sudo ln -f /usr/bin/opam-2.0 /usr/bin/opam
RUN opam init --reinit -ni
RUN opam config report
ENV OPAMDOWNLOADJOBS="1"
ENV OPAMERRLOGLEN="0"
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 depext -u || true
RUN opam pin add -k version -yn ocaml-variants.5.3.0+BER 5.3.0+BER
RUN opam depext ocaml-variants.5.3.0+BER && opam reinstall --update-invariant ocaml-variants.5.3.0+BER; \
    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" != 'ocaml-variants.5.3.0+BER' && 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 .

2025-05-19 10:14.10: Using cache hint "ocaml/opam:debian-12-ocaml-5.3@sha256:601a187e2900fccdc210cf20312e1bb4b7d0d219d790e3a816c5bf992c14e3e6-ocaml-variants.5.3.0+BER-433941096ba89ee82e098993795b9cda9a1179d6"
2025-05-19 10:14.10: Using OBuilder spec:
((from ocaml/opam:debian-12-ocaml-5.3@sha256:601a187e2900fccdc210cf20312e1bb4b7d0d219d790e3a816c5bf992c14e3e6)
 (user (uid 1000) (gid 1000))
 (workdir /home/opam)
 (run (shell "sudo ln -f /usr/bin/opam-2.0 /usr/bin/opam"))
 (run (network host)
      (shell "opam init --reinit --config .opamrc-sandbox -ni"))
 (run (shell "opam config report"))
 (env OPAMDOWNLOADJOBS 1)
 (env OPAMERRLOGLEN 0)
 (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 depext -u || true"))
 (run (shell "opam pin add -k version -yn ocaml-variants.5.3.0+BER 5.3.0+BER"))
 (run (cache (opam-archives (target /home/opam/.opam/download-cache)))
      (network host)
      (shell  "opam depext ocaml-variants.5.3.0+BER && opam reinstall --update-invariant ocaml-variants.5.3.0+BER;\
             \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\" != 'ocaml-variants.5.3.0+BER' && partial_fails=\"$partial_fails $pkg\";\
             \n        done;\
             \n        test \"${partial_fails}\" != \"\" && echo \"opam-repo-ci detected dependencies failing: ${partial_fails}\";\
             \n        exit 1"))
)

2025-05-19 10:14.10: Waiting for resource in pool OCluster
2025-05-19 10:14.11: Waiting for worker…
2025-05-19 10:18.04: Got resource from pool OCluster
Building on x86-bm-c4.sw.ocaml.org
All commits already cached
Updating files:  92% (21366/23052)
Updating files:  93% (21439/23052)
Updating files:  94% (21669/23052)
Updating files:  95% (21900/23052)
Updating files:  96% (22130/23052)
Updating files:  97% (22361/23052)
Updating files:  98% (22591/23052)
Updating files:  99% (22822/23052)
Updating files: 100% (23052/23052)
Updating files: 100% (23052/23052), done.
HEAD is now at 55711315d0 Merge pull request #27901 from deakodev/opam-publish-echo.0.0.4
Merge made by the 'ort' strategy.
 .../ocaml-variants/ocaml-variants.4.14.1+BER/opam  |  6 +++-
 .../ocaml-variants/ocaml-variants.5.3.0+BER/opam   | 41 +++++++++++++---------
 2 files changed, 30 insertions(+), 17 deletions(-)

(from ocaml/opam:debian-12-ocaml-5.3@sha256:601a187e2900fccdc210cf20312e1bb4b7d0d219d790e3a816c5bf992c14e3e6)
2025-05-19 10:18.07 ---> using "0585f6b0985f7eb566e20fd068ca8d674792c3b808091294d28083728c5a5ee6" from cache

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

/: (workdir /home/opam)

/home/opam: (run (shell "sudo ln -f /usr/bin/opam-2.0 /usr/bin/opam"))
2025-05-19 10:18.07 ---> saved as "516b3fd3fd9039a307d3a04e69397fa29d1cd17f49ebb613ded2da322e3c315f"

/home/opam: (run (network host)
                 (shell "opam init --reinit --config .opamrc-sandbox -ni"))
[NOTE] Will configure 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.

[WARNING] Recommended dependencies -- most packages rely on these:
  - m4

<><> Updating repositories ><><><><><><><><><><><><><><><><><><><><><><><><><><>
[default] Initialised
default (at git+file:///home/opam/opam-repository): 
    [INFO] opam 2.1 and 2.2 include many performance and security improvements over 2.0; please consider upgrading (https://opam.ocaml.org/doc/Install.html)

2025-05-19 10:19.12 ---> saved as "f26c62a6d17405227a9512f0c2f5b613546e7ef05ed83c157442740b3c9681ff"

/home/opam: (run (shell "opam config report"))
# opam config report
# opam-version      2.0.10 (adc1e1829a2bef5b240746df80341b508290fe3b) 
# self-upgrade      no
# system            arch=x86_64 os=linux os-distribution=debian os-version=12
# solver            builtin-mccs+glpk
# install-criteria  -removed,-count[version-lag,request],-count[version-lag,changed],-changed
# upgrade-criteria  -removed,-count[version-lag,solution],-new
# jobs              39
# repositories      1 (version-controlled)
# pinned            1 (version)
# current-switch    5.3
2025-05-19 10:19.12 ---> saved as "32f84a6580f2762020bc2c09ca5acb5efbba197a24c51e49d9f305ab4faf6dde"

/home/opam: (env OPAMDOWNLOADJOBS 1)

/home/opam: (env OPAMERRLOGLEN 0)

/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/"))
2025-05-19 10:19.19 ---> saved as "01ddecb9721b574a4736e5f1a32bed263b3ccfdfdc2c66adf48d203a63e7d9c7"

/home/opam: (copy (src .) (dst opam-repository/))
2025-05-19 10:19.27 ---> saved as "87cce95992ef6a17565e2651439d83b5c9eef4d2ccd02f7912c032b74097e502"

/home/opam: (run (shell "opam repository set-url --strict default opam-repository/"))
[default] Initialised
default (at file:///home/opam/opam-repository): 
    [INFO] opam 2.1 and 2.2 include many performance and security improvements over 2.0; please consider upgrading (https://opam.ocaml.org/doc/Install.html)

2025-05-19 10:19.44 ---> saved as "53d8c20cab145bea8502e6f25e58314e2884b9475502488fc9bd1a1a55d2e2e1"

/home/opam: (run (network host)
                 (shell "opam depext -u || true"))
# Detecting depexts using vars: arch=x86_64, os=linux, os-distribution=debian, os-family=debian
# No extra OS packages requirements found.
# All required OS packages found.
The following command needs to be run through "sudo":
    apt-get update
Get:1 http://deb.debian.org/debian bookworm InRelease [151 kB]
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/main amd64 Packages [8793 kB]
Get:5 http://deb.debian.org/debian-security bookworm-security/main amd64 Packages [259 kB]
Fetched 9306 kB in 1s (6432 kB/s)
Reading package lists...
# OS package update successful
2025-05-19 10:19.47 ---> saved as "1e1b3faa45e4ac157e0a68da9548de5c602f5668a77adc69093d80d31a2b4c36"

/home/opam: (run (shell "opam pin add -k version -yn ocaml-variants.5.3.0+BER 5.3.0+BER"))
ocaml-variants is now pinned to version 5.3.0+BER
2025-05-19 10:19.47 ---> saved as "7fffdf66d7e63efeb2e5add14122f6157fe6ddb6407447ce7fdba9de95e86f45"

/home/opam: (run (cache (opam-archives (target /home/opam/.opam/download-cache)))
                 (network host)
                 (shell  "opam depext ocaml-variants.5.3.0+BER && opam reinstall --update-invariant ocaml-variants.5.3.0+BER;\
                        \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\" != 'ocaml-variants.5.3.0+BER' && partial_fails=\"$partial_fails $pkg\";\
                        \n        done;\
                        \n        test \"${partial_fails}\" != \"\" && echo \"opam-repo-ci detected dependencies failing: ${partial_fails}\";\
                        \n        exit 1"))
# Detecting depexts using vars: arch=x86_64, os=linux, os-distribution=debian, os-family=debian
[ERROR] No solution for ocaml-variants.5.3.0+BER: Your request can't be satisfied:
          - conflict with the base packages of this switch


Command failed: opam list --readonly --external '--resolve=ocaml-variants.5.3.0+BER' --color=never returned 20
"/usr/bin/env" "bash" "-c" "opam depext ocaml-variants.5.3.0+BER && opam reinstall --update-invariant ocaml-variants.5.3.0+BER;
        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" != 'ocaml-variants.5.3.0+BER' && 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
2025-05-19 10:20.01: Job failed: Failed: Build failed
2025-05-19 10:20.01: Log analysis:
2025-05-19 10:20.01: >>> 
[ERROR] No solution for ocaml-variants.5.3.0+BER: Your request can't be satisfied:
 (score = 100)
2025-05-19 10:20.02: [SKIP] Package not available