New GitHub issue #118919 from sfc-gh-mvashishtha:<br>
<hr>
<pre>
# Bug report
### Bug description:
Reproducible example:
```python
from __future__ import annotations
from typing import get_type_hints
def f() -> int | str:
return 3
print(get_type_hints(f))
```
`from __future__ import annotations` lets me use the `__or__` overload for types to create union types, but `get_type_hints` can't recognize those types.
This is the root cause of https://github.com/gradio-app/gradio/pull/4228 and https://github.com/pydantic/pydantic/issues/2597
### CPython versions tested on:
3.9
### Operating systems tested on:
macOS
</pre>
<hr>
<a href="https://github.com/python/cpython/issues/118919">View on GitHub</a>
<p>Labels: type-bug</p>
<p>Assignee: </p>