opensearch-project / opensearch-py

Python Client for OpenSearch
https://opensearch.org/docs/latest/clients/python/
Apache License 2.0
350 stars 175 forks source link

[BUG] Wrong return type hint in async_scan #512

Closed dmenini closed 1 year ago

dmenini commented 1 year ago

What is the bug?

The interface for async_scan (https://github.com/opensearch-project/opensearch-py/blob/2feccc22bb8300e9e0d9a4575e2717f2baec17ec/opensearchpy/_async/helpers/actions.pyi#L103C6-L103C31) suggests that the return type is AsyncGenerator[int, None], while it should be AsyncGenerator[dict, None] since every yielded hit is a dictionary.

saimedhi commented 1 year ago

@dmenini, Please feel free to contribute! Thanks :)