Skip to main content

Local data and files

Files Watcher creates​

PathCreated whenContents
<project root>/.watcher/watcher.dbFirst valid npx watcher startSQLite database of completed runs. See Run history.
OS temp directory, short-livedPlanning a Playwright-aware runPlaywright's test listing for the planned count. Removed after use.
OS temp directory, watcher-tool-session-*Launching a Playwright ToolUI Mode output and session ownership data. Removed after the session ends.

Watcher does not create a configuration file and does not modify files in your project.

The history database​

  • Uses Node.js's built-in SQLite, run in a dedicated worker thread.
  • Writes use a rollback journal with full synchronization, so a completed write survives a crash.
  • The schema is versioned. Upgrading Watcher migrates the database automatically. Downgrading is unsupported: older versions keep newer data intact but may disable history.
  • A database that is corrupt, uses an unknown schema, or uses WAL journal mode is preserved untouched for manual recovery. Watcher never resets it.
  • If the .watcher/ directory or database is a link that leads outside the project, Watcher refuses to use it.
  • History can be lost if Watcher is killed before a write commits.

Git​

Add the directory to your project's Git ignore rules:

.gitignore
.watcher/

Backing up​

Stop Watcher, then copy .watcher/watcher.db. Watcher has no export feature in the Alpha.

Removing history​

Stop Watcher, then delete the .watcher/ directory. Watcher creates a new, empty database the next time it starts.