You are not logged in.
When using Sage's notebook, via jupyter, whenever evaluating a cell, regardless of its content (as long as it is valid code), I get the following warning:
/usr/lib/python2.7/json/encoder.py:207: DeprecationWarning: Interpreting naive datetime as local 2017-07-07 12:19:20.338945. Please add timezone info to timestamps.
chunks = self.iterencode(o, _one_shot=True)
A bit of googling indicated that this was indeed a bug, that has in the meantime, been fixed. However, no matter how much I updated, I keep stumbling upon across it. So to see if I could compile a list of steps to reproduce the problem, I uninstalled everything Sage plus dependencies (and also removed ~/.sage and ~/.jupyter)
# pacman -Rs sagemath sage-notebook sagemath-jupyter
Then I installed sagemath-jupyter, which pulls the necessary dependencies for sage et al.
# pacman -S sagemath-jupyter
Now start the notebook:
$ jupyter notebook
Then with kernel sagemath selected, type (eg)
print("foo")
and hit Shift+Enter (for evaluation). You get the above warning. The reason I post this in the forum, as opposed to a bug report, is because I found so little information about this bug in Archlinux that I can't help but wonder if I misconfigured something (and then forgot about it until I needed the notebook again...)
Thank you in advance.
EDIT TO ADD: I also have installed kernels for Python 2 and 3, but this warning is NOT shown when using either of those.
Last edited by gauthma (2017-07-10 13:05:29)
Offline
Add
warnings.filterwarnings(action='ignore')
to ~/.sage/init.sage
Offline
Add
warnings.filterwarnings(action='ignore')
to ~/.sage/init.sage
Thanks, this definitely makes working in the notebook more bearable... but of course does not fix the underlying problem... is a bug report appropriate?
Offline
Well, you said it has been fixed already, so it will make its way into the repos eventually. If you can pinpoint where the fix is you can open a backport request, otherwise it can be a mess to dig into the gazillion python modules involved here to figure out where the issue is. A full backtrace of the warning would definitely help.
Offline
Well, my understanding of this is that the problem (which is with jupyter only) is fixed. And in fact, when using jupyter with a Python 2 or 3 kernel, I don't get that warning.
It only happens when using sage, which is I think the problem must be in sage's kernel. I originally thought that the link said the problem with sage was fixed; it was only when I searched again for that link above that I noticed that the underlying problem was about jupyter alone -- that is the one that is fixed. Sorry about that
Which means submitting a bug report (about the sage kernel) might not be the worst of ideas...
Offline
According to that link the fix is in ipykernel 4.6.1, which is not in our repos yet
Offline
Well, I guess that settles it then
Offline