-
-
Notifications
You must be signed in to change notification settings - Fork 32k
gh-109234: Enhanced sqlite3 connection context management documentation with contextlib.closing
#109322
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
gh-109234: Enhanced sqlite3 connection context management documentation with contextlib.closing
#109322
Conversation
Most changes to Python require a NEWS entry. Please add it using the blurb_it web app or the blurb command-line tool. |
…er/cpython into fix-issue-109234
Hey am inquiring how can I run the doctests, could someone guide me on this , thanks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR. I left some comments regarding how to improve the docs on this topic.
Also, please remove all non-relevant changes (style changes, whitespace changes, etc); this goes for all kinds of CPython PRs (code, docs, infra, etc.)
Misc/NEWS.d/next/Library/2023-09-13-08-14-28.gh-issue-109234._vZIUm.rst
Outdated
Show resolved
Hide resolved
…er/cpython into fix-issue-109234
…ement using contextlib.closing
As far as I see you have addressed comments from @erlend-aasland , thanks for the PR. |
Congrats on your first CPython contribution @Lincoln-developer and thanks for working on this PR diligently. |
Please clean up the commit message next time – github’s interface for some misguided reason concatenates all the individual commit messages and hides that, so manual care is needed. (Also the common commit message style is followed, such as imperative |
oops forgot this, good call. |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
…textlib.closing pythongh-109234 (pythonGH-109322) * Enhanced sqlite3 connection context management documentation with contextlib.closing * 📜🤖 Added by blurb_it. * Fixed gitignore spelling error from nitignore to gitignore * Renamed .gitignore to .nitignore * Added generated doctests * Deleted sqlite3 generated files * Removed white-space changes * Removed News entry from the doc * Expanded a note that context manager can be used for connection management using contextlib.closing * Removed repeated contextlib.closing code snippet * Expanded the note around usage of context manageer for sqlite3 connection management * Deleted extra white-spaces * Deleted extra white-space * re-arranged context manager wording * Re-arranged word layout on how to use context manager * Fix whitespace errors * Remove unneeded change in .gitignore * Added suggested changes * Added suggested change redirecting to the contextlib.closing implementation * Added closing keyword * Removed line 2473 --------- (cherry picked from commit 4227bfa) Co-authored-by: Lincoln <[email protected]> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <[email protected]>
…textlib.closing pythongh-109234 (pythonGH-109322) * Enhanced sqlite3 connection context management documentation with contextlib.closing * 📜🤖 Added by blurb_it. * Fixed gitignore spelling error from nitignore to gitignore * Renamed .gitignore to .nitignore * Added generated doctests * Deleted sqlite3 generated files * Removed white-space changes * Removed News entry from the doc * Expanded a note that context manager can be used for connection management using contextlib.closing * Removed repeated contextlib.closing code snippet * Expanded the note around usage of context manageer for sqlite3 connection management * Deleted extra white-spaces * Deleted extra white-space * re-arranged context manager wording * Re-arranged word layout on how to use context manager * Fix whitespace errors * Remove unneeded change in .gitignore * Added suggested changes * Added suggested change redirecting to the contextlib.closing implementation * Added closing keyword * Removed line 2473 --------- (cherry picked from commit 4227bfa) Co-authored-by: Lincoln <[email protected]> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <[email protected]>
GH-110293 is a backport of this pull request to the 3.11 branch. |
GH-110294 is a backport of this pull request to the 3.12 branch. |
I'll take care of the backports. |
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
This comment was marked as duplicate.
…er docs (GH-109322) (#110294) (cherry picked from commit 4227bfa) Co-authored-by: Lincoln <[email protected]> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <[email protected]>
…er docs (GH-109322) (#110294) (cherry picked from commit 4227bfa) Co-authored-by: Lincoln <[email protected]> Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <[email protected]>
I'm surprised that the CI let this PR through; the PR title was not formatted correctly. I thought we had CI checks for these things. |
contextlib.closing
Thanks all , for the review and guidance upon working on this issue. l greatly appreciate ! |
…textlib.closing pythongh-109234 (python#109322) * Enhanced sqlite3 connection context management documentation with contextlib.closing * 📜🤖 Added by blurb_it. * Fixed gitignore spelling error from nitignore to gitignore * Renamed .gitignore to .nitignore * Added generated doctests * Deleted sqlite3 generated files * Removed white-space changes * Removed News entry from the doc * Expanded a note that context manager can be used for connection management using contextlib.closing * Removed repeated contextlib.closing code snippet * Expanded the note around usage of context manageer for sqlite3 connection management * Deleted extra white-spaces * Deleted extra white-space * re-arranged context manager wording * Re-arranged word layout on how to use context manager * Fix whitespace errors * Remove unneeded change in .gitignore * Added suggested changes * Added suggested change redirecting to the contextlib.closing implementation * Added closing keyword * Removed line 2473 --------- Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com> Co-authored-by: Erlend E. Aasland <[email protected]>
…textlib.closing
Enhance sqlite3 connection context management documentation with contextlib.closing #109234
This change enhances the existing sqlite3 docs on context management by adding a mention of the contextlib.closing to help guide developers when performing singular transactions.
📚 Documentation preview 📚: https://cpython-previews--109322.org.readthedocs.build/
sqlite3
connection context management documentation withcontextlib.closing
#109234