Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

improve how gap workspace caching works #407

Closed
williamstein opened this issue Jul 27, 2007 · 1 comment
Closed

improve how gap workspace caching works #407

williamstein opened this issue Jul 27, 2007 · 1 comment

Comments

@williamstein
Copy link
Contributor

On 7/26/07, Dan Christensen <jdc@uwo.ca> wrote:
> 
> "David Joyner" <wdjoyner@gmail.com> writes:
> 
> > Could you please try gap_reset_workspace() and then restart SAGE
> > and see if the examples start?
> 
> That fixed it!  Thanks.  Not sure what I did.  The problem occurred on
> two different systems, which my home directory is mirrored between.
> If it happens again, I'll report any additional info I can think of.

Very interesting.  When you install the gap database, SAGE runs
gap_reset_workspace() to update the cached workspace on the machine
on which the database is installed.  Because a single home directory could
be used by multiple machines, there are potentially multiple gap workspace
cache files, and for you only one was updated.   

This is an annoying design (due to me), since multiple users of a single
SAGE install will all have to type gap_reset_workspace() to get the new gap
libraries (when one installs, e.g., the small group database). 

I should change the implementation so when installing database_gap (or
anything else that might invalidate the stored gap workspace, or more precisely
make it not optimal), then *all* gap workspace cache files from all users of
that SAGE install become invalid.  They would then be regenerated (which takes
only a few seconds) the next time any user starts GAP from a SAGE session.
I could do this by assigning a sequence number, e.g., in a file like 
local/lib/gap-sequence-number, which is incremented any time gap is updated
in some way.  Then I could make the cached workspace (or another file
with a similar name next to the gap workspace file) also store this 
sequence number (the cached workspaces are in ~/.sage/gap/).  
Then whenever a gap interpreter is first started in interface/gap.py, 
this sequence number is checked, and if it doesn't match, then the gap workspace
is regenerated.  This should completely eliminate all future gap_reset_workspace
synchronization errors. 

I'll wait to see if anybody thinks the above idea is stupid, and if not,
I'll implement it (which shouldn't take long). 

 -- William

Component: packages: standard

Issue created by migration from https://trac.sagemath.org/ticket/407

@sagetrac-mabshoff
Copy link
Mannequin

sagetrac-mabshoff mannequin commented Sep 10, 2007

comment:1

Looks like a duplicate of #527.

Cheers,

Michael

@sagetrac-mabshoff sagetrac-mabshoff mannequin added this to the sage-2.9 milestone Sep 10, 2007
@sagetrac-mabshoff sagetrac-mabshoff mannequin modified the milestones: sage-2.9.1, sage-2.9 Nov 3, 2007
@williamstein williamstein modified the milestones: sage-2.9, sage-2.8.12 Nov 3, 2007
tobiasdiez pushed a commit to tobiasdiez/sage that referenced this issue Feb 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant