Opened 2 years ago
Last modified 2 years ago
#56751 new enhancement
Add wp_get_environment_type() to update.php checks (core, plugins, themes)
Reported by: | johnjamesjacoby | Owned by: | |
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | normal | Version: | 5.5 |
Component: | Upgrade/Install | Keywords: | 2nd-opinion needs-patch needs-docs |
Focuses: | Cc: |
Description
While researching #meta6511 I noticed when WordPress checks for updates to itself, plugins, or themes, it does not send to api.wordpress.org
what type of environment that it is:
array( 'local', 'development', 'staging', 'production', )
These are filterable, too.
A few community members have questioned (in that ticket, Slack, Twitter...) whether non-production sites have the potential to influence installation counts.
If WordPress sent the environment type, it could be aggregated over time and used later to more accurately respond to that question, perhaps even reported back if it is eventually deemed useful or actionable.
I can imagine it being useful to myself, so I'm making this ticket to suggest it.
I am choosing version 5.5 because that is when environment types were added.
Change History (2)
#2
@
2 years ago
Strictly speaking, generally, local development sites should already be excluded through some heuristics in the pre-filter for the stat aggregations.
Sending the environment type with update API requests would however make that easier, as it could discard any non-production sites much earlier in the filtering.
I would be shocked if non-production environment type values account for more than a tiny fraction of a percentage point of sites in the aggregated stats though.
No meta ticket required at this point in time, if the environment type gets added to the payload that's sent, open a meta ticket at that point in time for API implementation.
It might be better to open this is #meta as it's an Plugins API related and not strictly speaking core. Pinging @dd32