-
-
Notifications
You must be signed in to change notification settings - Fork 97
attach is broken #169
Comments
This reportedly worked in some sage-5.x version https://groups.google.com/d/msg/sage-devel/gHlK7zmgcAg/mREDSLLeI7wJ |
I suspect it might have been earlier than 5.4. The flask notebook was On Wed, Jun 26, 2013 at 12:07 PM, vbraun notifications@github.com wrote:
|
Given the current state of the notebook we should just remove the attach functionality in the notebook. Can be re-added to the new notebook when it is out. |
So if we don't find a fix, should we make 'attach' just work like 'load', along with a warning that this is what it's doing? Meanwhile, not only does it do automatic reloading, it just doesn't work: if I
then 3 gets printed, but if I evaluate |
I would prefer to just disable it, or maybe print an error message telling the user to use |
Interestingly, I don't get any errors, just that it doesn't redo stuff when I change a file - whether from |
I strongly suspect that this is related to lazy import, as pointed out in http://trac.sagemath.org/ticket/15308#comment:3 - at any rate, I'll be trying this out to see. Edit: or maybe not, still seems to be broken in earlier versions - I can't get it to work in 5.2, though the error is quite different, a recursion depth issue. |
Interestingly, anything that requires preparsing seems to be bad now. |
Using |
Automatic reloading of attached files is broken on Sage-5.10.rc2. For example, start with a file containing "x=1". Then, in the notebook:
attach('/tmp/t.py')
x
works as intended. Now change the file to "x=2". All subsequent evaluations yield
Traceback (most recent call last):
File "", line 1, in
File "sage_input_5.py", line 10, in
exec compile(u'open("code.py","w").write("# -- coding: utf-8 --\n" + support.preparse_worksheet_cell(base64.b64decode("eA=="),globals())+"\n"); execfile(os.path.abspath("_code.py"))
File "", line 1, in
File "/tmp/tmpdG1Jqn/_code_.py", line 2
"/tmp/t.py"
^
IndentationError: unexpected indent
Ideally, this would be fixed in a way compatible with http://trac.sagemath.org/14523
The text was updated successfully, but these errors were encountered: