Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

async_to_sync should find and replace sections anywhere in the docstring #2664

Open
weaverba137 opened this issue Feb 10, 2023 · 0 comments
Open

Comments

@weaverba137
Copy link
Member

While working on #2663, I discovered that async_to_sync and related decorators appear to assume that the Returns section is the last section in the docstring. However, if there are more sections than just Parameters and Returns, and one is following the numpydoc standard, then there is a good chance that Returns is not the last section.

#2598 suggests eliminating separate sync and async functions entirely, and that would certainly solve this issue too.

However if #2598 is not adopted, or if adoption takes a long time, then async_to_sync should be made more robust and be able to find the Returns section anywhere in the docstring.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants