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

Add programmatic and docstring deprecations #734

Merged
merged 7 commits into from May 2, 2023
Merged

Add programmatic and docstring deprecations #734

merged 7 commits into from May 2, 2023

Conversation

maximlt
Copy link
Member

@maximlt maximlt commented Apr 12, 2023

Our plan for Param 2.0 was to improve its API by renaming and removing some methods/functions. This has already been partially achieved, however some API we deprecated was just deprecated by adding a comment in the release notes (of Param 1.12.0 mostly) and in the code, sometimes in docstrings.

We deem that this was not enough to completely remove that API in Param 2.0, as users tend to rely on programmatic warnings. For instance, in some of the HoloViz libraries there were still usages of the deprecated .param.params().

This PR:

  • adds programmatic warnings using the warnings module of Python to the deprecated methods/functions/attributes
  • adds the deprecated Sphinx directive to the relevant docstrings
  • updates the test suite to no longer use the deprecated API

Fixes #692
Fixes #702

@maximlt maximlt requested a review from jlstevens April 12, 2023 15:51
@maximlt
Copy link
Member Author

maximlt commented May 2, 2023

I'm going to merge this PR that is just adding programmatic deprecation warnings to some API that's already been docs-deprecated for a while.

@maximlt maximlt merged commit fcdda31 into main May 2, 2023
10 checks passed
@maximlt maximlt deleted the deprecate branch May 2, 2023 21:18
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.

List.class_ is deprecated Deprecating methods to be removed for 2.0?
1 participant