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

Mark deprecated functions #2469

Merged
merged 2 commits into from
May 30, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions plugin/core/url.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
from __future__ import annotations
from typing import Any
from typing_extensions import deprecated
from urllib.parse import urljoin
from urllib.parse import urlparse
from urllib.request import pathname2url
Expand Down Expand Up @@ -31,6 +32,7 @@ def view_to_uri(view: sublime.View) -> str:
return filename_to_uri(file_name)


@deprecated("Use parse_uri() instead")
predragnikolic marked this conversation as resolved.
Show resolved Hide resolved
def uri_to_filename(uri: str) -> str:
"""
DEPRECATED: An URI associated to a view does not necessarily have a "file:" scheme.
Expand Down
2 changes: 2 additions & 0 deletions plugin/session_buffer.py
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,7 @@
from typing import Any, Callable, Iterable, List, Protocol
from typing import cast
from typing_extensions import TypeGuard
from typing_extensions import deprecated
from weakref import WeakSet
import sublime
import time
Expand Down Expand Up @@ -192,6 +193,7 @@ def get_view_in_group(self, group: int) -> sublime.View:
return next(iter(self.session_views)).view

@property
@deprecated("Use get_language_id() instead")
def language_id(self) -> str:
"""
Deprecated: use get_language_id
Expand Down