Skip to content

Commit a801e6d

Browse files
author
Matthias Koeppe
committed
src/sage/interfaces/gap_workspace.py: Use hash of GAP_SO to disambiguate the workspace file, not SAGE_LOCAL
1 parent 2dc634e commit a801e6d

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/sage/interfaces/gap_workspace.py

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
import os
1717
import time
1818
import hashlib
19-
from sage.env import DOT_SAGE, SAGE_LOCAL
19+
from sage.env import DOT_SAGE, GAP_SO
2020

2121

2222
def gap_workspace_file(system="gap", name="workspace", dir=None):
@@ -59,7 +59,10 @@ def gap_workspace_file(system="gap", name="workspace", dir=None):
5959
if dir is None:
6060
dir = os.path.join(DOT_SAGE, 'gap')
6161

62-
h = hashlib.sha1(SAGE_LOCAL.encode('utf-8')).hexdigest()
62+
if GAP_SO:
63+
h = hashlib.sha1(GAP_SO.encode('utf-8')).hexdigest()
64+
else:
65+
h = 'unknown'
6366
return os.path.join(dir, '%s-%s-%s' % (system, name, h))
6467

6568

0 commit comments

Comments
 (0)