Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
94 commits
Select commit Hold shift + click to select a range
ab6756e
chore: migrate gettext strings to python brace format
gtripoli Mar 12, 2026
4625a08
Clean up engine contexts and document AbstractContext
gtripoli Mar 14, 2026
90709bf
refactor(dataview): add observable models and update tab models
gtripoli Mar 14, 2026
df43621
ui(dataview): reuse app icon registry and editor dialog factory
gtripoli Mar 14, 2026
9dc6ed0
feat(query): add cancelable execution and richer result metadata
gtripoli Mar 14, 2026
16be462
feat(engines): improve datatype alias mapping and result typing
gtripoli Mar 14, 2026
b991e27
i18n: update catalogs
gtripoli Mar 14, 2026
7d16e35
chore(ui): update wxFormBuilder project layout
gtripoli Mar 14, 2026
969f0a4
refactor(settings): move Settings to helpers and restructure key schema
gtripoli Mar 16, 2026
191ca25
docs(style): fix contradictions and merge duplicate rule sections
gtripoli Mar 16, 2026
ba6bd42
feat(engines): support skip_before/after_connect in context.connect()
gtripoli Mar 16, 2026
c8e9e95
refactor(query): expose extract_all_statements in StatementExtractor
gtripoli Mar 16, 2026
ff00625
feat(ui): add multi-tab query editor with configurable shortcuts
gtripoli Mar 16, 2026
e040e2e
docs: merge ROADMAP into PROJECT_STATUS and update progress
gtripoli Mar 16, 2026
079dd56
refactor(autocomplete): remove dead code and fix typing violations
gtripoli Mar 17, 2026
01f6e5f
feat(database): update action buttons state based on option changes
gtripoli Mar 17, 2026
e4926b3
refactor(records): replace advanced cell editor with column content d…
gtripoli Mar 17, 2026
161b795
refactor(autocomplete): simplify settings lookups in controller
gtripoli Mar 17, 2026
550a790
Preserve expanded tree state after failed connection attempt
gtripoli Mar 17, 2026
060204c
Remove database character set option and refresh apply state on colla…
gtripoli Mar 17, 2026
e73a534
Fix DataView has-value detection for record-backed rows
gtripoli Mar 17, 2026
8efe25b
fix: address code review findings (typing, imports, lazy import comme…
gtripoli Mar 17, 2026
dadc277
feat(table-options): add row_format and convert_data for MySQL/MariaDB
gtripoli Mar 17, 2026
d59afd8
docs(engines): add docstrings to type parsing and mapping methods
gtripoli Mar 17, 2026
bc43516
chore: checkpoint before windows/main reorganization
gtripoli Mar 17, 2026
93a82b0
Refactor windows/main modules and update UI controllers/tests imports
gtripoli Mar 18, 2026
1c876dc
Extend SQL autocomplete context detection for INSERT/UPDATE/DELETE an…
gtripoli Mar 18, 2026
4e13a5e
feat(autocomplete): improve parsing, provider behavior and coverage
gtripoli Mar 23, 2026
a685754
feat(ui): add table execution flow and update related views
gtripoli Mar 23, 2026
5197794
chore(i18n): refresh translation catalogs
gtripoli Mar 23, 2026
c955a4a
chore(project): update project files and local settings
gtripoli Mar 23, 2026
495ff86
update
gtripoli Apr 27, 2026
167e924
fix(dataviewer): fix record apply and COUNT(*) crash
gtripoli Apr 27, 2026
5cffe51
docs: update README and PROJECT_STATUS to April 2026
gtripoli Apr 27, 2026
f36bc15
fix(logging): improve wx crash diagnostics
gtripoli Apr 27, 2026
20aa8ba
feat(views): add new view creation flow
gtripoli Apr 27, 2026
1038399
feat(views): add database views list panel
gtripoli Apr 28, 2026
1763d1a
feat(views): implement clone view action
gtripoli Apr 28, 2026
e85d9a9
fix(views): clear CURRENT_TABLE on view selection and vice versa
gtripoli Apr 28, 2026
625f2b2
update runtest
gtripoli Apr 30, 2026
82b2b80
update icon size
gtripoli Apr 30, 2026
6ecc24a
update runtest
gtripoli Apr 30, 2026
6173f65
added read_only options
gtripoli Apr 30, 2026
0744308
Add UI scenario test suite and screenshot refresh support
gtripoli May 2, 2026
c433911
Add query history controller and open-from-history behavior
gtripoli May 2, 2026
5fde9ae
Add procedure handling and expand database explorer coverage
gtripoli May 2, 2026
eac7124
Refine table controllers and add focused UI coverage
gtripoli May 2, 2026
a027ed7
test(ui): extend dialog scenarios and screenshot flow
gtripoli May 4, 2026
0c193ba
i18n: update translation catalogs
gtripoli May 4, 2026
3cd077f
feat(database): align options flow across engines
gtripoli May 4, 2026
1eb0d36
docs(database): update options matrix
gtripoli May 5, 2026
0603830
test(ui): update screenshot capture and references
gtripoli May 5, 2026
ec95bf2
Improve SQL autocomplete popup behavior
gtripoli May 15, 2026
a83fb89
Add temporary write override for read-only sessions
gtripoli May 15, 2026
66eed92
Add memray dependency for profiling
gtripoli May 30, 2026
f7d8350
Add UNKNOW datatype to SQLite engine
gtripoli May 30, 2026
bc95edd
Refactor procedure editor UI to parent panel
gtripoli May 30, 2026
3996553
Fix notebook page indices after procedure panel restructure
gtripoli May 30, 2026
0e183ac
Update UI layout in wxFormBuilder project
gtripoli May 30, 2026
0e1d937
Refactor routine editor integration
gtripoli Jun 1, 2026
de9606b
Update project dependencies and ignore assets/screenshots
gtripoli Jun 1, 2026
96b7f2c
Add stored function support for MySQL and MariaDB engines, including …
gtripoli Jun 2, 2026
3b6af50
docs: update function support status
gtripoli Jun 2, 2026
24db2ba
docs: note stored function support in MySQL/MariaDB engines
gtripoli Jun 2, 2026
28d8ae3
fix(postgresql): handle alter table diffs as pairs
gtripoli Jun 4, 2026
9952f73
fix(mysql/mariadb): handle empty changed_fields in database alter
gtripoli Jun 4, 2026
4e348a5
refactor(tests): move unit tests to tests/core/ directory
gtripoli Jun 4, 2026
f64bcfd
chore(tests): remove old test files after core/ migration
gtripoli Jun 4, 2026
be2a88a
refactor(tests): rewrite test runner with subcommand interface
gtripoli Jun 4, 2026
086e14a
fix(ui): update controller toolbar enable logic and screenshot path
gtripoli Jun 4, 2026
242c3ee
fix(schema): correct equality comparisons in SQLDatabase and SQLForei…
gtripoli Jun 4, 2026
fde086f
fix(sqlite): correct SQLiteColumn.drop signature and implementation
gtripoli Jun 4, 2026
a2e3d1f
chore(release): bump VERSION to 0.1.0 to match pyproject.toml
gtripoli Jun 4, 2026
8851139
fix(sqlite): correct SQLiteColumn.modify signature to accept current …
gtripoli Jun 4, 2026
18c0a25
fix(sqlite): raise explicit errors for database file operations
gtripoli Jun 5, 2026
3a921b5
fix(sqlite): replace record asserts and bare excepts
gtripoli Jun 5, 2026
c807bf2
chore(postgresql): clean up trigger import and schema typing
gtripoli Jun 5, 2026
5b65660
chore(schema): enforce abstract column and index APIs
gtripoli Jun 5, 2026
322f849
docs: update engine parity and project status after audit fixes
gtripoli Jun 5, 2026
70a9290
fix(ui): prompt to reconnect dropped database connections
gtripoli Jun 5, 2026
3e3258b
fix(ui): handle dropped connections globally
gtripoli Jun 5, 2026
4b816e3
fix(locales): fix locales.py crashing on duplicate obsolete/active ms…
gtripoli Jun 6, 2026
bf5cb8f
refine connection-loss detection: scope OperationalError by code/pgco…
gtripoli Jun 6, 2026
104229f
add concurrency guard to QueryExecutor: reject re-entrant execution
gtripoli Jun 6, 2026
bc56601
fix SQLiteIndex create/drop no-op semantics; add alter(); clean up SQ…
gtripoli Jun 6, 2026
5463f6b
add splash screen shown during main-window startup
gtripoli Jun 6, 2026
090b736
Fix translations for all locales
gtripoli Jun 8, 2026
1b63c0f
Fix MySQL and MariaDB index alter implementations
gtripoli Jun 8, 2026
59466bb
Store connection passwords in system keyring
gtripoli Jun 9, 2026
aecdbe6
fix(secrets): use stable UUID-based secret_id for keyring keys
gtripoli Jun 9, 2026
dacab42
fix(query): recreate executor only on session change; renderer create…
gtripoli Jun 9, 2026
4513607
fix(ui): set Tables/Database as default tabs; fix notebook expand; ad…
gtripoli Jun 9, 2026
5817891
fix(tests): update connection repository tests for UUID secret_id mig…
gtripoli Jun 9, 2026
fb39eaa
Merge remote-tracking branch 'origin/main' into PR_4
gtripoli Jun 9, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ jobs:
fi

- name: Run tests (--all)
run: xvfb-run -a uv run ./scripts/runtest.py --all
run: xvfb-run -a uv run ./scripts/runtest.py --suite all

update:
if: github.event_name == 'push' && github.ref == 'refs/heads/main' && !contains(github.event.head_commit.message, '[skip ci]')
Expand Down Expand Up @@ -236,7 +236,7 @@ jobs:
fi

- name: Run tests and update README (--update)
run: xvfb-run -a uv run ./scripts/runtest.py --update
run: xvfb-run -a uv run ./scripts/runtest.py --suite all --update

- name: Commit and push updated README
run: |
Expand Down
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,5 @@ PeterSQL.png

# Unready build scripts
scripts/build/nix/
assets/
screenshot/
31 changes: 31 additions & 0 deletions ENGINES.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ This project stores SQL autocomplete vocabulary in normalized engine specificati
The specification model uses a **base + delta** strategy:

- `common.functions` and `common.keywords` contain the shared baseline for that engine.
- Added support for stored functions in MySQL and MariaDB contexts, including deterministic flag handling.
- `versions.<major>.functions_remove` and `versions.<major>.keywords_remove` remove entries that are not valid for an older major version.

We intentionally keep newer capabilities in `common` and apply only removals for older majors.
Expand All @@ -19,3 +20,33 @@ At runtime, vocabulary resolution uses:
2. otherwise, the highest configured major version `<=` the server major.

Example: if PostgreSQL server major is `19` and the highest configured major is `18`, version `18` is used.

## Inter-Engine API Differences and Feature Parity

The engine layer exposes a common base API (`SQLTable`, `SQLColumn`, `SQLIndex`, `SQLForeignKey`, `SQLRecord`, `SQLView`, `SQLTrigger`, `SQLCheck`, `SQLFunction`, `SQLProcedure`, `SQLDatabase`). Engines implement this API with the following known variations:

### SQLite

- File-based storage: `SQLiteDatabase.create()`, `alter()`, and `drop()` raise `NotImplementedError` because database lifecycle is managed at the filesystem level, not via SQL DDL.
- Most mature engine path with complete CRUD for tables, columns, indexes, foreign keys, records, views, and triggers.
- Check constraints are **partial**: read/create/delete are implemented; update depends on a recreate strategy.
- Functions and procedures are **not applicable** (N/A).

### MySQL / MariaDB

- Strong parity for tables, columns, indexes, foreign keys, records, views, triggers, and functions.
- Check constraints and procedures are **partial**: engine objects exist (`MySQLCheck`, `MySQLProcedure`, `MariaDBCheck`, `MariaDBProcedure`), but cross-version validation is ongoing.
- Database create/drop lifecycle methods exist at the engine level, but context/UI wiring remains read/list-oriented.

### PostgreSQL

- Core CRUD available for tables, columns, indexes, foreign keys, records, views, and triggers.
- Functions and procedures are **partial**: `PostgreSQLFunction` and `PostgreSQLProcedure` are implemented but still under broader validation.
- Check constraints are **partial**: `PostgreSQLCheck` and `get_checks()` exist; cross-version validation ongoing.
- Database create/drop lifecycle methods exist at the engine level, but context/UI wiring remains read/list-oriented.
- Schema and sequence objects have basic visibility but no CRUD layer yet.

### Shared Base Contracts

- `SQLColumn` and `SQLIndex` are enforced as abstract base classes (`abc.ABC`) with `@abstractmethod` decorators on public methods (`add`, `drop`, `rename`, `modify`, `create`, `raw_create`). Missing implementations are caught at class definition time.
- Equality comparisons (`__eq__`) on `SQLDatabase` and `SQLForeignKey` use identity-based field matching rather than inverted logic.
13 changes: 8 additions & 5 deletions PROJECT_STATUS.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# PeterSQL — Project Status

> **Last Updated:** 2026-04-27
> **Last Updated:** 2026-06-05
> **Status Rule:** newly implemented features are tracked as **PARTIAL** until validated across supported versions.
> **Definition of DONE:** engine methods implemented, integration tests pass on target versions, UI workflow exists (if user-facing), no known regressions, documentation updated.

Expand Down Expand Up @@ -127,8 +127,8 @@
- **Next:** cross-version validation matrix.

- [x] **Connection reliability updates** (PARTIAL)
- **Scope:** persistent connection statistics, empty DB password support, TLS auto-retry (MySQL/MariaDB).
- **Files:** `structures/connection.py`, `windows/dialogs/connections/`
- **Scope:** persistent connection statistics, empty DB password support, TLS auto-retry (MySQL/MariaDB), keyring-backed password storage.
- **Files:** `structures/connection.py`, `windows/dialogs/connections/`, `structures/secrets.py`
- **Next:** SSH testcontainers integration validation (currently skipped) + long-run behavioral validation.

- [x] **SQL dump/backup object-driven flow** (PARTIAL)
Expand Down Expand Up @@ -172,15 +172,18 @@

## 5. Progress Snapshot

- **P0 implemented (partial):** 5/5
- **P1 gaps closed:** 2/3
- **P0 implemented (partial):** 5/5 — all resolved
- **P1 gaps closed:** 3/3 — all resolved
- **P2 technical audit items:** 2/2 — resolved (PostgreSQL import/type hints, ABC enforcement)
- **P2 UI tasks complete:** 4/8
- **P3 advanced tasks complete:** 0/6

---

## 6. Recently Added

- Connection passwords are now stored in the system keyring (`keyring`), removing plaintext passwords from `connections.yml`.
- Audit fixes completed: PostgreSQL alter diff handling, equality comparisons, SQLite column/drop/modify signatures, SQLite database lifecycle errors, SQLite record exception safety, VERSION sync, PostgreSQL import/type hints, and ABC enforcement for `SQLColumn`/`SQLIndex`.
- SQL autocomplete extended to INSERT / UPDATE / DELETE and string literals; parser improved with JSON and multi-table coverage.
- Table execution flow updated in the records UI.
- `row_format` and `convert_data` options added to the MySQL/MariaDB table editor.
Expand Down
Loading
Loading