From 614e32bf12dc0ced60a0d309b98e2f0dd274b59a Mon Sep 17 00:00:00 2001 From: Chris Clark Date: Tue, 23 Jul 2024 13:02:06 -0400 Subject: [PATCH] 5.1.0b1 --- AUTHORS | 10 ++++++-- HISTORY.rst | 45 +++++++++++++++++++++++++++++++++- README.rst | 50 +++++++++++++++++++++++++------------- explorer/__init__.py | 8 +++--- pypi-release-checklist.md | 51 +++------------------------------------ setup.py | 12 ++++----- 6 files changed, 98 insertions(+), 78 deletions(-) diff --git a/AUTHORS b/AUTHORS index 85156ed2..2945fa0f 100644 --- a/AUTHORS +++ b/AUTHORS @@ -1,8 +1,9 @@ The following people have contributed to django-sql-explorer: +- Chris Clark +- Mark Walker - Lee Brooks - Artyom Chernyakov -- Chris Clark - Rodney Hawkins - Dane Hillard - Wojtek Jurkowlaniec @@ -21,6 +22,11 @@ The following people have contributed to django-sql-explorer: - Brad Melin - Dara Adib - Moe Elias - +- Illia Volochii +- Amir Abedi +- Christian Clauss +- Shiyan Shirani +- Calum Smith +- Steven Luoma A full list of contributors can be found on Github; https://github.com/explorerhq/django-sql-explorer/graphs/contributors diff --git a/HISTORY.rst b/HISTORY.rst index 33bdf0f8..76d79dcc 100644 --- a/HISTORY.rst +++ b/HISTORY.rst @@ -5,6 +5,41 @@ Change Log This document records all notable changes to `django-sql-explorer `_. This project adheres to `Semantic Versioning `_. +`5.1.0`_ (2024-07-TBD) +=========================== +Major improvements: + +* `#647`_: Upload json files as data sources (in addition to CSV and SQLite files). Both 'normal' + json files, and files structured as a list of json objects (one json object per line) are supported. +* `#643`_: Addresses #640 (Snowflake support). Additionally, supports an "extras" field on the + userspace DatabaseConnection object, which allows for arbitrary additional connection + params to get added. This allows engine-specific (or just more obscure) settings to + get injected into the connection. +* `#644`_: Dockerfile and docker-compose to run the test_project. Replaces the old start.sh script. + +Minor improvements: + +* `#647`_: In the schema explorer, clicking on a field name copies it to the clipboard +* `#647`_: Charts are limited to a maximum of 10 series. This significantly speeds up rendering + of 'wide' result-sets when charts are enabled. +* `#645`_: Removed pie charts, added bar charts. Replaced Seaborn with Matplotlib + because it's much lighter weight. Pie charts were overly finicky to get working. + Bars are more useful. Will look to continue to expand charting in the future. +* `#643`_: After uploading a csv/json/etc, the resulting connection is highlighted in the + connection list, making it much clearer what happened. +* `#643`_: Fixed some bugs in user connection stuff in general, and improved the UI. + +Bugfixes and internal improvements: + +* `#647`_: Robustness to the user uploads feature, in terms of the UI, error handling and logging, and test coverage. +* `#648`_: Backwards migration for 0016_alter_explorervalue_key.py +* `#649`_: Use a more reliable source of the static files URL +* `#635`_: Improved test coverage in tox, so that base requirements are properly used. + This would have prevented (for example) issue 631. Additionally, introduced a test + to verify that migrations are always generated, which would have prevented #633. +* `#636`_: Output rendering bugfix. +* `#567`_: Upgrade translate tags in templates to more modern style. + `5.0.2`_ (2024-07-3) =========================== * `#633`_: Missing migration @@ -561,7 +596,14 @@ Initial Release .. _#566: https://github.com/explorerhq/django-sql-explorer/pull/566 .. _#571: https://github.com/explorerhq/django-sql-explorer/pull/571 .. _#594: https://github.com/explorerhq/django-sql-explorer/pull/594 - +.. _#647: https://github.com/explorerhq/django-sql-explorer/pull/647 +.. _#643: https://github.com/explorerhq/django-sql-explorer/pull/643 +.. _#644: https://github.com/explorerhq/django-sql-explorer/pull/644 +.. _#645: https://github.com/explorerhq/django-sql-explorer/pull/645 +.. _#648: https://github.com/explorerhq/django-sql-explorer/pull/648 +.. _#649: https://github.com/explorerhq/django-sql-explorer/pull/649 +.. _#635: https://github.com/explorerhq/django-sql-explorer/pull/635 +.. _#636: https://github.com/explorerhq/django-sql-explorer/pull/636 .. _#269: https://github.com/explorerhq/django-sql-explorer/issues/269 .. _#288: https://github.com/explorerhq/django-sql-explorer/issues/288 @@ -587,5 +629,6 @@ Initial Release .. _#619: https://github.com/explorerhq/django-sql-explorer/issues/619 .. _#631: https://github.com/explorerhq/django-sql-explorer/issues/631 .. _#633: https://github.com/explorerhq/django-sql-explorer/issues/633 +.. _#567: https://github.com/explorerhq/django-sql-explorer/issues/567 .. _furo: https://github.com/pradyunsg/furo diff --git a/README.rst b/README.rst index 27620959..8ef8ea78 100644 --- a/README.rst +++ b/README.rst @@ -20,9 +20,9 @@ SQL Explorer * `Official Website `_ * `Live Demo `_ * `Documentation `_ -* Quick Start: Clone and then ``docker compose up`` -Video Tour: +Video Tour +---------- .. |inline-image| image:: https://sql-explorer.s3.amazonaws.com/video-thumbnail.png :target: https://sql-explorer.s3.amazonaws.com/Sql+Explorer+5.mp4 @@ -30,14 +30,30 @@ Video Tour: |inline-image| +Quick Start +----------- + +Included is a complete test project that you can use to kick the tires. + +1. Run ``docker compose up`` +2. Navigate to 127.0.0.1:8000/explorer/ +3. log in with admin/admin +4. Begin exploring! + +This will also run a Vite dev server with hot reloading for front-end changes. + +About +----- + SQL Explorer aims to make the flow of data between people fast, simple, and confusion-free. It is a Django-based application that you can add to an existing Django site, or use as a standalone business intelligence tool. It will happily connect to any SQL database that -`Django supports `_. +`Django supports `_ +as well as user-uploaded CSV, JSON, or SQLite databases. Quickly write and share SQL queries in a simple, usable SQL editor, -view the results in the browser, and keep the information flowing! +view the results in the browser, and keep the information flowing. Add an OpenAI (or other provider) API key and get an LLM-powered SQL assistant that can help write and debug queries. The assistant @@ -50,17 +66,15 @@ licensed, and pull requests are welcome. Some key features include: -- Support for multiple connections +- Support for multiple connections, admin configured or user-provided. +- Users can upload and immediately query JSON or CSV files. - AI-powered SQL assistant - Quick access to schema information to make querying easier (including autocomplete) -- In-browser pivot tables (which can also be shared via URLs) -- Ability to snapshot queries on a regular schedule, capturing changing - data +- Ability to snapshot queries on a regular schedule, capturing changing data - Query history and logs - Quick in-browser statistics, pivot tables, and scatter-plots (saving a trip to Excel for simple analyses) -- Basic code-completion in the SQL editor - Parameterized queries that automatically generate a friendly UI for users who don't know SQL - A playground area for quickly running ad-hoc queries @@ -75,31 +89,33 @@ Screenshots .. image:: https://sql-explorer.s3.amazonaws.com/5.0-query-with-schema.png +------------------ + **Using the SQL AI Assistant** .. image:: https://sql-explorer.s3.amazonaws.com/5.0-assistant.png +------------------ + **Viewing all queries** .. image:: https://sql-explorer.s3.amazonaws.com/5.0-query-list.png +------------------ + **Query results w/ stats summary** .. image:: https://sql-explorer.s3.amazonaws.com/5.0-query-results.png +------------------ + **Pivot in browser** .. image:: https://sql-explorer.s3.amazonaws.com/5.0-pivot.png +------------------ + **View logs** .. image:: https://sql-explorer.s3.amazonaws.com/5.0-querylogs.png -Development ------------- - -Included is a test_project that you can use to kick the tires. You can run this via ``docker compose up`` - -You can now navigate to 127.0.0.1:8000/explorer/, log in with admin/admin, and begin exploring! - -This will also run a Vite dev server with hot reloading for front-end changes. diff --git a/explorer/__init__.py b/explorer/__init__.py index a8806366..9117de56 100644 --- a/explorer/__init__.py +++ b/explorer/__init__.py @@ -1,9 +1,9 @@ __version_info__ = { "major": 5, - "minor": 0, - "patch": 2, - "releaselevel": "final", - "serial": 0 + "minor": 1, + "patch": 0, + "releaselevel": "beta", + "serial": 1 } diff --git a/pypi-release-checklist.md b/pypi-release-checklist.md index c11f08ed..6793b718 100644 --- a/pypi-release-checklist.md +++ b/pypi-release-checklist.md @@ -3,7 +3,7 @@ - [x] Make sure any new files are included in MANIFEST.in - [x] Update version number in `explorer/__init__.py` - [x] Update any package dependencies in `setup.py` -- [x] Commit the changes: +- [x] Commit the changes and add the tag *in master*: ``` git add . git commit -m "Release 1.0.0" @@ -14,50 +14,5 @@ git push --tags - Be sure to test the built JS source by running `npm run build` and setting `VITE_DEV_MODE = False` in settings.py -- [x] Build & test the source distribution: -``` -python setup.py build -mktmpenv -cd django-sql-explorer -cd dist -tar xzvf django-sql-explorer-x.x.tar.gz -cd django-sql-explorer-x.x/ -python setup.py install -python -m django startproject explorertest -cd explorertest/explorertest/ -emacs urls.py ->> from django.urls import path, include ->> path('explorer/', include('explorer.urls')), -emacs settings.py ->> add 'explorer' to installed apps ->> EXPLORER_CONNECTIONS = {'Default': 'default'} ->> EXPLORER_DEFAULT_CONNECTION = 'default' -cd.. -python manage.py migrate -python manage.py createsuperuser -python manage.py runserver ->> log in and try it! http://127.0.0.1:8000/explorer/ -deactivate -``` - -- [x] Release on PyPI: -``` -python setup.py release -``` - -- [x] Test that it pip installs: -``` -mktmpenv -pip install my_project -deactivate -``` - -- [x] Tag the last git commit with the version number: -``` -python setup.py tag -``` - - Put the same message as in HISTORY.rst. -- [x] Push: `git push` -- [x] Push tags: `git push --tags` -- [x] Check the PyPI listing page (https://pypi.python.org/pypi/django-sql-explorer) to make sure that the README, release notes display properly. +- [x] Check the PyPI listing page (https://pypi.python.org/pypi/django-sql-explorer) to make sure that the release + went out and that the README is displaying properly. diff --git a/setup.py b/setup.py index 8647a63f..8dde4afb 100644 --- a/setup.py +++ b/setup.py @@ -44,13 +44,13 @@ def requirements(fname): name=name, version=version, author="Chris Clark", - author_email="chris@untrod.com", - maintainer="Mark Walker", - maintainer_email="theshow@gmail.com", - description=("A pluggable app that allows users (admins) to execute SQL," - " view, and export the results."), + author_email="chris@sqlexplorer.io", + maintainer="Chris Clark", + maintainer_email="chris@sqlexplorer.io", + description=("SQL Reporting that Just Works. Fast, simple, and confusion-free." + "Write and share queries in a delightful SQL editor, with AI assistance"), license="MIT", - keywords="django sql explorer reports reporting csv database query", + keywords="django sql explorer reports reporting csv json database query", url="https://www.sqlexplorer.io", project_urls={ "Changes": "https://django-sql-explorer.readthedocs.io/en/latest/history.html",