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 driver implementation #26

Merged
merged 8 commits into from
Feb 6, 2024
Merged

Conversation

LuckySting
Copy link
Contributor

In this PR

Add isort

isort is a Python utility / library to sort imports alphabetically, and automatically separated into sections and by type. It will help to keep imports well organized in project during the development.

Implement asynchronous driver

The support of an async drivers is needed to allow usage of this dialect in async context, which is the modern way to write applications in python. I used SQLAlchemy async-sync-async trick to implement an async driver without the copy-paste of code.

Enable multi-driver testing

The SQLAlchemy test suite supports running its test on a several combinations of dialects, which I use to run the same test on both sync and async drivers.

finally:
loop.run_until_complete(driver.stop())

loop.run_until_complete(driver.stop())
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you need call driver.stop() twice?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@rekby rekby merged commit 755e968 into ydb-platform:main Feb 6, 2024
5 checks passed
@rekby rekby self-assigned this Feb 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants