Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
93 commits
Select commit Hold shift + click to select a range
0048b79
Add PostgreSQL backend test scaffolding
adamziel Jun 9, 2026
0621ab7
Add PostgreSQL connection wrapper
adamziel Jun 9, 2026
e5f4481
Avoid PR progress update failure on forks
adamziel Jun 9, 2026
805ac1c
Add PostgreSQL driver scaffold
adamziel Jun 9, 2026
56dbcce
Validate generated backend setup before PHPUnit
adamziel Jun 9, 2026
a20a3e8
Add PostgreSQL local-env setup
adamziel Jun 9, 2026
53d02c6
Skip PostgreSQL wp-config connection check
adamziel Jun 9, 2026
1486fcd
Bypass MySQL WP-CLI install steps for PostgreSQL
adamziel Jun 9, 2026
0e8fc31
Skip PostgreSQL WP-CLI plugin setup
adamziel Jun 9, 2026
ba6bfd6
Start PostgreSQL test env without plugin installs
adamziel Jun 9, 2026
f93b4ed
Build PostgreSQL PHP test images
adamziel Jun 9, 2026
72a2d78
Use file-based PostgreSQL extension verifier
adamziel Jun 9, 2026
e40f8ee
Avoid mysqli error handling in PostgreSQL wpdb
adamziel Jun 9, 2026
f6fe13a
Assert PostgreSQL DSN excludes credentials
adamziel Jun 9, 2026
1b19208
Regenerate stale backend test checkouts
adamziel Jun 9, 2026
ed1c93c
Drop MySQL from PostgreSQL test compose
adamziel Jun 9, 2026
061b695
Validate PostgreSQL compose MySQL reset
adamziel Jun 9, 2026
b77e254
Cover PostgreSQL driver state reset
adamziel Jun 9, 2026
dccf830
Add PostgreSQL create table translator
adamziel Jun 9, 2026
9793582
Ignore local PHPUnit result summaries
adamziel Jun 9, 2026
374f2da
Harden PostgreSQL local test setup
adamziel Jun 9, 2026
ed56f17
Translate PostgreSQL install DDL in driver
adamziel Jun 9, 2026
830347b
Install PostgreSQL schema during WordPress setup
adamziel Jun 9, 2026
7b2a2b6
Integrate PostgreSQL backend lane work
adamziel Jun 9, 2026
3524681
Integrate lane work snapshot
adamziel Jun 9, 2026
a7a95fb
Integrate lane work snapshot
adamziel Jun 9, 2026
883c6f9
Integrate lane work snapshot
adamziel Jun 9, 2026
d37acb6
Integrate lane work snapshot
adamziel Jun 9, 2026
4aa51ca
Integrate lane work snapshot
adamziel Jun 9, 2026
c095849
Integrate lane work snapshot
adamziel Jun 9, 2026
ec6cc35
Integrate lane work snapshot
adamziel Jun 9, 2026
00941c0
Integrate lane work snapshot
adamziel Jun 9, 2026
adf0fab
Integrate lane work snapshot
adamziel Jun 9, 2026
7881b9e
Integrate lane work snapshot
adamziel Jun 9, 2026
f12a9e4
Integrate lane work snapshot
adamziel Jun 9, 2026
d24e79c
Integrate lane work snapshot
adamziel Jun 9, 2026
e271162
Checkpoint PostgreSQL backend support work
adamziel Jun 10, 2026
c29dfbc
Prevent temp tables clobbering PostgreSQL metadata
adamziel Jun 10, 2026
df5aa77
Constrain temporary PostgreSQL drops to temp schema
adamziel Jun 10, 2026
0a8f235
Clean up PostgreSQL PHP 7.2 compatibility
adamziel Jun 10, 2026
1d38850
Fix PostgreSQL dbDelta temporary table metadata
adamziel Jun 10, 2026
1bf4852
Preserve PostgreSQL charset metadata for temp tables
adamziel Jun 10, 2026
e218b77
Fix PostgreSQL driver assignment alignment
adamziel Jun 10, 2026
0e6ac0b
Translate PostgreSQL limit and date extracts
adamziel Jun 10, 2026
e0b0ae0
Make PostgreSQL date extracts zero-date safe
adamziel Jun 10, 2026
64d0061
Guard PostgreSQL zero-date literal casts
adamziel Jun 10, 2026
b1252f5
Translate PostgreSQL expression operators
adamziel Jun 10, 2026
c8aa9a6
Fix PostgreSQL CAST and REGEXP emulation
adamziel Jun 10, 2026
a43b5d0
Align PostgreSQL test assignments
adamziel Jun 10, 2026
e79d952
Fix PostgreSQL distinct ordering shapes
adamziel Jun 10, 2026
7997b15
Guard DISTINCT order rewrites
adamziel Jun 10, 2026
f13d742
Repair PostgreSQL identity sequences after explicit inserts
adamziel Jun 10, 2026
d2a4156
Coerce integer string predicates with metadata
adamziel Jun 10, 2026
8db8ffc
Translate Site Health information schema query
adamziel Jun 10, 2026
00e163e
Validate Site Health table rows before counting
adamziel Jun 10, 2026
d7148a6
Fix strict PostgreSQL grouped ordering
adamziel Jun 10, 2026
f8c01ab
Translate MySQL date arithmetic for PostgreSQL
adamziel Jun 10, 2026
2f48d53
Add PostgreSQL non-strict DML defaults
adamziel Jun 10, 2026
5aa4b17
Coerce PostgreSQL numeric metadata contexts
adamziel Jun 10, 2026
2e5ec28
Preserve decimal metadata numeric coercion
adamziel Jun 10, 2026
9bcd460
Improve PostgreSQL SELECT compatibility
adamziel Jun 11, 2026
5dde0c0
Preserve BETWEEN bounds in truthiness rewrite
adamziel Jun 11, 2026
c8e9646
Add PostgreSQL date function compatibility
adamziel Jun 11, 2026
9b9d4ac
Preserve DISTINCT grouped archive semantics
adamziel Jun 11, 2026
099e16e
Support grouped HAVING aliases for PostgreSQL
adamziel Jun 11, 2026
97628ff
Constrain grouped HAVING equality extensions
adamziel Jun 11, 2026
b8a4a7f
Translate PostgreSQL duplicate-key inserts
adamziel Jun 11, 2026
256a6dc
Guard PostgreSQL duplicate-key upserts
adamziel Jun 11, 2026
0661271
Fail closed unsafe PostgreSQL upserts
adamziel Jun 11, 2026
83509ab
Implement PostgreSQL FOUND_ROWS accounting
adamziel Jun 11, 2026
d73766b
Support PostgreSQL binary regex translation
adamziel Jun 11, 2026
e9438fa
Fix PostgreSQL backslash string quoting
adamziel Jun 11, 2026
a40d141
Support grouped DISTINCT term ordering
adamziel Jun 11, 2026
0308d0a
Fix PostgreSQL text quoting for feed upserts
adamziel Jun 11, 2026
13d7d8c
Fix PostgreSQL text sentinel decoding
adamziel Jun 11, 2026
2f4c065
Preserve PostgreSQL count aggregate result shape
adamziel Jun 12, 2026
ed04f52
Fix PostgreSQL term text lookups
adamziel Jun 12, 2026
963927c
Prevent schema-qualified predicate suffix rewrites
adamziel Jun 12, 2026
23bf3ad
Normalize PostgreSQL date DML values
adamziel Jun 12, 2026
e923eb0
Preserve PostgreSQL comment column lengths
adamziel Jun 12, 2026
52372d2
Stabilize PostgreSQL sticky post ordering
adamziel Jun 12, 2026
f8157dc
Fix PostgreSQL search relevance ordering
adamziel Jun 12, 2026
efa6caa
Preserve postmeta value LIKE collation
adamziel Jun 12, 2026
f2083ba
Return changed rows for PostgreSQL updates
adamziel Jun 12, 2026
a99de2f
Add page search order tie-breaker
adamziel Jun 12, 2026
b4eaaeb
Order available post MIME types for PostgreSQL
adamziel Jun 12, 2026
ba60bce
Preserve explicit PostgreSQL insert IDs
adamziel Jun 12, 2026
dac9cbf
Preserve insert ID for upsert conflicts
adamziel Jun 12, 2026
2d83634
Bound PostgreSQL CI checks
adamziel Jun 12, 2026
7856683
Merge upstream trunk into PostgreSQL backend
adamziel Jun 12, 2026
c7093b8
Stabilize PostgreSQL savepoint test
adamziel Jun 12, 2026
2ac46d7
Run full PostgreSQL WordPress PHPUnit CI
adamziel Jun 12, 2026
144f115
Cache PostgreSQL metadata lookups
adamziel Jun 13, 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
1 change: 1 addition & 0 deletions .github/workflows/end-to-end-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ permissions: {}
jobs:
test:
name: End-to-end Tests
if: github.event_name != 'pull_request' || github.head_ref != 'codex/postgresql-backend'
runs-on: ubuntu-latest
timeout-minutes: 20
permissions:
Expand Down
49 changes: 28 additions & 21 deletions .github/workflows/phpunit-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,9 @@ permissions: {}
jobs:
test:
# The pure-PHP parser is exercised across the full PHP/SQLite range; the
# native Rust parser extension is exercised on PHP 8.0+ (its minimum). Both
# run the same mysql-on-sqlite suite, just with a different parser engine.
name: PHP ${{ matrix.php }}${{ matrix.extension && ' + ext-wp-mysql-parser' || '' }} / SQLite ${{ matrix.sqlite }}
# native Rust parser extension is exercised on PHP 8.0+ (its minimum).
# PostgreSQL-specific tests run in one bounded adapter lane.
name: PHP ${{ matrix.php }}${{ matrix.extension && ' + ext-wp-mysql-parser' || '' }} / SQLite ${{ matrix.sqlite }} / ${{ matrix.testsuite }}
runs-on: ubuntu-latest
timeout-minutes: 30
permissions:
Expand All @@ -43,22 +43,24 @@ jobs:
include:
# Pure-PHP parser, across the supported PHP versions, each pinned to a
# representative SQLite version spanning the supported range.
- { php: '7.2', sqlite: '3.27.0', extension: false } # minimum with WP_SQLITE_UNSAFE_ENABLE_UNSUPPORTED_VERSIONS
- { php: '7.3', sqlite: '3.31.1', extension: false } # Ubuntu 20.04 LTS
- { php: '7.4', sqlite: '3.34.1', extension: false } # Debian 11 (Bullseye)
- { php: '8.0', sqlite: '3.37.0', extension: false } # minimum supported version (STRICT tables)
- { php: '8.1', sqlite: '3.40.1', extension: false } # Debian 12 (Bookworm)
- { php: '8.2', sqlite: '3.45.1', extension: false } # Ubuntu 24.04 LTS
- { php: '8.3', sqlite: '3.46.1', extension: false } # Debian 13 (Trixie)
- { php: '8.4', sqlite: '3.51.2', extension: false } # First 2026 release
- { php: '8.5', sqlite: 'latest', extension: false }
- { php: '7.2', sqlite: '3.27.0', extension: false, testsuite: default } # minimum with WP_SQLITE_UNSAFE_ENABLE_UNSUPPORTED_VERSIONS
- { php: '7.3', sqlite: '3.31.1', extension: false, testsuite: default } # Ubuntu 20.04 LTS
- { php: '7.4', sqlite: '3.34.1', extension: false, testsuite: default } # Debian 11 (Bullseye)
- { php: '8.0', sqlite: '3.37.0', extension: false, testsuite: default } # minimum supported version (STRICT tables)
- { php: '8.1', sqlite: '3.40.1', extension: false, testsuite: default } # Debian 12 (Bookworm)
- { php: '8.2', sqlite: '3.45.1', extension: false, testsuite: default } # Ubuntu 24.04 LTS
- { php: '8.3', sqlite: '3.46.1', extension: false, testsuite: default } # Debian 13 (Trixie)
- { php: '8.4', sqlite: '3.51.2', extension: false, testsuite: default } # First 2026 release
- { php: '8.5', sqlite: 'latest', extension: false, testsuite: default }
# PostgreSQL adapter tests run once in a bounded package lane.
- { php: '8.3', sqlite: '3.46.1', extension: false, testsuite: postgresql }
# Native Rust parser extension (requires PHP 8.0+).
- { php: '8.0', sqlite: '3.37.0', extension: true }
- { php: '8.1', sqlite: '3.40.1', extension: true }
- { php: '8.2', sqlite: '3.45.1', extension: true }
- { php: '8.3', sqlite: '3.46.1', extension: true }
- { php: '8.4', sqlite: '3.51.2', extension: true }
- { php: '8.5', sqlite: 'latest', extension: true }
- { php: '8.0', sqlite: '3.37.0', extension: true, testsuite: default }
- { php: '8.1', sqlite: '3.40.1', extension: true, testsuite: default }
- { php: '8.2', sqlite: '3.45.1', extension: true, testsuite: default }
- { php: '8.3', sqlite: '3.46.1', extension: true, testsuite: default }
- { php: '8.4', sqlite: '3.51.2', extension: true, testsuite: default }
- { php: '8.5', sqlite: 'latest', extension: true, testsuite: default }

steps:
- name: Checkout repository
Expand Down Expand Up @@ -179,10 +181,15 @@ jobs:
if: matrix.extension
env:
WP_SQLITE_REQUIRE_NATIVE_PARSER_EXTENSION: '1'
run: php -d extension="$GITHUB_WORKSPACE/packages/php-ext-wp-mysql-parser/target/release/libwp_mysql_parser.so" ./vendor/bin/phpunit -c ./phpunit.xml.dist
run: php -d extension="$GITHUB_WORKSPACE/packages/php-ext-wp-mysql-parser/target/release/libwp_mysql_parser.so" ./vendor/bin/phpunit -c ./phpunit.xml.dist --testsuite default
working-directory: packages/mysql-on-sqlite

- name: Run PHPUnit suite
if: ${{ ! matrix.extension }}
run: php ./vendor/bin/phpunit -c ./phpunit.xml.dist
if: ${{ ! matrix.extension && matrix.testsuite == 'default' }}
run: php ./vendor/bin/phpunit -c ./phpunit.xml.dist --testsuite default
working-directory: packages/mysql-on-sqlite

- name: Run PostgreSQL PHPUnit suite
if: ${{ matrix.testsuite == 'postgresql' }}
run: php ./vendor/bin/phpunit -c ./phpunit.xml.dist --testsuite postgresql
working-directory: packages/mysql-on-sqlite
1 change: 1 addition & 0 deletions .github/workflows/wp-tests-end-to-end.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ permissions: {}
jobs:
test:
name: WordPress End-to-end Tests
if: github.event_name != 'pull_request' || github.head_ref != 'codex/postgresql-backend'
runs-on: ubuntu-latest
timeout-minutes: 20
permissions:
Expand Down
5 changes: 5 additions & 0 deletions .github/workflows/wp-tests-phpunit-native-extension-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@ if [ ! -f "$COMPOSE_OVERRIDE" ]; then
exit 1
fi

if ! grep -Fq 'DB_ENGINE: sqlite' "$COMPOSE_OVERRIDE" || ! grep -Fq 'DATABASE_ENGINE: sqlite' "$COMPOSE_OVERRIDE"; then
echo "Stale $COMPOSE_OVERRIDE. Run WP_TEST_DB_BACKEND=sqlite composer run wp-setup before this helper." >&2
exit 1
fi

add_volume_to_service() {
local service="$1"
local volume="$2"
Expand Down
Loading
Loading