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

Remove deprecated MacOSXOSAScript._name attribute #105545

Closed
sobolevn opened this issue Jun 9, 2023 · 0 comments
Closed

Remove deprecated MacOSXOSAScript._name attribute #105545

sobolevn opened this issue Jun 9, 2023 · 0 comments
Assignees
Labels
3.13 bugs and security fixes type-feature A feature request or enhancement

Comments

@sobolevn
Copy link
Member

sobolevn commented Jun 9, 2023

Feature or enhancement

It was deprecated in 3.11: https://github.com/python/cpython/blob/3.11/Lib/webbrowser.py#L676-L688
It is time to remove it.

My PR from 2 years ago: #30241
CC @corona10 as the original PR reviewer.

Pitch

  1. It is not used directly in a general use-case
  2. It was a mistake in the first place, all other browsers do have .name and not ._name, which was fixed in 3.11
  3. Top 5000 packages on PyPI do not use it (we only have results from mypy / typeshed):
» python cpython/search_pypi_top.py -q . "MacOSXOSAScript"              
./jedi-0.18.2.tar.gz: jedi-0.18.2/jedi/third_party/typeshed/stdlib/2and3/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./hexbytes-0.3.0.tar.gz: hexbytes-0.3.0/.tox/lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/@python2/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./hexbytes-0.3.0.tar.gz: hexbytes-0.3.0/.tox/lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):  # In runtime this class does not have `name` and `basename`
./hexbytes-0.3.0.tar.gz: hexbytes-0.3.0/.tox/py39-lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/@python2/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./hexbytes-0.3.0.tar.gz: hexbytes-0.3.0/.tox/py39-lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):  # In runtime this class does not have `name` and `basename`
./eth_abi-4.0.0.tar.gz: eth_abi-4.0.0/.tox/lint/lib/python3.10/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./typeshed_client-2.3.0.tar.gz: typeshed_client-2.3.0/typeshed_client/typeshed/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):  # In runtime this class does not have `name` and `basename`
./eth-hash-0.5.1.tar.gz: eth-hash-0.5.1/.tox/lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/@python2/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./eth-hash-0.5.1.tar.gz: eth-hash-0.5.1/.tox/lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):  # In runtime this class does not have `name` and `basename`
./eth-utils-2.1.0.tar.gz: eth-utils-2.1.0/.tox/lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./mypy-1.3.0.tar.gz: mypy-1.3.0/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):  # In runtime this class does not have `name` and `basename`
./eth-rlp-0.3.0.tar.gz: eth-rlp-0.3.0/.tox/lint/lib/python3.9/site-packages/mypy/typeshed/stdlib/2and3/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./eth-rlp-0.3.0.tar.gz: eth-rlp-0.3.0/venv-erlp/lib/python3.9/site-packages/jedi/third_party/typeshed/stdlib/2and3/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./eth-rlp-0.3.0.tar.gz: eth-rlp-0.3.0/venv-erlp/lib/python3.9/site-packages/mypy/typeshed/stdlib/2and3/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./eth-account-0.8.0.tar.gz: eth-account-0.8.0/.tox/lint/lib/python3.10/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./eth-account-0.8.0.tar.gz: eth-account-0.8.0/.tox/py310-lint/lib/python3.10/site-packages/mypy/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):
./pytype-2023.6.2.tar.gz: pytype-2023.6.2/pytype/typeshed/stdlib/webbrowser.pyi: class MacOSXOSAScript(BaseBrowser):  # In runtime this class does not have `name` and `basename`

I will send a PR.

Linked PRs

@sobolevn sobolevn added type-feature A feature request or enhancement 3.13 bugs and security fixes labels Jun 9, 2023
@sobolevn sobolevn self-assigned this Jun 9, 2023
sobolevn added a commit to sobolevn/cpython that referenced this issue Jun 9, 2023
@sobolevn sobolevn closed this as completed Jun 9, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.13 bugs and security fixes type-feature A feature request or enhancement
Projects
None yet
Development

No branches or pull requests

1 participant