Skip to content

Commit

Permalink
py-altair: Update to 5.0.1
Browse files Browse the repository at this point in the history
Version 5.0.1 (released May 26, 2023)
    Remove unwanted files during build to avoid littering site-packages folder (#3057).
    Deprecate the .ref() function for selections, instead of removing it (#3063).
    Fix bug in reconstructing layered charts with Chart.from_json()/Chart.from_dict() (#3068).

Version 5.0.0 (released May 9, 2023)
    Update Vega-Lite from version 4.17.0 to version 5.8.0; see Vega-Lite Release Notes.
Enhancements
    As described in the release notes for Vega-Lite 5.0.0, the primary change in this release of Altair is the introduction of parameters. There are two types of parameters, selection parameters and variable parameters. Variable parameters are new to Altair, and while selections are not new, much of the old terminology has been deprecated. See Slider Cutoff for an application of variable parameters (#2528).
    Grouped bar charts and jitter are now supported using offset channels, see Grouped Bar Chart with xOffset and Strip Plot with Jitter
    vl-convert is now used as the default backend for saving Altair charts as svg and png files, which simplifies saving chart as it does not require external dependencies like altair_saver does (#2701). Currently, altair_saver does not support Altair 5 and it is recommended to switch to vl-convert. See PNG, SVG, and PDF format for more details.
    Saving charts with HTML inline is now supported without having altair_saver installed (#2807).
    The default chart width was changed from 400 to 300 (#2785).
    Ordered pandas categorical data are now automatically encoded as sorted ordinal data (#2522)
    The Title and Impute aliases were added for TitleParams and ImputeParams, respectively (#2732).
    The documentation page has been revamped, both in terms of appearance and content.
    More informative autocompletion by removing deprecated methods (#2814) and for editors that rely on type hints (e.g. VS Code) we added support for completion in method chains (#2846) and extended keyword completion to cover additional methods (#2920).
    Substantially improved error handling. Both in terms of finding the more relevant error (#2842), and in terms of improving the formatting and clarity of the error messages (#2824, #2568, #2979, #3009).
    Include experimental support for the DataFrame Interchange Protocol (through __dataframe__ attribute). This requires pyarrow>=11.0.0 (#2888).
    Support data type inference for columns with special characters (#2905).
    Responsive width support using width="container" when saving charts to html or displaying them with the default html renderer (#2867).
Grammar Changes
    Channel options can now be set via a more convenient method-based syntax in addition to the previous attribute-based syntax. For example, instead of alt.X(..., bin=alt.Bin(...)) it is now recommend to use alt.X(...).bin(...)`) (#2795). See Method-Based Syntax for details.
    selection_single and selection_multi are now deprecated; use selection_point instead. Similarly, type=point should be used instead of type=single and type=multi.
    add_selection is deprecated; use add_params instead.
    The selection keyword argument must in many cases be replaced by param (e.g., when specifying a filter transform).
    The empty keyword argument for a selection parameter should be specified as True or False instead of all or none, respectively.
    The init keyword argument for a parameter is deprecated; use value instead.
Bug Fixes
    Displaying a chart not longer changes the shorthand syntax of the stored spec (#2813).
    Fixed disable_debug_mode (#2851).
    Fixed issue where the webdriver was not working with Firefox’s geckodriver (#2466).
    Dynamically determine the jsonschema validator to avoid issues with recent jsonschema versions (#2812).
Backward-Incompatible Changes
    Colons in column names must now be escaped to remove any ambiguity with encoding types. You now need to write "column\:name" instead of "column:name" (#2824).
    Removed the Vega (v5) wrappers and deprecate rendering in Vega mode (save Chart as Vega format is still allowed) (#2829).
    Removed the Vega-Lite 3 and 4 wrappers (#2847).
    Removed the deprecated datasets.py (#3010).
    In regards to the grammar changes listed above, the old terminology will still work in many basic cases. On the other hand, if that old terminology gets used at a lower level, then it most likely will not work. For example, in the current version of Scatter Plot with Minimap, two instances of the key param are used in dictionaries to specify axis domains. Those used to be selection, but that usage is not compatible with the current Vega-Lite schema.
    Removed the altair.sphinxext module (#2792). The altair-plot Sphinx directive is now part of the sphinxext-altair package.
  • Loading branch information
Matthew Danielson committed Jun 3, 2023
1 parent 33daeff commit 84dda93
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 464 deletions.
10 changes: 4 additions & 6 deletions py-altair/Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# $NetBSD$

DISTNAME= altair-4.2.2
DISTNAME= altair-5.0.1
PKGNAME= ${PYPKGPREFIX}-${DISTNAME}
CATEGORIES= graphics python
MASTER_SITES= ${MASTER_SITE_PYPI:=a/altair/}
Expand All @@ -14,18 +14,16 @@ BUILD_DEPENDS+= ${PYPKGPREFIX}-black>=20.8:../../textproc/py-black
BUILD_DEPENDS+= ${PYPKGPREFIX}-docutils>=0.16:../../textproc/py-docutils
BUILD_DEPENDS+= ${PYPKGPREFIX}-ipython>=0:../../devel/py-ipython
BUILD_DEPENDS+= ${PYPKGPREFIX}-flake8>=3.3.0:../../devel/py-flake8
BUILD_DEPENDS+= ${PYPKGPREFIX}-test>=4.3.1:../../devel/py-test
BUILD_DEPENDS+= ${PYPKGPREFIX}-typing-extensions>=4.0.1:../../devel/py-typing-extensions
BUILD_DEPENDS+= ${PYPKGPREFIX}-sphinx>=2.4.4:../../textproc/py-sphinx
BUILD_DEPENDS+= ${PYPKGPREFIX}-m2r>=0.2.1:../../textproc/py-m2r
BUILD_DEPENDS+= ${PYPKGPREFIX}-wheel>=0:../../devel/py-wheel
#BUILD_DEPENDS+= ${PYPKGPREFIX}-vega_datasets>=0:../../wip/py-vega_datasets
BUILD_DEPENDS+= ${PYPKGPREFIX}-recommonmark>=0.6.0:../../wip/py-recommonmark
DEPENDS+= ${PYPKGPREFIX}-entrypoints>=0.3:../../devel/py-entrypoints
DEPENDS+= ${PYPKGPREFIX}-jinja2>=2.11.2:../../textproc/py-jinja2
DEPENDS+= ${PYPKGPREFIX}-jsonschema>=3.2.0:../../textproc/py-jsonschema
#DEPENDS+= ${PYPKGPREFIX}-pandas>=0.18:../../math/py-pandas
DEPENDS+= ${PYPKGPREFIX}-pandas>=0.18:../../math/py-pandas
DEPENDS+= ${PYPKGPREFIX}-toolz>=0.10.0:../../devel/py-toolz

TEST_DEPENDS+= ${PYPKGPREFIX}-test>=4.3.1:../../devel/py-test
TEST_DEPENDS+= ${PYPKGPREFIX}-vega_datasets>=0.9.0:../../wip/py-vega_datasets

USE_LANGUAGES= # none
Expand Down
Loading

0 comments on commit 84dda93

Please sign in to comment.