Repository navigation
docs: sync ARCHITECTURE.md section 9 with reality - #248
Merged
Merged
Conversation
The "Local Storage Architecture" section claimed directories and schema that don't exist. Replace fiction with the actual state of the codebase. Old claims that were wrong (all removed): - `config.toml` — does not exist. Settings are in localStorage via zustand stores. Section replaced with a localStorage-key table. - `history.db` — does not exist. Query history is in localStorage via `historyStore.ts` + `zustand/middleware::persist`. Removed the entire history.db schema section. - `themes/`, `snippets/`, `backups/`, `cache/schema/`, `cache/ai/` — none of these directories exist. Replaced with a one-paragraph note pointing to the actual storage locations (theme localStorage key, favoritesStore, in-memory schema cache, in-memory AI cache). - `connections.db` schema listed `password_ref`, `sort_order`, `pool_config` — none of these columns exist. Replaced with the ACTUAL schema: 19 columns with their real migration chain (env, connect_timeout_secs, query_timeout_secs, charset). The `password` column gets emptied after keyring migration; password is held in OS keyring via `apple-native-keyring-store`, not in the SQL row. - `query_history` table — does not exist. Replaced with a paragraph on the in-memory + persist-middleware implementation and the future-SQLite migration scope. The corrected doc has: - File tree: `connections.db` (+ wal/shm) and `logs/` only. Two text files. No config.toml, no history.db, no themes, no snippets. - localStorage keys table (theme, sqlpilot-formatter-settings, sqlpilot-query-settings, mas-query-history, mas-query-favorites, sqlpilot-editor-session) with their owners and formats. - Password storage section explaining the keyring + migration + why the SQL `password` column gets emptied. - Actual `connection_profiles` SQL with the real 19 columns and a migration chain table. - A short paragraph on the missing `password_ref` / `sort_order` / `pool_config` so future contributors don't assume they exist. No code changes. Pure doc. Cross-linked to #241 (SQLite migration framework) — the `.ok()`- swallowed ALTER TABLE approach flagged as needing replacement with a `PRAGMA user_version`-gated runner.
3 tasks done
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
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
docs: sync ARCHITECTURE.md section 9 with reality
The "Local Storage Architecture" section claimed directories and
schema that don't exist. Replace fiction with the actual state of
the codebase.
Old claims that were wrong (all removed):
config.toml— does not exist. Settings are in localStorage viazustand stores. Section replaced with a localStorage-key table.
history.db— does not exist. Query history is in localStoragevia
historyStore.ts+zustand/middleware::persist. Removedthe entire history.db schema section.
themes/,snippets/,backups/,cache/schema/,cache/ai/— none of these directories exist. Replaced with a one-paragraph
note pointing to the actual storage locations (theme localStorage
key, favoritesStore, in-memory schema cache, in-memory AI cache).
connections.dbschema listedpassword_ref,sort_order,pool_config— none of these columns exist. Replaced with theACTUAL schema: 19 columns with their real migration chain (env,
connect_timeout_secs, query_timeout_secs, charset). The
passwordcolumn gets emptied after keyring migration; password is held in
OS keyring via
apple-native-keyring-store, not in the SQL row.query_historytable — does not exist. Replaced with aparagraph on the in-memory + persist-middleware implementation
and the future-SQLite migration scope.
The corrected doc has:
connections.db(+ wal/shm) andlogs/only. Twotext files. No config.toml, no history.db, no themes, no snippets.
sqlpilot-query-settings, mas-query-history, mas-query-favorites,
sqlpilot-editor-session) with their owners and formats.
why the SQL
passwordcolumn gets emptied.connection_profilesSQL with the real 19 columns and amigration chain table.
password_ref/sort_order/pool_configso future contributors don't assume they exist.No code changes. Pure doc.
Cross-linked to #241 (SQLite migration framework) — the
.ok()-swallowed ALTER TABLE approach flagged as needing replacement with
a
PRAGMA user_version-gated runner.