{ } Raw JSON

bundles / jupyter_client 8.10.0 / jupyter_client / adapter / adapt

function

jupyter_client.adapter:adapt

source: /jupyter_client/adapter.py:394

Signature

def adapt(msg: dict[str, Any], to_version: int = 5) → dict[str, Any]

Summary

Adapt a single message to a target version

Parameters

msg : dict

A Jupyter message.

to_version : int, optional

The target major version. If unspecified, adapt to the current version.

Returns

msg : dict

A Jupyter message appropriate in the new version.

Aliases

  • jupyter_client.adapter.adapt