@Karl Palmskog : I don't know if you have seen my comment in (https://github.com/coq/opam-coq-archive/pull/1537). This PR fails because the CI of opam-coq-archive doesn't call depext. I guess for pure Coq packages this is fine, but gappa has a lengthy list of depext packages.
Do you think it would be feasible / OK to have depext in opam-coq-archive CI? If not I can remove the gappa.dev package and keep it forver in the opam patch repo of the Coq Platform master branch. The release package is in the main opam repo and passes CI fine there on many platforms (they call opam depext).
@Michael Soegtrop adding depext just because of gappa seems unncessary. Why not just add the required Debian packages into the CI config like Enrico suggested?
You mean add these packages in the CI config for all packages? This might be more wasteful than calling opam depext for all installed packages. If I remember right gappa has a few dependencies which take a while to install (boost?).
But as I said, if this is problematic, I see no issue in keeping the gappa package forever in the Coq Platform Master patch repo. For the release branches there is no issue, since gappa is in the opam main (not coq) repo.
every CI run in the opam archive builds Coq, so almost any binary package installation will be a drop in the bucket
You don't install boost regularly I guess ;-)
(boost is about 13.000 C header files and this makes even binary instalations quite slow - depending on how many sanity checks the package manager does per file).
Even on fast machines it can take a few minutes.
@Karl Palmskog : I thought aboit this and I don't like the idea of adding the packages to CI a lot. There will likely come more of this (Z3 for Coq-hammer, ...) and I like the platform independent way of depext. Adding depext is a one time effort for many packages.
can you coordinate with Enrico if you want to add depext stuff? I think he was the last person to fiddle with those scripts. What I don't want to happen is for regular CI jobs to fail due to scripting issues that were added for Gappa, which almost nobody uses
or in other words, I would rather have a working CI that fails for some packages with obscure dependencies than a faulty CI tailored for packages with such dependencies.
I think it doesn't make a lot of sense to handle complicated dependencies for each package and each CI system separately.
So the options I see are:
I am fine with either way - your choice. I don't think that handling depext will be complicated. It should be one command to install it and one to run it. It should only fail if depext entries are bogus. Sure I can align with @Enrico Tassi on this topic as you suggest.
@Enrico Tassi: I had a quick look at the CI scripts. A few questions:
- test -e $OPAM_ROOT_CACHE || scripts/opam-coq-init
- curl -L https://github.com/ocaml/opam/releases/download/${OPAM_VERSION}/opam-${OPAM_VERSION}-x86_64-linux >/usr/local/bin/opam
test -e $OPAM_ROOT_CACHE
fails or what to do to reinit opam. If we add depext it would make most sense to do it once.opam-build:any:
. Which one is the correct?opam-coq-install-remove
has set -e
but checks for errors with if [ $? != 0 ]; then
- do I miss something?set +e
echo Installing $PKG_NAME_VERSION
opam install "$PKG_NAME_VERSION" -y -v -v $EXTRA_OPAM_OPTION >> $LOG
if [ $? != 0 ]; then
RC=1;
FAILURES="$FAILURES $PKG_NAME_VERSION";
else
SUCCESSES="$SUCCESSES $PKG_NAME_VERSION";
fi
echo Removing $PKG_NAME
opam remove "$PKG_NAME" -y >> $LOG
set -e
which seems correct about set +/- e
The point is that we want to try all packages, even if one fails, and this is important since many PRs add/modify many packages.
@Enrico Tassi : Ah yes, I didn't see the inner set +e
- this is fine then.
How can I clear the cache in case I want to add something (that is depext) to the tar file generated at the end of opam-coq-init? For Travis there are buttons in the settings section, but I couldn't find something similar for Gitlab.
What I still don't understand is the logic of running opam (in opam-coq-init) and one line later downloading a different opam. What is the point of doing it in this order rather than the other way around? Wouldn't the first step fail if there is no opam installed as yet?
I don't know how the cache works in gitlab ci (originally the scripts were using travis)
if the cache is there, then you don't run opam-coq-init. if it is not, then you install opam twice
Last updated: Jun 03 2023 at 05:01 UTC