Repository: mit-ll-responsible-ai/hydra-zen

Issue:
Bump pyright from 1.1.345 to 1.1.347 in /deps
Bumps [pyright](https://github.com/RobertCraigie/pyright-python) from 1.1.345 to 1.1.347.
<details>
<summary>Commits</summary>
<ul>
<li><a href="https://github.com/RobertCraigie/pyright-python/commit/daefe65bfba4d53d87272649e2335ead7de3e0d9"><code>daefe65</code></a> Pyright NPM Package update to 1.1.347 (<a href="https://redirect.github.com/RobertCraigie/pyright-python/issues/246">#246</a>)</li>
<li><a href="https://github.com/RobertCraigie/pyright-python/commit/b16743c84df91edb8acd6bd3b18c22b1dcb5ffb0"><code>b16743c</code></a> [pyright updated to 1.1.346] Update Version (<a href="https://redirect.github.com/RobertCraigie/pyright-python/issues/245">#245</a>)</li>
<li>See full diff in <a href="https://github.com/RobertCraigie/pyright-python/compare/v1.1.345...v1.1.347">compare view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=pyright&package-manager=pip&previous-version=1.1.345&new-version=1.1.347)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)


</details>


Discussion:

Resolving patch:
diff --git a/src/hydra_zen/structured_configs/_implementations.py b/src/hydra_zen/structured_configs/_implementations.py
--- a/src/hydra_zen/structured_configs/_implementations.py
+++ b/src/hydra_zen/structured_configs/_implementations.py
@@ -853,7 +853,7 @@ def _sanitized_type(
                 if optional_type is Any:  # Union[Any, T] is just Any
                     return Any
 
-                return Union[optional_type, NoneType]
+                return cast(type, Union[optional_type, NoneType])
 
             if origin is list or origin is List:
                 if args:
@@ -2276,7 +2276,8 @@ def builds(self,target, populate_full_signature=False, **kw):
                     " You can manually create a dataclass to utilize this name in a structured config."
                 )
 
-        target_field: List[Union[Tuple[str, Type[Any]], Tuple[str, Type[Any], Any]]]
+        # list[tuple[str, type] | tuple[str, type, Any]]
+        target_field: List[Union[Tuple[str, Any], Tuple[str, Any, Any]]]
 
         # zen_partial behavior:
         #
@@ -2406,7 +2407,7 @@ def builds(self,target, populate_full_signature=False, **kw):
                             ZEN_WRAPPERS_FIELD_NAME,
                             Union[
                                 Union[str, Builds[Any]],
-                                Tuple[Union[str, Builds[Any]], ...],
+                                Tuple[Union[str, Builds[Any]], Any],
                             ],
                             _utils.field(default=validated_wrappers[0], init=False),
                         ),
@@ -2417,7 +2418,7 @@ def builds(self,target, populate_full_signature=False, **kw):
                             ZEN_WRAPPERS_FIELD_NAME,
                             Union[
                                 Union[str, Builds[Any]],
-                                Tuple[Union[str, Builds[Any]], ...],
+                                Tuple[Union[str, Builds[Any]], Any],
                             ],
                             _utils.field(default=validated_wrappers, init=False),
                         ),
@@ -3542,7 +3543,7 @@ def get_target(obj: Union[HasTarget, HasTargetInst]) -> Any:
     ... class A:
     ...     _target_: str = "builtins.dict"
 
-    >>> get_target(A)
+    >>> get_target(A())
     <class 'dict'>
 
     and for configs loaded from yamls.
diff --git a/src/hydra_zen/structured_configs/_type_guards.py b/src/hydra_zen/structured_configs/_type_guards.py
--- a/src/hydra_zen/structured_configs/_type_guards.py
+++ b/src/hydra_zen/structured_configs/_type_guards.py
@@ -10,7 +10,7 @@
 from hydra_zen.funcs import get_obj, zen_processing
 from hydra_zen.structured_configs._utils import safe_name
 from hydra_zen.typing import Builds, Just, PartialBuilds
-from hydra_zen.typing._implementations import DataClass_, HasTarget
+from hydra_zen.typing._implementations import DataClass_, HasTarget, HasTargetInst
 
 from ._globals import (
     JUST_FIELD_NAME,
@@ -66,7 +66,7 @@ def safe_getattr(obj: Any, field: str, *default: Any) -> Any:
     return getattr(obj, field, *default)
 
 
-def _get_target(x: HasTarget) -> Any:
+def _get_target(x: Union[HasTarget, HasTargetInst]) -> Any:
     return safe_getattr(x, TARGET_FIELD_NAME)
 
 
diff --git a/src/hydra_zen/typing/_implementations.py b/src/hydra_zen/typing/_implementations.py
--- a/src/hydra_zen/typing/_implementations.py
+++ b/src/hydra_zen/typing/_implementations.py
@@ -296,7 +296,9 @@ class MyBuilds(BuildsFn[CustomConfigType[MyType]]):
 
 
 DefaultsList = List[
-    Union[str, DataClass_, Mapping[str, Union[None, str, Sequence[str]]]]
+    Union[
+        str, DataClass_, Type[DataClass_], Mapping[str, Union[None, str, Sequence[str]]]
+    ]
 ]
 
 


Test patch:
diff --git a/tests/annotations/declarations.py b/tests/annotations/declarations.py
--- a/tests/annotations/declarations.py
+++ b/tests/annotations/declarations.py
@@ -426,7 +426,6 @@ class AnEnum(Enum):
 
 def check_zen_field():
     ZenField(int)
-    ZenField(Callable[..., Any])
     ZenField(List[int])
 
     ZenField(1.0)  # type: ignore