site-kit-wp icon indicating copy to clipboard operation
site-kit-wp copied to clipboard

AdSense dash not showing up for newly enabled site

Open OisinOConnor opened this issue 7 years ago • 7 comments

Bug Description

When there are ads serving (showing data in the main dashboard), the AdSense tab is still showing "we're getting your site ready for ads" instead of stats dashboard.

Steps to reproduce

Set up AdSense with an existing account with low traffic.

Expected behavior

The AdSense dashboard showing up.

Screenshots

Additional Context

With newly added sites.

N/A

N/A

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

Changelog entry

  • Ensure that Site Kit dashboard informs the user if there is an issue with the AdSense account, rather than showing empty AdSense stats.

Acceptance criteria

  • Main dashboard and product subreport should reflect the account state in a coordinated manner.
    • If there are AdSense earnings data available, it should be shown in both the main dashboard and the subreport. (in this case, as soon as ad impressions are available via API, stop showing the "we're getting your site ready for ads" notice in the subreport)
    • If there is an issue with the account (e.g. approval state, user input required), users should be notified in both the main dashboard and the subreport without delay b/w the two.

Implementation Brief

When setting up AdSense with an account pending review, Earnings in site kit dashboard show 0 values while AdSense dashboard renders appropriate message.

The same way that <AdSenseDashboardWidget /> has the logic in place to render <AdSenseInProcessStatus /> when zeroData is true, we need to add this logic to <DashboardEarnings /> to render <AdSenseInProcessStatus /> when there is no data. This should solve the discrepancy between both components, once we get data from AdSense they would both show earnings.

OisinOConnor avatar Jul 01 '19 14:07 OisinOConnor

In the main Site Kit dashboard it does display the basic AdSense dashboard: LQ24wq2E90e

Clicking on the "Adsense" tab from the Site Kit panel results in the below: vOb7w9FWe9

jamesozzie avatar Jul 02 '19 09:07 jamesozzie

@lucymtc could you work on an implementation brief for this one?

bjackson27 avatar Jul 09 '19 17:07 bjackson27

Noting for the team that @lucymtc is OOO today (Jul 10) but can pick this up tomorrow, no problem (Jul 11). Thanks!

lilybonney avatar Jul 10 '19 11:07 lilybonney

Implementation brief ready for review

lucymtc avatar Jul 11 '19 09:07 lucymtc

@lucymtc would you please add a label for your estimate and then move it to the Engineering board? Thank you!

aaemnnosttv avatar Jul 11 '19 17:07 aaemnnosttv

@felixarntz @adamsilverstein as it will be difficult to QA this ticket if you don't have a newly AdSense account I am adding link to screen recording with my testing https://drive.google.com/file/d/1iEaGK7MTDGefzKT5ur8hmu-j8DWrtGqy/view?usp=sharing Data is shown in the AdSense page as soon as impressions are higher than 0, as well as in the main dashboard.

lucymtc avatar Jul 17 '19 11:07 lucymtc

verified the AdSense module shows a CTA on the Site Kit Dashboard when the data is empty:

image

Once there is data, the section shows correctly:

image

QA passes, moving to Approval.

adamsilverstein avatar Jul 17 '19 21:07 adamsilverstein