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

save_notebook is called twice on notebook shutdown #7801

Closed
qed777 mannequin opened this issue Jan 1, 2010 · 6 comments
Closed

save_notebook is called twice on notebook shutdown #7801

qed777 mannequin opened this issue Jan 1, 2010 · 6 comments

Comments

@qed777
Copy link
Mannequin

qed777 mannequin commented Jan 1, 2010

See run_notebook.py's run_twisted, which generates DOT_SAGE/sagen_notebook.sagenb/twistedconf.tac.

Mentioned here.

Component: notebook

Author: Alex Leone

Reviewer: Tim Dumol

Merged: sagenb-0.6

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

@qed777 qed777 mannequin added c: user interface labels Jan 1, 2010
@qed777 qed777 mannequin assigned williamstein Jan 1, 2010
@sagetrac-acleone
Copy link
Mannequin

sagetrac-acleone mannequin commented Jan 19, 2010

Attachment: trac_7801-save_notebook_twice.patch.gz

Fixed interrupt handler to stop the twisted server instead of in save_notebook

@sagetrac-acleone
Copy link
Mannequin

sagetrac-acleone mannequin commented Jan 19, 2010

comment:1

What the problem was:
The signal handler would call save_notebook(), which would stop the twisted server. There was a handler on the server shutdown, "reactor.addSystemEventTrigger('before', 'shutdown', save_notebook)", that would call save_notebook() again.

Changes:
Moved the code that stops the server into the signal handler, and removed the save_notebook call.

@TimDumol
Copy link
Mannequin

TimDumol mannequin commented Jan 19, 2010

Author: Alex Leone

@TimDumol
Copy link
Mannequin

TimDumol mannequin commented Jan 19, 2010

comment:2

LGTM. Nice job.

@TimDumol
Copy link
Mannequin

TimDumol mannequin commented Jan 19, 2010

Reviewer: Tim Dumol

@TimDumol TimDumol mannequin added this to the sage-4.3.2 milestone Jan 19, 2010
@TimDumol
Copy link
Mannequin

TimDumol mannequin commented Jan 19, 2010

Merged: sagenb-0.6

@TimDumol TimDumol mannequin removed the s: positive review label Jan 19, 2010
@TimDumol TimDumol mannequin closed this as completed Jan 19, 2010
@mwhansen mwhansen modified the milestones: sage-4.3.2, sage-4.3.1 Jan 19, 2010
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

2 participants