`--format` argument fails to change output of command

Open
#47 11 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
68/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Quiet
Tech stack
php
Domain
cli

Research direction

Start at the implementation or entry point for wp plugin verify-checksums and trace how its --format option is passed to output handling. Reproduce the six commands listed, then verify that each supported format changes the output while checksum verification remains correct.

Written by the indexing model from the issue text.

Description

command:plugin-verify-checksums
Summary

While trying to use the --format argument with the wp plugin verify-checksums commands I found the output wouldn't change. I've tried all format options listed and none of them change the format outputted.

Steps to reproduce
  1. Run command ‘wp plugin verify-checksums --all’
  2. Run command ‘wp plugin verify-checksums --all --format=json’
  3. Run command ‘wp plugin verify-checksums --all --format=csv’
  4. Run command ‘wp plugin verify-checksums --all --format=count’
  5. Run command ‘wp plugin verify-checksums --all --format=yaml’
  6. Run command ‘wp plugin verify-checksums --all --format=table’
  7. Observe the output of all six commands is identical.
Environment
  • WP-CLI 1.5.1
Results and impacts

Severity – Moderate

Expected Results: Output in the format specified in the command line argument

Actual Results: The output does not follow the format specified.

This command has been incredibly useful to me in one off scenarios, but I can't use it effectively in scripts and Unix pipes without the option of a clean output format.

Dominant language
PHP
Stars
33
Forks
27
Avg merge
5m
Merged PRs (30d)
1

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Similar issues

More PHP issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.