MDL-88218: Add experimental SQLite support for Moodle WASM environments (main)#1
Open
erseco wants to merge 5 commits into
Open
Conversation
erseco
force-pushed
the
MDL-88218-Add-experimental-SQLite-support-for-Moodle-WASM-environments
branch
from
March 27, 2026 07:26
1ae328a to
2e0b63b
Compare
erseco
force-pushed
the
MDL-88218-Add-experimental-SQLite-support-for-Moodle-WASM-environments
branch
from
April 4, 2026 09:00
2e0b63b to
57750bb
Compare
erseco
force-pushed
the
MDL-88218-Add-experimental-SQLite-support-for-Moodle-WASM-environments
branch
2 times, most recently
from
May 26, 2026 20:36
3af3394 to
e7ede2e
Compare
erseco
force-pushed
the
MDL-88218-Add-experimental-SQLite-support-for-Moodle-WASM-environments
branch
2 times, most recently
from
June 4, 2026 15:52
50d6314 to
1a24393
Compare
Reintroduces experimental SQLite support via PDO, intended for WASM-based and other constrained ephemeral runtimes (portable demos, educational sandboxes, local experimentation). Not proposed as a production database backend. - Add SQLite 3 (PDO) as an installer database option - Restore the SQLite DML driver and DDL generator - Fix transaction result handling in pdo_moodle_database Also fix fetch_columns() to find temporary tables in SQLite: it only queried sqlite_master, but SQLite stores temporary tables in sqlite_temp_master, causing "Table does not exist" errors when Moodle accessed temporary tables (e.g. backup_ids_temp during activity duplication). Add UNION ALL with sqlite_temp_master, consistent with the existing pattern in get_tables(). See tracker: MDL-88218
erseco
force-pushed
the
MDL-88218-Add-experimental-SQLite-support-for-Moodle-WASM-environments
branch
from
June 5, 2026 20:12
1a24393 to
714f178
Compare
…r-Moodle-WASM-environments
…r-Moodle-WASM-environments
database_column_info::__construct() reads its fields via object property access, so the SQLite driver's fetch_columns() must pass an object like the pgsql and mysqli drivers do. Passing the raw array left every property (including ->name) null, which broke callers reading $column->name (e.g. theme_snap's events query produced 'SELECT e., e., ...' and a syntax error).
…r-Moodle-WASM-environments
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.
Reintroduces experimental SQLite support via PDO, intended for WASM-based and other constrained ephemeral runtimes.
pdo_moodle_databaseThis is not proposed as a production database backend. It targets portable demos, educational sandboxes, and local experimentation in WASM environments.
See tracker: MDL-88218