millejoh / emacs-ipython-notebook

Jupyter notebook client in Emacs
http://millejoh.github.io/emacs-ipython-notebook/
GNU General Public License v3.0
1.47k stars 123 forks source link

connect to a paperspace session #871

Open LazerJesus opened 1 year ago

LazerJesus commented 1 year ago

Hi, I am trying to connect to a kernel running on Paperspace.

when running this block:

#+NAME: BD7DDF92-DC52-439E-8CDF-CFD659FC7560
#+BEGIN_SRC ein-python :session https://n[]e.c[]l.paperspacegradient.com :results output
  print("lorem inc")
#+end_src

#+RESULTS: BD7DDF92-DC52-439E-8CDF-CFD659FC7560
: [....]

i get this message:

ein: [info] WS action [(websocket-received-error-http-response 403)] on-open (wss://n[]l.paperspacegradient.com:443/api/kernels/[]/channels?session_id=[])

on paperspace, i have now two notbooks Untitlted & Untitled1.

what to do?

related: i can connect to the instance with ein:login and view the notebooklist of the remote instance in emacs, but any edits i do to the notebook arent propagated. the top of the buffer says kernel requires reconncect C-c C-r which results in the same error

ein: [info] WS action [(websocket-received-error-http-response 403)] on-open (wss://[].paperspacegradient.com:443/api/kernels/[]/channels?session_id=[])
dickmao commented 1 year ago

Get out while you still can?

There are far too many layers of web security that could thwart a naive connection to a commercial server behind a firewall.

I'd reroute off the jupyter ecosystem generally. How ridiculous is a framework that willy-nilly creates cruft like Untitled1.ipynb, and foils any attempt at version control?

LazerJesus commented 1 year ago

I would love to flee the entire python ecosystem in its entirety - its a toy language created for learning - but sadly all of modern ML is built on python & jupyter. therefore i can not.

raw

dickmao commented 1 year ago

Millions of ML learners run a few notebooks and then find a job completely unrelated to ML.

Your trajectory is fine, except you're needlessly complicating the first part with emacs.

LazerJesus commented 1 year ago

lucky me then, that i don’t need to find a job.

i have everything in emacs that matters to me and i don’t want notebooks to be the exception. especially since the development flow with gpt.el is insanely productive for me. do you think this is paperspace issue or a jupyter one?

On Thu 27. Apr 2023 at 18:59 dickmao @.***> wrote:

Millions of ML learners run a few notebooks and then find a job completely unrelated to ML.

Your trajectory is fine, except you're needlessly complicating the first part with emacs.

— Reply to this email directly, view it on GitHub https://github.com/millejoh/emacs-ipython-notebook/issues/871#issuecomment-1526036405, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACVBZJXMSMCB2FBRNGGSH5TXDKQW3ANCNFSM6AAAAAAXOC4OSU . You are receiving this because you authored the thread.Message ID: @.***>

nakkaya commented 1 year ago

@dickmao @FinnFrotscher This is not exactly a Paperspace issue. I also have the same thing with vanilla jupyter instance and org-mode. I can use ein with the instance running (edit/run notebooks) but org-mode integration is broken.

What I do is, use ein when working with collaborators who are using notebooks. For personal stuff I use emacs-jupyter with org-mode.

I'd reroute off the jupyter ecosystem generally. How ridiculous is a framework that willy-nilly creates cruft like Untitled1.ipynb, and foils any attempt at version control?

I would if I could believe me but unfortunately we are at a point where it became the standard interface.

LazerJesus commented 1 year ago

I get the same error message even on ein <-> jupyter kernel (on paperspace) connections in ein:notebook-mode without org or babel.

ein: [info] WS action [(websocket-received-error-http-response 403)] on-open (wss://[].paperspacegradient.com:443/api/kernels/[]/channels?session_id=[])