| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request integrates native asyncio capabilities into the google-cloud-spanner library. It introduces a novel 'Cross-Sync' architecture that treats the asynchronous code as the canonical implementation, automatically generating and synchronizing the synchronous API. This fundamental shift enhances the library's performance and responsiveness for concurrent operations, ensuring a robust and well-tested asynchronous experience for users. Highlights
The full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either /gemini <command> or @gemini-code-assist <command>. Below is a summary of the supported commands on the current page.
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a .gemini/ folder in the base of the repository. Detailed instructions can be found here. Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
Sorry, something went wrong.
There was a problem hiding this comment.
This pull request introduces a significant architectural change with the new Cross-Sync mechanism for generating synchronous code from an asynchronous source. The implementation of the code generation and the new async components is well-structured. However, I've identified a critical issue in an async transport interceptor where a missing await will likely cause runtime errors. Additionally, there are opportunities for improvement by refactoring duplicated code in the AST transformers, enhancing the robustness of AST checks, and correcting some documentation typos and inaccuracies. Addressing these points will further strengthen this excellent contribution towards native asyncio support.
Sorry, something went wrong.
|
📢 Migration Notice: 📢 This library is moving to the google-cloud-python monorepo soon. We kept this PR open due to recent activity. We would like to finalize this PR so it can be merged if it is critical. If we don't hear from the PR author, we will close this PR in the next few days. The PR can then be re-opened in the monorepo once the migration is complete and work can continue there. |
Sorry, something went wrong.
Hi, |
Sorry, something went wrong.
- Port TLS/mTLS and experimental host support to AsyncClient - Port enable_interceptors_in_tests to AsyncInstance.database - Regenerate synchronous code via CrossSync - Fix noxfile.py for pytest-asyncio compatibility and test isolation - Add comprehensive asynchronous system tests
There was a problem hiding this comment.
LGTM...
Sorry, something went wrong.
| "py.test", | ||
| "--quiet", |
There was a problem hiding this comment.
Should we remove "--quite" mode...
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Description: Native Asyncio Support
This PR introduces comprehensive, native asyncio support to the google-cloud-spanner library. It transitions the library into a "Cross-Sync" architecture, where the asynchronous implementation serves as the source of truth, and the synchronous implementation is automatically kept in parity.
Key Technical Changes
Core Library Porting
Verification & Testing
9 New System Tests: Created a dedicated async system test suite (tests/system/_async/) covering:
Rich data types (Timestamp, JSON, Protobuf, etc.)
Transaction retry loops
Partitioned DML operations
Session pool lifecycle
100% Pass Rate: All new async tests and existing sync tests pass reliably against the Spanner Emulator.
Mock Server Updates: Added 40+ mock server tests to verify specific async behaviors like result-set iteration and error handling.