Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Jan 19, 2026

The wp package list command checks for updates by making network requests to package repositories, which can fail due to authentication issues with GitHub/Composer or rate limiting, and is slow when only local package information is needed.

Changes

  • Added --skip-update-check flag to wp package list command

    • Skips find_latest_package() calls when flag is set
    • Sets update field to "none" and update_version to empty string
    • Maintains backward compatibility (default behavior unchanged)
  • Updated command documentation with flag description and usage example

  • Added Behat test verifying flag functionality

Usage

# Fast, local-only listing without update checks or auth issues
wp package list --skip-update-check

# Output shows packages with update status as "none"
+-----------------------+------------------+----------+--------+----------------+
| name                  | authors          | version  | update | update_version |
+-----------------------+------------------+----------+--------+----------------+
| wp-cli/server-command | Daniel Bachhuber | dev-main | none   |                |
+-----------------------+------------------+----------+--------+----------------+

Warning

Firewall rules blocked me from connecting to one or more addresses (expand for details)

I tried to connect to the following addresses, but was blocked by firewall rules:

  • api.wordpress.org
    • Triggering command: /usr/bin/curl curl -s REDACTED (dns block)
  • downloads.wordpress.org
    • Triggering command: /usr/bin/curl curl -sSfL REDACTED (dns block)
  • gitlab.com
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install REDACTED (dns block)
  • https://api.github.com/repos/https://gitlab.com/gitlab-examples/php.git
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install REDACTED (http block)
  • https://api.github.com/repos/non-existent-git-user-asdfasdf/non-existent-git-repo-asdfasdf
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install REDACTED wp-cli/bin/wp pull.rebase rgo/bin/which (http block)
  • https://api.github.com/repos/wp-cli-test/private-repository
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install REDACTED d asp_tags=Off' '-d short_open_tag=Off' '-d error_reporting=E_ALL' '-n' '-l' './src/WP_CLI/Packash main k/package-command/package-command/vendor/bin/sh (http block)
  • wp-cli.org
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install wp-cli/restful tup_errors=0' '--n ame t[bot] (dns block)
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install google-sitemap-generator-cli.zip it} (dns block)
    • Triggering command: /usr/bin/php /usr/bin/php /home/REDACTED/work/package-command/package-command/vendor/wp-cli/wp-cli/bin/../php/boot-fs.php package install path-command (dns block)

If you need me to access, download, or install something from one of these locations, you can either:

Original prompt

This section details on the original issue you should resolve

<issue_title>Add option to package list to access locally only and not check for updates.</issue_title>
<issue_description>See #59 (comment)

An option to not bother checking for updates to packages would be useful to avoid GITHUB_TOKEN and Composer auth issues like the above and is sometimes all one wants to know and would also be much much faster.

Might also consider combining with or having some local caching of update info.</issue_description>

<agent_instructions>Add a new --skip-update-check flag to wp package list</agent_instructions>

Comments on the Issue (you are @copilot in this section)


💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

Co-authored-by: swissspidy <841956+swissspidy@users.noreply.github.com>
Copilot AI changed the title [WIP] Add skip update check flag to package list Add --skip-update-check flag to wp package list Jan 19, 2026
Copilot AI requested a review from swissspidy January 19, 2026 09:52
@codecov
Copy link

codecov bot commented Jan 19, 2026

Codecov Report

❌ Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
src/Package_Command.php 0.00% 4 Missing ⚠️

📢 Thoughts on this report? Let us know!

@swissspidy swissspidy added this to the 2.6.2 milestone Jan 19, 2026
@swissspidy swissspidy marked this pull request as ready for review January 19, 2026 11:34
@swissspidy swissspidy requested a review from a team as a code owner January 19, 2026 11:34
@swissspidy swissspidy merged commit 18effbe into main Jan 19, 2026
52 of 53 checks passed
@swissspidy swissspidy deleted the copilot/add-skip-update-check-flag branch January 19, 2026 13:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add option to package list to access locally only and not check for updates.

2 participants