Conversation
Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Previously, the DID was cached in the AJAX installation handler. This meant that only one DID could be cached, even during a bulk install (such as via WP-CLI). Now, the DID is cached when its artifact's URL matches the package currently being passed for installation. Additionally, the cached DID is cleared after the package has been installed to prevent contamination. Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Previously, signature verification was only applied in the Updater class, whose setup is somewhat tightly coupled to installing in an admin context. Now, signature verification has been moved to general functions so that it can be used in various contexts. Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
This excludes `verify-checksums` because: 1. This currently depends on the WordPress.org API. 2. Each file in a plugin or theme has its own checksum, which is not part of the FAIR protocol. Future support remains uncertain. Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Repeated testing showed failures to rename the downloaded package correctly. This occurred at times for a package whether it used a release asset or not. While the exact cause hasn't been determined yet, bumping the priority resolved the issue. Re-testing with the previous priority of 10, and possible investigation to find the cause, is welcome. Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Member
Author
|
Some DIDs to test with:
|
Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
Signed-off-by: costdev <79332690+costdev@users.noreply.github.com>
afragen
approved these changes
Oct 3, 2025
afragen
reviewed
Oct 4, 2025
|
@costdev If there's anything we could improve on the WP-CLI side to make this more seamless, please let me know :-) |
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.
This PR adds support for the following
wp plugin <subcommand> <did>commands.Currently supported commands
The following commands are supported:
For those commands which support multiple values, a mixture of DIDs and slugs (for non-FAIR plugins) is also supported by this PR.
Currently NOT supported commands
The following commands are not currently supported:
This relies on the wordpress.org API, and each file in a package has its own checksum which isn't part of the FAIR protocol.
Additional changes
The PR also includes refactoring some of the plugin to facilitate WP-CLI support:
Packages\Adminnamespace to thePackagesnamespace, as this is now used in more than just the admin context.