-
Notifications
You must be signed in to change notification settings - Fork 794
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
refactoring: remove vega and vegalite wrappers #2817
Comments
Thanks for the comment @binste, given this alternative it is fine by me to refactor the Vega v5 wrappers out of Altair. Regarding the Vega-Lite wrappers, another option would be to prepare a 4.3 version of Altair with some of the new features excluding the changes required for vega-lite v5 and from there refactor Altair v5 with just a single Vega-Lite v5 wrapper? |
I am +1 on removing the Vega 5 code and it seems like Jake also had this in mind based on the comment that @binste linked. Regarding a 4.3 version, I think there are some nice things with this, but it would involve a lot of rearranging or cherrypicking of commits to create the 4.3 release. I would rather spend that time on working toward a 5.0 release, and recommend people to update. Based on the discussion in #2785 I remain in favor of only supporting Vega-Lite 5 in Altair 5. I agree with the idea that pinning of the Vega-Lite version is best done via pinning the Altair version, rather than using the newest version of Altair with specific Vega-Lite versions. It does also seem that this could add significant maintenance cost in terms of figuring out which new Altair features are safe to backport to the older Vega-Lite version and which should only be applied to the latest Vega-Lite version. Given that the upgrade from Altair 4 for 5 has been quite the undertaking, I'm can't help to lean towards the solution that is easier to maintain and upgrade in the future. |
Fine. At least its good documented why we are doing this. Then we agree to refactor vega v5, vega-lite v3 and vega-lite v4 out of Altair. |
@jakevdp Just a ping here in case you are able to share your thoughts on this issue since it is a bigger decision. But I understand if you are not able to and then we can go ahead with the current plan for the time being. |
Is Vega-Lite 5.2 what we're aiming for in the next release? On the Altair side, I don't think there will be any issue using a later version of Vega-Lite. I'm asking here just as a possible reminder that this decision exists! |
Altair itself will be fine, but you won’t be able to pass the tests as defined in GitHub Action, since |
I had a brief look on the release notes for 5.3, 5.4, 5.5, and 5.6 and I don't see anything super important, so I am ok sticking with 5.2 and ironing out minor things in the meanwhile. But maybe open an issue to track it @ChristopherDavisUCI, in case it is something relatively straightforward we can do later, just before the release (candidate). |
Thanks! @joelostblom I opened a brief issue here: #2833 |
Continuation of the discussion that started from this comment and onwards.
Vega 5 specifications can currently be rendered using Altair, with support of interactivity:
Now, one can also use
vl-convert
(pip/conda install vl-convert-python
) to render these as png or svg in a notebook:But as far as I can tell it does not support the interactivity (btw just like a svg-export from the Vega Editor with above example).
Introducing errors in the spec, propagate JavaScript warnings back to the notebook, in both cases:
Changing eg:
"from": {"data": "table"},
to"from": {"data": "FOO"},
Results with Altair variant:
And with vl-convert variant:
Since it is not the core of Altair, we can decide for maintenance purposes to remove the Vega (currently v5) wrappers and leave this to vl-convert if people like to make use of this within a notebook environment.
Altair had until this commit support in the main version on Github support for the following Vega-Lite versions:
Three versions of Vega-Lite seems too many, and we are still discussing if we can reduce it to only a single version of Vega-Lite. But the
v3
version is obsolete anyway. These packages/tests can safely be removed from main.The text was updated successfully, but these errors were encountered: