Detailed Page Stats result in errors when using language plugins
- Dominant language
- JavaScript
- Stars
- 1.4k
- Forks
- 384
- Avg merge
- 4d 14h
- Merged PRs (30d)
- 77
Description
## Bug Description
As reported in [the WordPress support forums](https://wordpress.org/support/topic/sitekit-disconnecting-spontaneusly/#post-14095007) users of TranslatePress and other language plugins that store language variations in the database as opposed to creating new language specific pages and posts will encounter various "no data available notices". One example notice is below:
```
No data available yet
There is no data available for this content yet. This could be because it was recently created or because nobody has accessed it so far.
```
These notices appear when using the Site Kit admin toolbar or when accessing a "Detailed Page Stats" URL. The error as appears on the "Detailed Page Stats" page is below:
```
It looks like the URL https://mysite.com.com/de/slug is not part of this site, therefore there is no data available to display
```
Many of these language plugins create variations of a homepage such as mysite.com/**_de_**/slug, with no individual post or page for this language variation.
[Example video](https://recordit.co/K2r8fdoNbi) demonstrating language variation
If possible revert to the original URL for identified language plugins for reporting purposes.
## Steps to reproduce
1. Install TranslatePress
2. Activate a language variation and apply a path associated with that language
3. View the stats for this URL using the Site Kit toolbar
4. View the stats for this URL's language variation using the Site Kit toolbar
## Additional Context
- Notices can appear with the Search Console stats using the admin toolbar
- Each language specific URL will include the laguage path listed in their "Canonical" URL when checking the site source code
---------------
_Do not alter or remove anything below. The following sections will be managed by moderators only._
## Acceptance criteria
*
## Implementation Brief
*
### Test Coverage
*
### Visual Regression Changes
*
## QA Brief
*
## Changelog entry
*
Contributor guide
Research direction
Start by reproducing the issue with TranslatePress, using the Site Kit admin toolbar and the Detailed Page Stats URL for a language variation. Trace how the language-specific URL is handled against the original URL; done means the original URL is used for reporting and the no-data notices and invalid-site error no longer appear.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, wordpress
- Domain
- analytics, internationalization, web-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100