#52547 closed defect (bug) (fixed)
async loopback site health test fails on alternative setups
Reported by: | Levdbas | Owned by: | peterwilsoncc |
---|---|---|---|
Milestone: | 5.7 | Priority: | normal |
Severity: | normal | Version: | 5.7 |
Component: | Site Health | Keywords: | has-patch commit |
Focuses: | administration | Cc: |
Description
In changeset [49917] site_url()
was used to work with the new REST api tests.
This causes errors in alternative setups like Bedrock where site_url()
points to example.com/wp/ which causes an error on the front-end of the website.
Changing site_url()
to home_url()
fixes this issue.
Attachments (1)
Change History (10)
#1
@
4 years ago
- Component changed from General to Site Health
- Milestone changed from Awaiting Review to 5.7
#4
@
4 years ago
- Owner set to peterwilsoncc
- Resolution set to fixed
- Status changed from new to closed
In 50381:
#5
@
4 years ago
- Resolution fixed deleted
- Status changed from closed to reopened
Reopening per-discussion in #core-site-health. The intent of using site_url
was to more closely mimic how a cron request works. So we need to find a way to keep this close to testing loopback for cron, but not error out on subdirectory installs.
Per discussion with @peterwilsoncc, ( see above ), it looks like the best way to do this would be to make a POST
request to site_url( 'wp-cron.php' )
. Making this a POST
request allows us to quickly exit out of Cron without triggering any cron jobs which might error out since cron would have just been executed when Site Health itself is loaded.
This ticket was mentioned in PR #1016 on WordPress/wordpress-develop by peterwilsoncc.
4 years ago
#6
This ticket was mentioned in Slack in #core-site-health by peterwilsoncc. View the logs.
4 years ago
hellofromtonya commented on PR #1016:
4 years ago
#9
Merged with changeset https://core.trac.wordpress.org/changeset/50399
Thanks @Levdbas, I've uploaded 52547.diff which makes the change you suggested.
Manually tested on a sub-directory install locally and all seems good.