Просмотр исходного кода

CI: Explicitly enable audio access on macOS 14

On the macOS 14 runners on GitHub actions, attempting to play audio (by
way of AudioOutputUnitStart) will open a pop-up asking for microphone
permission. This prevents any calling test to hang until they error out
with MACH_SEND_TIMED_OUT. This works around the issue by explicitly
enabling microphone access to all applications.
Timothy Flynn 1 год назад
Родитель
Сommit
a447b9bffd
1 измененных файлов с 5 добавлено и 0 удалено
  1. 5 0
      .github/workflows/lagom.yml

+ 5 - 0
.github/workflows/lagom.yml

@@ -65,6 +65,11 @@ jobs:
             echo "host_cxx=$(brew --prefix llvm@18)/bin/clang++" >> "$GITHUB_OUTPUT"
           fi
 
+      # https://github.com/actions/runner-images/issues/9330
+      - name: Allow microphone access to all apps (macOS 14)
+        run: sqlite3 $HOME/Library/Application\ Support/com.apple.TCC/TCC.db "INSERT OR IGNORE INTO access VALUES ('kTCCServiceMicrophone','/usr/local/opt/runner/provisioner/provisioner',1,2,4,1,NULL,NULL,0,'UNUSED',NULL,0,1687786159,NULL,NULL,'UNUSED',1687786159);"
+        if: ${{ matrix.os == 'macos-14' }}
+
       - name: Create Build Environment
         working-directory: ${{ github.workspace }}/Meta/Lagom
         run: |