1- from __future__ import annotations
1+ from __future__ import annotations # nocov
22
3- from collections .abc import MutableMapping
4- from typing import Any
3+ from collections .abc import MutableMapping # nocov
4+ from typing import Any # nocov
55
6- from reactpy ._warnings import warn
7- from reactpy .backend .types import Connection , Location
8- from reactpy .core .hooks import ConnectionContext , use_context
6+ from reactpy ._warnings import warn # nocov
7+ from reactpy .backend .types import Connection , Location # nocov
8+ from reactpy .core .hooks import ConnectionContext , use_context # nocov
99
1010
11- def use_connection () -> Connection [Any ]:
11+ def use_connection () -> Connection [Any ]: # nocov
1212 """Get the current :class:`~reactpy.backend.types.Connection`."""
1313 warn (
1414 "The module reactpy.backend.hooks has been deprecated and will be deleted in the future. " ,
@@ -17,13 +17,13 @@ def use_connection() -> Connection[Any]:
1717 )
1818
1919 conn = use_context (ConnectionContext )
20- if conn is None : # nocov
20+ if conn is None :
2121 msg = "No backend established a connection."
2222 raise RuntimeError (msg )
2323 return conn
2424
2525
26- def use_scope () -> MutableMapping [str , Any ]:
26+ def use_scope () -> MutableMapping [str , Any ]: # nocov
2727 """Get the current :class:`~reactpy.backend.types.Connection`'s scope."""
2828 warn (
2929 "The module reactpy.backend.hooks has been deprecated and will be deleted in the future. " ,
@@ -34,7 +34,7 @@ def use_scope() -> MutableMapping[str, Any]:
3434 return use_connection ().scope
3535
3636
37- def use_location () -> Location :
37+ def use_location () -> Location : # nocov
3838 """Get the current :class:`~reactpy.backend.types.Connection`'s location."""
3939 warn (
4040 "The module reactpy.backend.hooks has been deprecated and will be deleted in the future. " ,
0 commit comments