google / google/site-kit-wp

Analytics settings offers a new account when the account list fails

Open
#13,306 0 comments 0 reactions 0 assignees View on GitHub
Module: Analytics P2 Type: Bug
Dominant language
JavaScript
Stars
1.4k
Forks
383
Avg merge
4d 14h
Merged PRs (30d)
77

Description

## Bug Description

When the Analytics account list fails to load, the settings screen shows an error line. Under the error, the screen shows the create account form, filled in with the site's details and ending with **Create Account**.

Any failure of the account list causes this: an outage at Google, a rate limit, an expired grant, or a lost connection.

The screen must say the account list failed to load, and offer a button to try again, with the account fields kept.

## Steps to reproduce

1. In Site Kit, go to **Settings > Connected Services > Analytics** and click **Edit**.
2. With Tweak (browser extension), set a `500` response for `.*analytics-4/data/account-summaries.*`, with `{"code":"internal_server_error","message":"Something went wrong.","data":{"status":500}}` as the response payload.
3. Reload the page.

## Screenshots

Image

## Additional Context

- Plugin Version: 1.185.0
- Asana Task: https://app.asana.com/1/8468971550303/project/1217014300014478/task/1217252529664988

---------------

_Do not alter or remove anything below. The following sections will be managed by moderators only._

## Acceptance criteria

*

## Implementation Brief

* [ ]

### Test Coverage

*

## QA Brief

*

## Changelog entry

*

Contributor guide

Open the contributing guide

Research direction

Start in Site Kit's Settings > Connected Services > Analytics > Edit flow and reproduce the failure by returning a 500 response for the analytics-4/data/account-summaries endpoint. Trace the account-list error state and verify that it explains the loading failure, offers a retry button, and preserves the account fields instead of showing Create Account.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript
Domain
analytics, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
58/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.