-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
28 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,25 @@ | ||
from __future__ import annotations | ||
|
||
import typing as t | ||
|
||
from .serving import run_simple as run_simple | ||
from .test import Client as Client | ||
from .wrappers import Request as Request | ||
from .wrappers import Response as Response | ||
|
||
__version__ = "3.0.0.dev" | ||
|
||
def __getattr__(name: str) -> t.Any: | ||
if name == "__version__": | ||
import importlib.metadata | ||
import warnings | ||
|
||
warnings.warn( | ||
"The '__version__' attribute is deprecated and will be removed in" | ||
" Werkzeug 3.1. Use feature detection or" | ||
" 'importlib.metadata.version(\"werkzeug\")' instead.", | ||
DeprecationWarning, | ||
stacklevel=2, | ||
) | ||
return importlib.metadata.version("werkzeug") | ||
|
||
raise AttributeError(name) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters