Skip to content

Only show active stores for app dev#7500

Open
dmerand wants to merge 1 commit intomainfrom
donald/list-app-dev-stores-store-status-filter
Open

Only show active stores for app dev#7500
dmerand wants to merge 1 commit intomainfrom
donald/list-app-dev-stores-store-status-filter

Conversation

@dmerand
Copy link
Copy Markdown
Contributor

@dmerand dmerand commented May 8, 2026

What

Filter app dev store selection to active app development stores in Business Platform.

This updates the dev-store list query to require STORE_STATUS=ACTIVE, regenerates the query artifact, and adds coverage for the request shape and empty-result behavior.

Why

app dev --reset can surface deleted or inactive app dev stores because the CLI only filters by STORE_TYPE=app_development today.

That makes it possible to reselect stores that the CLI should no longer treat as valid for app dev flows.

How

Add STORE_STATUS=ACTIVE to ListAppDevStores, matching the filter pattern already used by Dev Dashboard for app dev stores.

Keep explicit domain lookup (storeByDomain) unchanged in this PR because that path is shared by mixed store-type flows. Leave a small helper and breadcrumb there so a narrower follow-up can add the same status filter for APP_DEVELOPMENT lookups with dedicated coverage.

Testing

Run shopify app dev for an app linked to an organization that has inactive or deleted app dev stores and confirm the flow only lists active app dev stores.

Here's an after/before:

Screenshot 2026-05-08 at 10.43.08 AM.png

Copy link
Copy Markdown
Contributor Author

dmerand commented May 8, 2026

This stack of pull requests is managed by Graphite. Learn more about stacking.

@github-actions github-actions Bot added the no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users. label May 8, 2026
@dmerand dmerand marked this pull request as ready for review May 8, 2026 14:52
@dmerand dmerand requested a review from a team as a code owner May 8, 2026 14:52
Copilot AI review requested due to automatic review settings May 8, 2026 14:52
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Filters the shopify app dev store-selection list to only include active app development stores by tightening the Business Platform query used to fetch dev stores.

Changes:

  • Update ListAppDevStores GraphQL query to require STORE_STATUS=ACTIVE in addition to STORE_TYPE=app_development.
  • Regenerate the list_app_dev_stores generated artifact to match the updated query shape (filters list).
  • Add unit tests covering the request shape (including the embedded filter AST) and empty-result behavior for devStoresForOrg.

Reviewed changes

Copilot reviewed 3 out of 4 changed files in this pull request and generated no comments.

File Description
packages/app/src/cli/utilities/developer-platform-client/app-management-client.ts Uses a small helper for storeByDomain filters; leaves status filtering scoped to ListAppDevStores as described.
packages/app/src/cli/utilities/developer-platform-client/app-management-client.test.ts Adds coverage for devStoresForOrg request shape (including STORE_STATUS=ACTIVE) and empty results.
packages/app/src/cli/api/graphql/business-platform-organizations/queries/list_app_dev_stores.graphql Adds STORE_STATUS=ACTIVE filter to the dev-stores list query.
packages/app/src/cli/api/graphql/business-platform-organizations/generated/list_app_dev_stores.ts Regenerated query artifact reflecting filters as a list with both required filters.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Copy link
Copy Markdown
Contributor Author

dmerand commented May 8, 2026

/snapit

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 8, 2026

🫰✨ Thanks @dmerand! Your snapshot has been published to npm.

Test the snapshot by installing your package globally:

pnpm i -g --@shopify:registry=https://registry.npmjs.org @shopify/cli@0.0.0-snapshot-20260508150036

Caution

After installing, validate the version by running shopify version in your terminal.
If the versions don't match, you might have multiple global instances installed.
Use which shopify to find out which one you are running and uninstall it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

no-changelog This PR doesn't include a changeset entry. Is an internal only change not relevant to end users.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants