Premium Analytics: show File downloads only on WPCOM Simple sites#50732
Premium Analytics: show File downloads only on WPCOM Simple sites#50732chihsuan wants to merge 1 commit into
Conversation
|
Are you an Automattician? Please test your changes on all WordPress.com environments to help mitigate accidental explosions.
Interested in more tips and information?
|
|
Thank you for your PR! When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:
This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖 Follow this PR Review Process:
If you have questions about anything, reach out in #jetpack-developers for guidance! |
Code Coverage SummaryCoverage changed in 2 files.
1 file is newly checked for coverage.
|
82112b1 to
6d8139a
Compare
6d8139a to
4eae208
Compare
da23ee4 to
e6c62e0
Compare
louwie17
left a comment
There was a problem hiding this comment.
This looks good and tested well both on simple and self hosted.
Fixes WOOA7S-1717
Fixes WOOA7S-1709
Proposed changes
File download tracking is provided only for WordPress.com Simple sites. The endpoint returns 404 elsewhere, but Premium Analytics registered and rendered the widget on every site.
jpa/file-downloadsas unsupported outside WordPress.com Simple./reports/downloadsroute outside WordPress.com Simple.Related product discussion/links
Does this pull request change what data or activity we track or use?
No.
Testing instructions
Self-hosted Jetpack or another non-Simple site
jetpack build packages/premium-analytics --deps.stats/file-downloadsrequests are made.admin.php?page=jetpack-premium-analytics-wp-admin&p=%2Freports%2Fdownloadsand confirm it redirects to the dashboard.Customizemode and remove it.WordPress.com Simple
On a sandbox, fetch this branch's build:
bin/jetpack-downloader test jetpack-mu-wpcom-plugin add/wooa7s-1717-hide-file-downloads-on-self-hosted.Sandbox the test site and
public-api.wordpress.comin/etc/hosts.Open Premium Analytics on a Simple site with the
jetpack-premium-analyticssticker. To add the sticker, run this on the sandbox:Confirm File downloads remains in the Traffic default and widget picker.
Confirm its request returns data and
/reports/downloadsstill renders.