From 18131492da1fece875707d7787549f3f9cf7783c Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?S=C3=A9bastien=20Villemot?= <sebastien@dynare.org>
Date: Thu, 4 Apr 2024 16:04:03 +0200
Subject: [PATCH] CI: workaround for testsuite lockups with MATLAB R2024a

By symlinking ~/.MathWorks to /dev/null, MATLAB is unable to copy and launch
the ServiceHost binary, which seems to cause lockups. See for example:
https://git.dynare.org/Dynare/dynare/-/jobs/62558
https://git.dynare.org/Dynare/dynare/-/jobs/62547
---
 .gitlab-ci.yml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index dd335080f8..4dd1e14be9 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -145,6 +145,8 @@ pkg_macOS_arm64:
 test_matlab:
   stage: test
   script:
+    # Workaround for R2024a, that prevents lockups apparently linked to the ServiceHost daemon
+    - rm -rf ~/.MathWorks && ln -s /dev/null ~/.MathWorks
     - meson test -C build-matlab --no-rebuild --num-processes $(($(nproc) * 3 / 4))
   artifacts:
     paths:
-- 
GitLab