Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include vl-convert-python as a dependency of Altair? #2816

Closed
mattijn opened this issue Jan 7, 2023 · 3 comments
Closed

Include vl-convert-python as a dependency of Altair? #2816

mattijn opened this issue Jan 7, 2023 · 3 comments

Comments

@mattijn
Copy link
Contributor

mattijn commented Jan 7, 2023

Lets open this issue. Title says it all. What are the cons and pros?

Pros:

  • easy to save charts to file, svg/png
  • other libraries also come included with saving engines

Cons:

  • 20mb
@jonmmease
Copy link
Contributor

In general, I don't think it's a good idea for a pure Python library like Altair to have a hard dependency on a native library if it can be avoided. This would break the use of Altair in contexts where vl-convert-python isn't pre-compiled. One notable example would be pyodide/pyscript. But also various arm architectures that are pre-built yet.

We could add vl-convert-python to an extra_require group and then update the docs to install using that group. For example, we could add vl-convert-python, altair-viewer, and vega-datasets to an extra_require group named full and then instruct people in the docs to install altair with

pip install "altair[full]"

@mattijn
Copy link
Contributor Author

mattijn commented Jan 7, 2023

That sounds good to me 👍.

@mattijn
Copy link
Contributor Author

mattijn commented Jan 8, 2023

Thanks @jonmmease for your comment and idea: closed in favor of #2818.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants