You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add location checks and redesign SQLite settings - #530
Randomized paths and DB_PATH do not prevent web downloads. This adds location warnings and a redesigned settings screen to help administrators protect their SQLite database.
Location warnings: Flag databases inside the WordPress directory, content directory, or a known web root in SQLite settings and Site Health. Site Health skips this warning on local sites.
Database overview: Show integration status, database size including sidecars, and a hidden path that administrators can reveal and copy.
Protection guidance: Explain how to choose private storage or block web access in a dedicated Database protection tab, with instructions for new and existing installations.
Unified setup: Combine requirements, location guidance, and installation in one panel. Clarify that setup starts a fresh WordPress site without copying existing content.
These checks assess location only. They do not test HTTP access, move a database, or change its configuration. A path outside known public roots is not proof of protection.
It looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the reviews.auto_review.auto_pause_after_reviewed_commits setting.
Included review availability: This review used your included allowance. Your plan provides up to 2 included reviews per hour; 1 remain after this review.
Walkthrough
The change adds database-location classification and write checks, database-size accounting, setup and protection views in the SQLite admin page, and a Site Health recommendation for public database locations. It also adds tests for these behaviors and related admin-screen interactions.
Adds the tabbed settings interface, setup checks, database details, protection status and instructions, and clipboard feedback. Styles, FAQ text, and tests cover the interface and setup behavior. The authorization tests use a shared drop-in test helper.
Report database status in Site Health packages/plugin-sqlite-database-integration/health-check.php, tests/phpunit/WP_SQLite_Storage_Health_Test.php
Uses shared size accounting for database-size reporting. Adds a Site Health recommendation for public database locations and tests its conditions and exclusions.
This change adds database-location warnings, a database-size display, and a redesigned SQLite settings page. No actionable merge-blocking risk remains after review.
Pre-merge checks: 5
Check name
Status
Explanation
Description Check
Check skipped - CodeRabbit’s high-level summary is enabled.
Title check
The title clearly and concisely summarizes the main changes: adding database location checks and redesigning the SQLite settings interface.
Docstring Coverage
Docstring coverage is inconclusive: files from earlier reviews still need to be rechecked within the check's analysis limits. Not blocking.
Linked Issues check
Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check
Check skipped because no linked issues were found for this pull request.
Finishing Touches
📝 Generate docstrings
Commit to this branch
Create a new PR
🧪 Generate unit tests (beta)
Commit to this branch
Create a new PR
Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Warning
Some tools did not complete. Review the errors below.
PHPStan (2.3.1)
PHPStan reported 2 non-file analysis error(s); analysis is incomplete
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.
Warn in Site Health and SQLite settings when the database is under a known public root, including randomized and custom paths. Account for symlinks and keep unknown locations distinct from paths outside known public roots. These checks do not test web access or change database storage. Site Health skips the recommendation on local sites.
Organize settings into Overview and Database protection tabs with database size, a hidden path that can be revealed and copied, and instructions for protecting new and existing databases. Site Health Info reports the same database size. Preserve installation and multisite permissions, and cover the behavior with focused tests.
Combine installation requirements, database location guidance, and the install action in one panel. Clarify that switching does not copy the existing content, while preserving installation guards and Query Monitor support.
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
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.
Randomized paths and
DB_PATHdo not prevent web downloads. This adds location warnings and a redesigned settings screen to help administrators protect their SQLite database.These checks assess location only. They do not test HTTP access, move a database, or change its configuration. A path outside known public roots is not proof of protection.
Screenshots
Setup
Overview
Database protection
Related: #502, #512, #520.
Summary by CodeRabbit