Support for Altair.v5?

Summary

Streamlit seems to require Altair.v4 so not working with v5?

Steps to reproduce

Code snippet:

pip install altair==5.0.0rc1

streamlit run main.py        

Traceback (most recent call last):
  File "/usr/local/bin/streamlit", line 5, in <module>
    from streamlit.web.cli import main
  File "/usr/local/lib/python3.9/site-packages/streamlit/__init__.py", line 55, in <module>
    from streamlit.delta_generator import DeltaGenerator as _DeltaGenerator
  File "/usr/local/lib/python3.9/site-packages/streamlit/delta_generator.py", line 45, in <module>
    from streamlit.elements.arrow_altair import ArrowAltairMixin
  File "/usr/local/lib/python3.9/site-packages/streamlit/elements/arrow_altair.py", line 36, in <module>
    from altair.vegalite.v4.api import Chart
ModuleNotFoundError: No module named 'altair.vegalite.v4'

Expected behavior:
Any way we can use altair.v5 with Streamlit or when can we expect support for altair.v5?

Debug info

  • Streamlit, version 1.16.0
  • Python 3.10.9
1 Like

It’s only a RC, was released only 5 days ago and has no official release yet, so maybe you’re expecting a bit too much?

Thanks, no problems, a long shot so expectations are low :slight_smile: Just some new nice features in v5 I’l like to use and a manual install of v5 is too messy.

Hi, we are aware that altair v5 is not going to work with streamlit as of right now:

3 Likes

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.