Skip to content

fix(deps): lower ipython requirement to >=7.34.0 for Colab Enterprise - #209

Merged
dborowitz merged 1 commit into
mainfrom
dborowitz-lower-ipython
Oct 22, 2026
Merged

dborowitz merged 1 commit into
mainfrom
dborowitz-lower-ipython

Conversation

@dborowitz

Copy link
Copy Markdown
Contributor

Summary

Colab and Colab Enterprise runtimes pre-install ipython==7.34.0 (the final 7.x release) to satisfy google-colab's custom kernel integration constraints. Requiring ipython>=8.0 in extras_require["interactive"] forced pip to upgrade IPython when installing google-cloud-spark-connect[interactive] on Colab Enterprise runtimes, conflicting with google-colab's pinned dependencies and risking kernel incompatibility across restarts.

Nothing in google.cloud.managed_spark_connect or google.cloud.managed_spark_magics depends on IPython 8+ features:

  • Interactive shell integration (_ipython.py, session.py, environment.py) and the %%sparksql / %load_spark_connect_session magics only use long-stable APIs already present in IPython 7.34.0 (get_ipython, IPython.display, Magics decorators, extension_manager, magics_manager, post_run_cell events, _showtraceback, and traitlets.config.Configurable).
  • All sibling [interactive] dependencies (anywidget, colabsqlviz, ipywidgets, jupyter_DynamicPip, sqlparse) already support ipython==7.34.0.

This PR lowers the floor in setup.py to ipython>=7.34.0 so installing the [interactive] extra on Colab Enterprise preserves the runtime's existing ipython==7.34.0 installation.

Verification

Recorded interactive notebook demo: 23-cell notebook executed end-to-end against a Managed Spark Serverless session in a venv starting with ipython==7.34.0:

1. Live pip install preserves ipython==7.34.0

image

2. %%sparksql interactive colabsqlviz widget rendering

image

3. DataFrame rich HTML table rendering (_repr_html_)

image

4. %dpip runtime package installation and Spark UDF execution

image

5. Concise PySpark error formatting in %%sparksql

image

6. %config GoogleSparkConnectShell runtime toggles

image

Colab and Colab Enterprise runtimes pre-install ipython==7.34.0 (the final 7.x
release) to satisfy google-colab's kernel integration constraints. Requiring
ipython>=8.0 in extras_require["interactive"] forced pip to upgrade IPython on
Colab Enterprise runtimes when installing google-cloud-spark-connect[interactive],
conflicting with google-colab's pinned dependencies and risking kernel
incompatibility across restarts.

Nothing in google.cloud.managed_spark_connect or google.cloud.managed_spark_magics
depends on IPython 8+ features:
- Interactive shell integration (_ipython.py, session.py, environment.py) and
  the %%sparksql / %load_spark_connect_session magics only use long-stable APIs
  available in IPython 7.34.0 (get_ipython, IPython.display, Magics decorators,
  extension_manager, magics_manager, post_run_cell events, _showtraceback, and
  traitlets.config.Configurable).
- All sibling [interactive] dependencies (anywidget, colabsqlviz, ipywidgets,
  jupyter_DynamicPip, sqlparse) already support IPython 7.34.0.

Lower the floor in setup.py to ipython>=7.34.0 so installing the [interactive]
extra on Colab Enterprise preserves the runtime's existing IPython 7.34.0
installation.
@dborowitz
dborowitz requested review from medb and tim-u October 20, 2026 04:03

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the setup.py file to lower the minimum required version of ipython from 8.0 to 7.34.0. There are no review comments, and I have no feedback to provide.

@dborowitz
dborowitz merged commit 2c9e2d8 into main Oct 22, 2026
12 checks passed
@dborowitz
dborowitz deleted the dborowitz-lower-ipython branch October 22, 2026 17:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants