Skip to content
This repository was archived by the owner on Apr 6, 2026. It is now read-only.

Commit cc2b31a

Browse files
authored
Set HOME in get-kernel-check-hook (#189)
Some kernels (especially those using Triton decorators) want to write to the home directory during import.
1 parent 2a04767 commit cc2b31a

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

pkgs/get-kernel-check/get-kernel-check-hook.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,10 @@ _getKernelCheckHook() {
1919
TMPDIR=$(mktemp -d -t test.XXXXXX) || exit 1
2020
trap "rm -rf '$TMPDIR'" EXIT
2121

22+
# Some kernels want to write stuff (especially when they use Triton).
23+
HOME=$(mktemp -d -t test.XXXXXX) || exit 1
24+
trap "rm -rf '$HOME'" EXIT
25+
2226
# Emulate the bundle layout that kernels expects. This even works
2327
# for universal kernels, since kernels checks the non-universal
2428
# path first.

0 commit comments

Comments
 (0)