Feature #89426
openRemove stale broken links in tx_linkvalidator_link
0%
Description
If a page (or content element, or ...) is removed, the related broken links are not removed from tx_linkvalidator_link.
They are not displayed because only broken links of subpages of current page are displayed, so it is not a huge problem. But, eventually, this clutters up the tx_linkvalidator_link table.
Currently, there is no possibility to remove stale (no longer relevant) broken links except removing them manually from the db table.
Updated by Sybille Peters about 5 years ago
- Subject changed from Give possibility to remove stale broken links in tx_linkvalidator_link to Remove (or do not show) stale broken links in tx_linkvalidator_link
Updated by Riccardo De Contardi almost 5 years ago
- Status changed from New to Needs Feedback
Is this one still reproducible? Could you add an example?
I tried with the following test on 10.3.0-dev:
1) I created a new "Header" content element (ID=269)
2) on the header_link
field, I added a non-existent link: https://www.typo3.org/sidfhrthorteiheoprit
3) Info > linkvalidator > check links > the link is reported (external links)
4) on the database > table tx_linkvalidator_links contains the line:
uid | record_uid | record_pid | headline | field | table_name | link_title | url | url_response | last_check | link_type | needs_recheck |
---|---|---|---|---|---|---|---|---|---|---|---|
27 | 269 | 244 | header test | header_link | tt_content | NULL | https://www.typo3.org/sidfhrthorteiheoprit | {"valid":false,"errorParams":{"errorType":404,"exception":"Client error: `GET https:\/\/www.typo3.org\/sidfhrthorteiheoprit` resulted in a `404 Not Found` response:\n<!DOCTYPE html>\n<html lang=\"en-US\">\n<head>\n\n<meta charset=\"utf-8\">\n<!-- \n\tMaintained by the typo3.org team\n\n\tThis websit (truncated...)\n","message":"The requested url was not found (404)."}} | 1581633094 | external | 0 |
5) Delete the content element
6) Info > linkvalidator > check links (again) > now the broken external links reported are 0
7) on the database the row has been removed
Am I misinterpreting it? A different test is necessary?
Updated by Sybille Peters almost 5 years ago
Your test was perfect except in order to reproduce this, you must remove the page (not just the content).
Clarification: Before links are rechecked, linkvalidator removes all links of list of pages it is rechecking from tx_linkvalidator_links. However, if a page no longer exists, the corresponding broken links will never be removed from tx_linkvalidator_link. They will not show up in the list of broken links in the BE. But, eventually, the list of broken links will contain "stale" (no longer relevant) broken links and this will likely increase over time.
You can only see this if you look directly in the DB table.
Reproduce¶
- Create content with one or more broken links
- Check for broken links (in BE linkvalidator module or by using the scheduler task)
- Remove a page which contains content with broken links
- Check for broken links again
- Look in table tx_linkvalidator_link
Expected result¶
No records for deleted content in tx_linkvalidator_link
Actual result¶
tx_linkvalidator_link DB table constains records for deleted content.
Updated by Sybille Peters almost 5 years ago
- Subject changed from Remove (or do not show) stale broken links in tx_linkvalidator_link to Remove stale broken links in tx_linkvalidator_link
Updated by Sybille Peters almost 5 years ago
The title and description was wrong / misleading. I have corrected this.
Updated by Riccardo De Contardi almost 5 years ago
- Status changed from Needs Feedback to New
Updated by Oliver Hader about 2 years ago
- Sprint Focus deleted (
On Location Sprint)