-
Notifications
You must be signed in to change notification settings - Fork 66
Update SQLite plugin to 2.2.3 and enable new driver #1506
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
2ac4e0e
Update SQLite plugin to 2.2.0 and enable new driver
wojtekn d6b934c
Set constant earlier in the flow
wojtekn 6391677
Remove unnecessary change
wojtekn 8e8e528
Update SQLite plugin version to latest 2.2.2
wojtekn 48bf68b
Enable AST driver for sqlite CLI calls
wojtekn 224cae3
Merge branch 'trunk' into update/sqlite-plugin-to-2.2.0
wojtekn 9a91b9b
Update SQLite driver to 2.2.3
wojtekn File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -380,7 +380,9 @@ async function initWordPress( php: PHP, wordPressVersion: string, vfsDocumentRoo | |
| initializeDefaultDatabase = true; | ||
| } | ||
|
|
||
| const wpConfigConsts = {}; | ||
| const wpConfigConsts = { | ||
| WP_SQLITE_AST_DRIVER: true, | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We set the constant to enable the new driver for the site's WP admin and frontend. |
||
| }; | ||
|
|
||
| if ( wordPressVersion !== 'user-provided' ) { | ||
| wpConfigConsts[ 'WP_AUTO_UPDATE_CORE' ] = wordPressVersion === 'latest'; | ||
|
|
||
Oops, something went wrong.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We set the parameter to enable the AST driver for CLI actions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We probably won't add more commands, but I wonder if we should
opt-into use the AST driver more broadly. Like enable it by default, or auto-append the parameter in the wp-cli-process, similarly to how we increase the timeout:studio/src/lib/wp-cli-process.ts
Lines 67 to 70 in 48bf68b
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We could, but we should remove this parameter as soon as the SQLite driver enables it by default. What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Then, let's leave it as it is. There is no risk that we'll introduce more SQLite commands and forget to add the parameter in the meantime. 👍