[Git][ghc/ghc][ghc-9.6] 3 commits: ci: Remove FreeBSD job from release pipelines

Matthew Pickering (@mpickering) gitlab at gitlab.haskell.org
Fri Jan 27 08:51:29 UTC 2023



Matthew Pickering pushed to branch ghc-9.6 at Glasgow Haskell Compiler / GHC


Commits:
6d788b11 by Matthew Pickering at 2023-01-27T08:44:42+00:00
ci: Remove FreeBSD job from release pipelines

We no longer attempt to build or distribute this release

- - - - -
9c263aff by Matthew Pickering at 2023-01-27T08:46:57+00:00
rel_eng: Add check to make sure that release jobs are downloaded by fetch-gitlab

This check makes sure that if a job is a prefixed by "release-" then the
script downloads it and understands how to map the job name to the
platform.

- - - - -
0751f56a by Matthew Pickering at 2023-01-27T08:47:41+00:00
rel_eng: Fix the name of the ubuntu-* jobs

These were not uploaded for alpha1

Fixes #22844

- - - - -


3 changed files:

- .gitlab/gen_ci.hs
- .gitlab/jobs.yaml
- .gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py


Changes:

=====================================
.gitlab/gen_ci.hs
=====================================
@@ -875,7 +875,7 @@ job_groups =
      , fastCI (standardBuildsWithConfig Amd64 Windows (splitSectionsBroken vanilla))
      , disableValidate (standardBuildsWithConfig Amd64 Windows (splitSectionsBroken nativeInt))
      , standardBuilds Amd64 Darwin
-     , allowFailureGroup (addValidateRule FreeBSDLabel (standardBuilds Amd64 FreeBSD13))
+     , allowFailureGroup (addValidateRule FreeBSDLabel (validateBuilds Amd64 FreeBSD13 vanilla))
      , standardBuilds AArch64 Darwin
      , standardBuildsWithConfig AArch64 (Linux Debian10) (splitSectionsBroken vanilla)
      , standardBuildsWithConfig I386 (Linux Debian9) (splitSectionsBroken vanilla)


=====================================
.gitlab/jobs.yaml
=====================================
@@ -2299,68 +2299,6 @@
       "ac_cv_func_utimensat": "no"
     }
   },
-  "release-x86_64-freebsd13-release": {
-    "after_script": [
-      ".gitlab/ci.sh save_cache",
-      ".gitlab/ci.sh clean",
-      "cat ci_timings"
-    ],
-    "allow_failure": true,
-    "artifacts": {
-      "expire_in": "1 year",
-      "paths": [
-        "ghc-x86_64-freebsd13-release.tar.xz",
-        "junit.xml"
-      ],
-      "reports": {
-        "junit": "junit.xml"
-      },
-      "when": "always"
-    },
-    "cache": {
-      "key": "x86_64-freebsd13-$CACHE_REV",
-      "paths": [
-        "cabal-cache",
-        "toolchain"
-      ]
-    },
-    "dependencies": [],
-    "image": null,
-    "needs": [
-      {
-        "artifacts": false,
-        "job": "hadrian-ghc-in-ghci"
-      }
-    ],
-    "rules": [
-      {
-        "if": "($CI_MERGE_REQUEST_LABELS !~ /.*fast-ci.*/) && ($RELEASE_JOB == \"yes\") && ($NIGHTLY == null) && (\"true\" == \"true\") && (\"true\" == \"true\") && (\"true\" == \"true\")",
-        "when": "on_success"
-      }
-    ],
-    "script": [
-      ".gitlab/ci.sh setup",
-      ".gitlab/ci.sh configure",
-      ".gitlab/ci.sh build_hadrian",
-      ".gitlab/ci.sh test_hadrian"
-    ],
-    "stage": "full-build",
-    "tags": [
-      "x86_64-freebsd13"
-    ],
-    "variables": {
-      "BIGNUM_BACKEND": "gmp",
-      "BIN_DIST_NAME": "ghc-x86_64-freebsd13-release",
-      "BUILD_FLAVOUR": "release",
-      "CABAL_INSTALL_VERSION": "3.8.1.0",
-      "CONFIGURE_ARGS": "--with-gmp-includes=/usr/local/include --with-gmp-libraries=/usr/local/lib --with-iconv-includes=/usr/local/include --with-iconv-libraries=/usr/local/lib ",
-      "GHC_VERSION": "9.4.3",
-      "HADRIAN_ARGS": "--docs=no-sphinx",
-      "IGNORE_PERF_FAILURES": "all",
-      "TEST_ENV": "x86_64-freebsd13-release",
-      "XZ_OPT": "-9"
-    }
-  },
   "release-x86_64-linux-alpine3_12-int_native-release+fully_static": {
     "after_script": [
       ".gitlab/ci.sh save_cache",


=====================================
.gitlab/rel_eng/fetch-gitlab-artifacts/fetch_gitlab.py
=====================================
@@ -12,13 +12,15 @@ def strip_prefix(s, prefix):
     else:
         return None
 
+do_not_distribute = set(["release-x86_64-linux-fedora33-release-hackage"])
+
 def job_triple(job_name):
     bindists = {
         'release-x86_64-windows-release': 'x86_64-unknown-mingw32',
         'release-x86_64-windows-int_native-release': 'x86_64-unknown-mingw32-int_native',
         'release-x86_64-rocky8-release': 'x86_64-rocky8-linux',
-        'release-x86_64-ubuntu20_04-release': 'x86_64-ubuntu20_04-linux',
-        'release-x86_64-ubuntu18_04-release': 'x86_64-ubuntu18_04-linux',
+        'release-x86_64-linux-ubuntu20_04-release': 'x86_64-ubuntu20_04-linux',
+        'release-x86_64-linux-ubuntu18_04-release': 'x86_64-ubuntu18_04-linux',
         'release-x86_64-linux-fedora33-release+debug_info': 'x86_64-fedora33-linux-dwarf',
         'release-x86_64-linux-fedora33-release': 'x86_64-fedora33-linux',
         'release-x86_64-linux-fedora27-release': 'x86_64-fedora27-linux',
@@ -54,6 +56,12 @@ def job_triple(job_name):
         #return strip_prefix(job.name, 'validate-')
         return None
 
+class UnhandledJobException(Exception):
+    # Raised when there is a release job in the pipeline but we don't explicitly handle it.
+    def __init__(self, name):
+        self.message = f"{name} is a release job but not downloaded"
+        super().__init__(self.message)
+
 def fetch_artifacts(release: str, pipeline_id: int,
                     dest_dir: Path, gl: gitlab.Gitlab):
     dest_dir.mkdir(exist_ok=True)
@@ -72,6 +80,8 @@ def fetch_artifacts(release: str, pipeline_id: int,
         job = proj.jobs.get(pipeline_job.id)
         triple = job_triple(job.name)
         if triple is None:
+            if job.name.startswith("release") and not (job.name in do_not_distribute):
+                raise(UnhandledJobException(job.name))
             logging.info(f'ignoring {job.name}')
             continue
 



View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/3e6ca4d13037821052d2a33e3ac07f15898d63c8...0751f56af51eb7a6d71d20cabb5e8e12209fcf99

-- 
View it on GitLab: https://gitlab.haskell.org/ghc/ghc/-/compare/3e6ca4d13037821052d2a33e3ac07f15898d63c8...0751f56af51eb7a6d71d20cabb5e8e12209fcf99
You're receiving this email because of your account on gitlab.haskell.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/ghc-commits/attachments/20230127/ba2ba803/attachment-0001.html>


More information about the ghc-commits mailing list