feat: Implementing client side statements in dbapi (starting with commit)#1037
feat: Implementing client side statements in dbapi (starting with commit)#1037ankiaga merged 8 commits intogoogleapis:mainfrom
Conversation
eec98bf to
bedb240
Compare
|
🤖 I detect that the PR title and the commit message differ and there's only one commit. To use the PR title for the commit history, you can use Github's automerge feature with squashing, or use -- conventional-commit-lint bot |
aseering
left a comment
There was a problem hiding this comment.
Thanks for putting this together! No major concerns but a bunch of little comments. Let me know what you think.
|
Thanks @aseering for taking out time and providing valuable comments. Got to learn a lot from your comments |
| RE_PYFORMAT = re.compile(r"(%s|%\([^\(\)]+\)s)+", re.DOTALL) | ||
|
|
||
|
|
||
| @deprecated(reason="This method is deprecated. Use _classify_stmt method") |
There was a problem hiding this comment.
this pulls in two new dependencies (deprecated, wrapt) into this library -- this can be replaced entirely with this inside the function body:
warnings.warn("This method is deprecated. Use classify_statement method instead", stacklevel=2)this uses warnings directly avoiding the two new dependencies (including one which has a C extension!)
There was a problem hiding this comment.
would one be open to a PR to do this instead?
There was a problem hiding this comment.
@ankiaga Would you mind taking a look what would be the best solution here?
Implementation to Commit the ongoing transaction whenever execute() method of Cursor is called with a sql query "COMMIT" (or "COMMIT TRANSACTION")
The plan is to later add more client side statements