Colab #
The Colab extension
depends on python and remote. It provides account login and the kernel's
colab binding. See the kernel for execution context.
Account access #
The extension's colab.account route calls native_signed_in and returns an
access token and email to the kernel. The kernel does not need to read
creds.json, but it does receive the token.
albedo_colab_auth.erl
owns account selection and token handling.
Runtimes and connections #
The Python plugin provides
instances, status, launch, stop, and connect. connect fetches a
current runtime listing, finds an SSH public key, registers an alias, and calls
remote.connect. Its websocket proxy URL and public key reach the bridge
through environment variables. The alias disables SSH host key checking for that
connection.
A failed connection can raise ColabSshSessionError after a probe identifies an
occupied SSH session. stop sends an unassign request and removes the alias. It
is a runtime-management operation, not a connection retry. Recover needed files
before requesting it.
HTTP file access #
The same plugin provides runtime_status, contents, read, and pull
independently of SSH. Paths are relative to the Jupyter root. pull can resume
a partial download. Resume assumes the remote content has not changed. Use
resume=False for mutable content.
Plugin tests exercise the client with a
fake HTTP layer.