Skip to content

Can't filter site list by upstream name #2788

Description

@morganestes

Problem

Site list options are inconsistent and return incorrect data.

Details

When I run org:site:list and filter by an upstream with known sites, it tells me there are none (at all! but that's a different problem).

$ terminus org:site:list <my-org> --upstream=<my-upstream-name>

 2026-03-03 17:41:36 UTC[+0000] [warning] This organization has no sites.
 ------ ---- ------ ----------- ------- --------- ------ ------------
  Name   ID   Plan   Framework   Owner   Created   Tags   Is Frozen?
 ------ ---- ------ ----------- ------- --------- ------ ------------

When I run the same command but use the UUID, it gives me the populated list as expected.

$ terminus org:site:list <my-org> --upstream=<my-upstream-id>

 ----------------------- -------------------------------------- ------- ----------- -------------------------------------- --------------------- ----------------------- ------------
  Name                    ID                                     Plan    Framework   Owner                                  Created               Tags                    Is Frozen?
 ----------------------- -------------------------------------- ------- ----------- -------------------------------------- --------------------- ----------------------- ------------
  cool-site-bro           e033e97e-6b51-4f80-be60-1d81e4e0164f   Basic   wordpress   b39a0711-d358-4fff-9866-f40ca76d2dd6   2022-12-19 17:00:09   rise_up,wise_up,eyes_up false
 ----------------------- -------------------------------------- ------- ----------- -------------------------------------- --------------------- ----------------------- ------------

The usage section of the command help says to use the UUID but the options says to use the name.

$ terminus help org:site:list

Usage:
...
  org:site:list <organization> --upstream=<upstream> Displays the list of sites associated with <organization> with the upstream having UUID <upstream>.
...

Options:
...
      --upstream[=UPSTREAM]  Upstream name to filter

Desired solution

I want the choice of using the name or the UUID, like I can with the organization (which allows name, label, or ID). Barring that, can we at least get some consistency in the command help?

This bug inconsistency was introduced in #1929.

Related tickets

#2069 #1860

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions