{ } Raw JSON

bundles / jupyter_client 8.10.0 / jupyter_client / provisioning / provisioner_base / KernelProvisionerBase / resolve_path

function

jupyter_client.provisioning.provisioner_base:KernelProvisionerBase.resolve_path

source: /jupyter_client/provisioning/provisioner_base.py:221

Signature

def resolve_path(self, path: str) → str | None

Summary

Returns the path resolved relative to kernel working directory.

Extended Summary

For example, path my_code.py for a kernel started in /tmp/ should result in /tmp/my_code.py, while path ~/test.py for a kernel started in /home/my_user/ should resolve to the (fully specified) /home/my_user/test.py path.

The provisioner may choose not to resolve any paths, or restrict the resolution to paths local to the kernel working directory to prevent path traversal and exposure of file system layout.

Aliases

  • jupyter_client.KernelProvisionerBase.resolve_path