Ah I see. I assumed it would also try to spawn a browser or something. On the other hand, I understand some of the networking stuff is still not completed. You can of course use wget and the like so it can't be too broken.
Bill. On Friday, 9 December 2016 15:15:43 UTC+1, Dima Pasechnik wrote: > > > > On Friday, December 9, 2016 at 12:48:30 PM UTC, Bill Hart wrote: >> >> The Sage Notebook isn't likely to work under the WSL. It's a text console >> environment only. Microsoft intended it mainly to provide Linux development >> tools to people, not as a way of running graphical applications. >> > > Hmm, no, all what gets to run here is a web server (on a local port) > talking to a Sage backend. Graphics happens in a web browser, so it should > not be a problem of being "text console only". > > >> >> You can probably fix the memory allocation issues though. You likely need >> to increase the Pagefile system size. Windows allocates a ridiculously >> small amount of memory for this. >> >> There's a walkthrough here: >> >> http://www.softwareok.com/?seite=faq-Windows-10&faq=52 >> >> I use 16GB on my system (of course you need enough disk space). >> >> Bill. >> >> On Monday, 5 December 2016 11:24:21 UTC+1, GK wrote: >>> >>> Hi from me. My (more recent) experience is similar but not identical. I >>> install sage from the ppa and I am having problems. Sage loads and seems to >>> be working, but: >>> >>> ┌────────────────────────────────────────────────────────────────────┐ >>> │ SageMath version 7.3, Release Date: 2016-08-04 │ >>> │ Type "notebook()" for the browser-based notebook interface. │ >>> │ Type "help()" for help. │ >>> └────────────────────────────────────────────────────────────────────┘ >>> sage: gp.eval('2+2') >>> >>> --------------------------------------------------------------------------- >>> OSError Traceback (most recent call >>> last) >>> <ipython-input-1-e5d4083fb83e> in <module>() >>> ----> 1 gp.eval('2+2') >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/expect.pyc >>> >>> in eval(self, code, strip, synchronize, locals, allow_use_file, >>> split_lines, **kwds) >>> 1292 elif split_lines: >>> 1293 return '\n'.join([self._eval_line(L, >>> allow_use_file=allow_use_file, **kwds) >>> -> 1294 for L in >>> code.split('\n') if L != '']) >>> 1295 else: >>> 1296 return self._eval_line(code, >>> allow_use_file=allow_use_file, **kwds) >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/gp.pyc >>> in _eval_line(self, line, allow_use_file, wait_for_prompt, >>> restart_if_needed) >>> 439 a = Expect._eval_line(self, line, >>> 440 allow_use_file=allow_use_file, >>> --> 441 wait_for_prompt=wait_for_prompt) >>> 442 if a.find("the PARI stack overflows") != -1: >>> 443 verbose("automatically doubling the PARI stack and >>> re-executing current input line") >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/expect.pyc >>> >>> in _eval_line(self, line, allow_use_file, wait_for_prompt, >>> restart_if_needed) >>> 903 try: >>> 904 if self._expect is None: >>> --> 905 self._start() >>> 906 E = self._expect >>> 907 try: >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/gp.pyc >>> in _start(self, alt_message, block_during_init) >>> 239 >>> 240 def _start(self, alt_message=None, block_during_init=True): >>> --> 241 Expect._start(self, alt_message, block_during_init) >>> 242 # disable timer >>> 243 self._eval_line('default(timer,0);') >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/expect.pyc >>> >>> in _start(self, alt_message, block_during_init) >>> 480 env=pexpect_env, >>> 481 name=self._repr_(), >>> --> 482 quit_string=self._quit_string()) >>> 483 except (ExceptionPexpect, pexpect.EOF) as e: >>> 484 # Change pexpect errors to RuntimeError >>> >>> sage/interfaces/sagespawn.pyx in >>> sage.interfaces.sagespawn.SageSpawn.__init__ >>> (/usr/lib/sagemath//src/build/cythonized/sage/interfaces/sagespawn.c:1446)() >>> >>> sage/interfaces/sagespawn.pyx in >>> sage.interfaces.sagespawn.SageSpawn.__init__ >>> (/usr/lib/sagemath//src/build/cythonized/sage/interfaces/sagespawn.c:1398)() >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pexpect/pty_spawn.pyc >>> in __init__(self, command, args, timeout, maxread, searchwindowsize, >>> logfile, cwd, env, ignore_sighup, echo, preexec_fn, encoding, codec_errors, >>> dimensions) >>> 196 self.name = '<pexpect factory incomplete>' >>> 197 else: >>> --> 198 self._spawn(command, args, preexec_fn, dimensions) >>> 199 >>> 200 def __str__(self): >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pexpect/pty_spawn.pyc >>> in _spawn(self, command, args, preexec_fn, dimensions) >>> 296 >>> 297 self.ptyproc = self._spawnpty(self.args, env=self.env, >>> --> 298 cwd=self.cwd, **kwargs) >>> 299 >>> 300 self.pid = self.ptyproc.pid >>> >>> sage/interfaces/sagespawn.pyx in >>> sage.interfaces.sagespawn.SageSpawn._spawnpty >>> (/usr/lib/sagemath//src/build/cythonized/sage/interfaces/sagespawn.c:1631)() >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/ptyprocess/ptyprocess.pyc >>> >>> in spawn(cls, argv, cwd, env, echo, preexec_fn, dimensions) >>> 218 >>> 219 if use_native_pty_fork: >>> --> 220 pid, fd = pty.fork() >>> 221 else: >>> 222 # Use internal fork_pty, for Solaris >>> >>> /usr/lib/sagemath/local/lib/python/pty.pyc in fork() >>> 106 >>> 107 master_fd, slave_fd = openpty() >>> --> 108 pid = os.fork() >>> 109 if pid == CHILD: >>> 110 # Establish a new session. >>> >>> OSError: [Errno 12] Cannot allocate memory >>> sage: >>> >>> and I cannot load the notebook interface: >>> >>> sage: notebook() >>> >>> --------------------------------------------------------------------------- >>> EnvironmentError Traceback (most recent call >>> last) >>> <ipython-input-2-3728cb3d7c7d> in <module>() >>> ----> 1 notebook() >>> >>> sage/misc/lazy_import.pyx in sage.misc.lazy_import.LazyImport.__call__ >>> (/usr/lib/sagemath//src/build/cythonized/sage/misc/lazy_import.c:3635)() >>> >>> sage/misc/lazy_import.pyx in >>> sage.misc.lazy_import.LazyImport._get_object >>> (/usr/lib/sagemath//src/build/cythonized/sage/misc/lazy_import.c:2242)() >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sagenb/notebook/notebook_object.py >>> >>> in <module>() >>> 15 import time, os, shutil, signal, tempfile >>> 16 >>> ---> 17 import notebook as _notebook >>> 18 >>> 19 import run_notebook >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sagenb/notebook/notebook.py >>> >>> in <module>() >>> 33 >>> 34 # Sage libraries >>> ---> 35 from sagenb.misc.misc import (pad_zeros, cputime, tmp_dir, load, >>> save, >>> 36 ignore_nonexistent_files, >>> unicode_str) >>> 37 >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sagenb/misc/misc.py >>> in <module>() >>> 379 >>> 380 try: >>> --> 381 from sage.misc.cython import cython >>> 382 except ImportError: >>> 383 @stub >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/misc/cython.py >>> in <module>() >>> 28 >>> 29 # CBLAS can be one of multiple implementations >>> ---> 30 cblas_pc = pkgconfig.parse('cblas') >>> 31 cblas_libs = list(cblas_pc['libraries']) >>> 32 cblas_library_dirs = list(cblas_pc['library_dirs']) >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pkgconfig-1.1.0-py2.7.egg/pkgconfig/pkgconfig.py >>> >>> in parse(packages) >>> 185 >>> 186 for package in packages.split(): >>> --> 187 for k, v in parse_package(package).items(): >>> 188 result[k].update(v) >>> 189 >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pkgconfig-1.1.0-py2.7.egg/pkgconfig/pkgconfig.py >>> >>> in parse_package(package) >>> 158 >>> 159 # Execute the query to pkg-config and clean the result. >>> --> 160 out = _query(package, '--cflags --libs') >>> 161 out = out.replace('\\"', '') >>> 162 >>> >>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pkgconfig-1.1.0-py2.7.egg/pkgconfig/pkgconfig.py >>> >>> in _wrapper(*args, **kwargs) >>> 56 >>> Enter code here... >>> >>> >>> return func(*args, **kwargs) >>> 57 except OSError: >>> ---> 58 raise EnvironmentError("pkg-config is not installed") >>> 59 >>> 60 return _wrapper >>> >>> EnvironmentError: pkg-config is not installed >>> sage: >>> >>> while I do have pkg-config installed. >>> >>> On Wednesday, May 18, 2016 at 5:07:02 PM UTC+3, William wrote: >>>> >>>> >>>> >>>> On Wednesday, May 18, 2016, Brian Beavers <drbeav...@gmail.com> wrote: >>>> >>>>> Looks like there's more going on than just a lack of pty. Here's the >>>>> result: >>>>> >>>>> >>>> Well that is just another test of pty... >>>> >>>> >>>> >>>>> sage: gp.eval('2+2') >>>>> >>>>> --------------------------------------------------------------------------- >>>>> OSError Traceback (most recent call >>>>> last) >>>>> <ipython-input-1-e5d4083fb83e> in <module>() >>>>> ----> 1 gp.eval('2+2') >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/expect.pyc >>>>> >>>>> in eval(self, code, strip, synchronize, locals, allow_use_file, >>>>> split_lines, **kwds) >>>>> 1237 elif split_lines: >>>>> 1238 return '\n'.join([self._eval_line(L, >>>>> allow_use_file=allow_use_file, **kwds) >>>>> -> 1239 for L in >>>>> code.split('\n') if L != '']) >>>>> 1240 else: >>>>> 1241 return self._eval_line(code, >>>>> allow_use_file=allow_use_file, **kwds) >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/gp.pyc >>>>> >>>>> in _eval_line(self, line, allow_use_file, wait_for_prompt, >>>>> restart_if_needed) >>>>> 437 a = Expect._eval_line(self, line, >>>>> 438 allow_use_file=allow_use_file, >>>>> --> 439 wait_for_prompt=wait_for_prompt) >>>>> 440 if a.find("the PARI stack overflows") != -1: >>>>> 441 verbose("automatically doubling the PARI stack and >>>>> re-executing current input line") >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/expect.pyc >>>>> >>>>> in _eval_line(self, line, allow_use_file, wait_for_prompt, >>>>> restart_if_needed) >>>>> 848 try: >>>>> 849 if self._expect is None: >>>>> --> 850 self._start() >>>>> 851 E = self._expect >>>>> 852 try: >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/gp.pyc >>>>> >>>>> in _start(self, alt_message, block_during_init) >>>>> 237 >>>>> 238 def _start(self, alt_message=None, block_during_init=True): >>>>> --> 239 Expect._start(self, alt_message, block_during_init) >>>>> 240 # disable timer >>>>> 241 self._eval_line('default(timer,0);') >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/sage/interfaces/expect.pyc >>>>> >>>>> in _start(self, alt_message, block_during_init) >>>>> 423 env=pexpect_env, >>>>> 424 name=self._repr_(), >>>>> --> 425 quit_string=self._quit_string()) >>>>> 426 except (ExceptionPexpect, pexpect.EOF) as e: >>>>> 427 # Change pexpect errors to RuntimeError >>>>> >>>>> sage/interfaces/sagespawn.pyx in >>>>> sage.interfaces.sagespawn.SageSpawn.__init__ >>>>> (/usr/lib/sagemath//src/build/cythonized/sage/interfaces/sagespawn.c:1331)() >>>>> >>>>> sage/interfaces/sagespawn.pyx in >>>>> sage.interfaces.sagespawn.SageSpawn.__init__ >>>>> (/usr/lib/sagemath//src/build/cythonized/sage/interfaces/sagespawn.c:1284)() >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pexpect/pty_spawn.pyc >>>>> in __init__(self, command, args, timeout, maxread, searchwindowsize, >>>>> logfile, cwd, env, ignore_sighup, echo, preexec_fn, encoding, >>>>> codec_errors, >>>>> dimensions) >>>>> 191 self.name = '<pexpect factory incomplete>' >>>>> 192 else: >>>>> --> 193 self._spawn(command, args, preexec_fn, dimensions) >>>>> 194 >>>>> 195 def __str__(self): >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/pexpect/pty_spawn.pyc >>>>> in _spawn(self, command, args, preexec_fn, dimensions) >>>>> 286 >>>>> 287 self.ptyproc = self._spawnpty(self.args, env=self.env, >>>>> --> 288 cwd=self.cwd, **kwargs) >>>>> 289 >>>>> 290 self.pid = self.ptyproc.pid >>>>> >>>>> sage/interfaces/sagespawn.pyx in >>>>> sage.interfaces.sagespawn.SageSpawn._spawnpty >>>>> (/usr/lib/sagemath//src/build/cythonized/sage/interfaces/sagespawn.c:1520)() >>>>> >>>>> /usr/lib/sagemath/local/lib/python2.7/site-packages/ptyprocess/ptyprocess.pyc >>>>> >>>>> in spawn(cls, argv, cwd, env, echo, preexec_fn, dimensions) >>>>> 218 >>>>> 219 if use_native_pty_fork: >>>>> --> 220 pid, fd = pty.fork() >>>>> 221 else: >>>>> 222 # Use internal fork_pty, for Solaris >>>>> >>>>> /usr/lib/sagemath/local/lib/python/pty.pyc in fork() >>>>> 105 return pid, fd >>>>> 106 >>>>> --> 107 master_fd, slave_fd = openpty() >>>>> 108 pid = os.fork() >>>>> 109 if pid == CHILD: >>>>> >>>>> /usr/lib/sagemath/local/lib/python/pty.pyc in openpty() >>>>> 27 except (AttributeError, OSError): >>>>> 28 pass >>>>> ---> 29 master_fd, slave_name = _open_terminal() >>>>> 30 slave_fd = slave_open(slave_name) >>>>> 31 return master_fd, slave_fd >>>>> >>>>> /usr/lib/sagemath/local/lib/python/pty.pyc in _open_terminal() >>>>> 68 continue >>>>> 69 return (fd, '/dev/tty' + x + y) >>>>> ---> 70 raise os.error, 'out of pty devices' >>>>> 71 >>>>> 72 def slave_open(tty_name): >>>>> >>>>> OSError: out of pty devices >>>>> >>>>> >>>>> Brian Beavers, Ph.D., Associate Professor >>>>> Department of Mathematics & Statistics >>>>> Stephen F. Austin State University >>>>> >>>>> On Wed, May 18, 2016 at 8:50 AM, William Stein <wst...@gmail.com> >>>>> wrote: >>>>> >>>>>> >>>>>> >>>>>> On Wednesday, May 18, 2016, Brian Beavers <drbeavers...@gmail.com> >>>>>> wrote: >>>>>> >>>>>>> I've discovered why the notebook server (and administrative pages >>>>>>> within) loads but notebooks do not load: WSL does not yet suppot pty. >>>>>>> When >>>>>>> I try to create a worksheet, back in the terminal Sage throws an error >>>>>>> that >>>>>>> it is out of pty instances. >>>>>>> >>>>>>> >>>>>> What happens if you do >>>>>> >>>>>> gp.eval('2+2') >>>>>> >>>>>> in the terminal? >>>>>> >>>>>> Also, unlike sagenb, jupyter doesn't use pty's so it won't have this >>>>>> obstruction. >>>>>> >>>>>> >>>>>>> >>>>>>> >>>>>>> Brian Beavers, Ph.D., Associate Professor >>>>>>> Department of Mathematics & Statistics >>>>>>> Stephen F. Austin State University >>>>>>> >>>>>>> On Mon, May 16, 2016 at 2:31 AM, Dima Pasechnik <dimp...@gmail.com> >>>>>>> wrote: >>>>>>> >>>>>>>> one can do graphics in a browser running on the host, so this is >>>>>>>> not really a big limitation. >>>>>>>> >>>>>>>> -- >>>>>>>> You received this message because you are subscribed to the Google >>>>>>>> Groups "sage-devel" group. >>>>>>>> To unsubscribe from this group and stop receiving emails from it, >>>>>>>> send an email to sage-devel+unsubscr...@googlegroups.com. >>>>>>>> To post to this group, send email to sage-devel@googlegroups.com. >>>>>>>> Visit this group at https://groups.google.com/group/sage-devel. >>>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>>> >>>>>>> >>>>>>> -- >>>>>>> You received this message because you are subscribed to the Google >>>>>>> Groups "sage-devel" group. >>>>>>> To unsubscribe from this group and stop receiving emails from it, >>>>>>> send an email to sage-devel+unsubscr...@googlegroups.com. >>>>>>> To post to this group, send email to sage-devel@googlegroups.com. >>>>>>> Visit this group at https://groups.google.com/group/sage-devel. >>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> Sent from my massive iPhone 6 plus. >>>>>> >>>>>> -- >>>>>> You received this message because you are subscribed to the Google >>>>>> Groups "sage-devel" group. >>>>>> To unsubscribe from this group and stop receiving emails from it, >>>>>> send an email to sage-devel+unsubscr...@googlegroups.com. >>>>>> To post to this group, send email to sage-devel@googlegroups.com. >>>>>> Visit this group at https://groups.google.com/group/sage-devel. >>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>> >>>>> >>>>> >>>> >>>> >>>> >>>> >>>>> -- >>>>> You received this message because you are subscribed to the Google >>>>> Groups "sage-devel" group. >>>>> To unsubscribe from this group and stop receiving emails from it, send >>>>> an email to sage-devel+unsubscr...@googlegroups.com. >>>>> To post to this group, send email to sage-devel@googlegroups.com. >>>>> Visit this group at https://groups.google.com/group/sage-devel. >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> >>>> -- >>>> Sent from my massive iPhone 6 plus. >>>> >>> -- You received this message because you are subscribed to the Google Groups "sage-devel" group. To unsubscribe from this group and stop receiving emails from it, send an email to sage-devel+unsubscr...@googlegroups.com. To post to this group, send email to sage-devel@googlegroups.com. Visit this group at https://groups.google.com/group/sage-devel. For more options, visit https://groups.google.com/d/optout.