FazBrowse GitHub Viewer | Trending |
URL:
| Home
Tools: [Download Repo ZIP]   [Original HTTPS Page]

gh-77617: Add interactive shell for sqlite3 by erlend-aasland · Pull Request #95026 · python/cpython · GitHub

/ cpython Public

gh-77617: Add interactive shell for sqlite3 - #95026

Merged
erlend-aasland merged 37 commits into
python:mainfrom
erlend-aasland:sqlite-shell
Aug 1, 2022
Merged

gh-77617: Add interactive shell for sqlite3#95026
erlend-aasland merged 37 commits into
python:mainfrom
erlend-aasland:sqlite-shell

Conversation

erlend-aasland commented Jul 19, 2022
edited
Loading

Copy link
Copy Markdown
Contributor

Disclaimer: this is based off of an old proof-of-concept branch I had lying around. Take it as it is :)

Resolves gh-77617

TODO:

  • docs
  • tests?

Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
erlend-aasland marked this pull request as ready for review July 20, 2022 19:28

Copy link
Copy Markdown
Contributor Author

@rhettinger, would you mind reviewing this?

erlend-aasland marked this pull request as draft July 29, 2022 12:09

Copy link
Copy Markdown
Contributor Author

Putting this PR on hold until the --enable-loadable-sqlite-extensions mess has been fixed in main.

erlend-aasland marked this pull request as ready for review July 29, 2022 19:37
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
Erlend Egeberg Aasland and others added 4 commits July 29, 2022 23:22

Copy link
Copy Markdown
Contributor Author

The python3 -m sqlite3 :memory: "pragma compile_options" trick will be very helpful for triaging and debugging issues.

Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py Outdated
Comment thread Lib/sqlite3/__main__.py

kumaraditya303 left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

LGTM

Copy link
Copy Markdown
Contributor Author

Added tests; plus some adjustments:

  • return non-zero if SQL passed from the command line fails
  • print exceptions to stderr (not sure if this is a good idea; I have no strong opinion here)

PTAL, @serhiy-storchaka and @kumaraditya303

serhiy-storchaka left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Choose a reason Spam Abuse Off Topic Outdated Duplicate Resolved Low Quality

👍

Comment thread Lib/test/test_sqlite3/test_cli.py Outdated

Copy link
Copy Markdown
Contributor Author

Thank you for the helpful reviews, Dong-hee, Kumar, and Serhiy. Highly appreciated!

Copy link
Copy Markdown
Contributor Author

FTR, I'm going to land this later today.

erlend-aasland merged commit bc7c7cd into python:main Aug 1, 2022
erlend-aasland deleted the sqlite-shell branch August 1, 2022 10:25
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode characters
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

stdlib Standard Library Python modules in the Lib/ directory type-feature A feature request or enhancement

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add an interactive shell for Sqlite3

5 participants


Back | FazBrowse Home | New Git URL