Skip to content

[Bug]: Column masking, sticky headers and some grid settings are lost on restart #883

Closed

Description

@debba

Describe the bug

Some settings are only kept for the current session: after a restart they are back to their defaults.

Affected keys (defined in src/contexts/SettingsContext.ts):

  • columnMaskingEnabled, columnMaskingPatterns, columnMaskingOverrides (Settings → Privacy, and the per-connection Privacy tab)
  • stickyColumnHeaders
  • rowEditorFollowSelection
  • cellDoubleClickAction

The frontend sends them to save_config, but save_config (src-tauri/src/config.rs:373) deserializes the payload into the Rust AppConfig struct and merges field by field. None of these keys exist in AppConfig, so serde drops them and they are never written to config.json. On the next launch load_config can't return them either.

To Reproduce

  1. Settings → Privacy: change the column masking toggle or add a pattern (or change "Cell double-click action").
  2. Quit and reopen Tabularis.
  3. The setting is back to its default, and config.json has no such key.

Expected behavior

The settings survive a restart like every other preference.

Where to start

  • src-tauri/src/config.rs: add the fields to AppConfig (types matching SettingsContext.ts; the masking patterns/overrides can be serde_json::Value or typed structs) and add the corresponding if config.x.is_some() merge lines in save_config.
  • Check src/contexts/SettingsProvider.tsx (stripSessionFields) to be sure none of them is meant to be session-only.

Acceptance criteria

  • All six keys round-trip through save_config / load_config.
  • A Rust unit test that saves and reloads them.
  • Existing config.json files without these keys keep loading (fields are Option).

Contributor notes

  • Follow the repo rules in .rules/ (TypeScript, React, Rust, testing).
  • Any new UI string needs a key in every locale under src/i18n/locales/.
  • Run pnpm lint, pnpm typecheck and pnpm test (and cargo test for Rust changes) before opening the PR.
  • Questions? Ask here or on Discord.

Activity

  1. added
    bug
    good first issue
    on Oct 7, 2026
  2. added a commit that references this issue on Oct 9, 2026
    f4b3871
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    buggood first issue

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions