We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 716140a commit b1c0e45Copy full SHA for b1c0e45
src/yandex_cloud_ml_sdk/_tools/function.py
@@ -1,6 +1,6 @@
1
from __future__ import annotations
2
3
-from typing import TypeVar, cast
+from typing import Optional, TypeVar, cast
4
5
from yandex_cloud_ml_sdk._types.domain import BaseDomain
6
from yandex_cloud_ml_sdk._types.misc import UNDEFINED, UndefinedOr, get_defined_value
@@ -23,11 +23,11 @@ def __call__(
23
schema = schema_from_parameters(parameters)
24
description_ = (
25
get_defined_value(description, None) or
26
- cast(str | None, schema.get('description'))
+ cast(Optional[str], schema.get('description'))
27
)
28
name_ = (
29
get_defined_value(name, None) or
30
- cast(str | None, schema.get('title'))
+ cast(Optional[str], schema.get('title'))
31
32
33
if not name_:
0 commit comments