Project

General

Profile

Actions

Bug #84887

closed

pageTSconfig subpage level is not considered in Linkvalidator

Added by Sybille Peters over 6 years ago. Updated about 3 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Linkvalidator
Start date:
2018-04-27
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
8
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Currently, linkvalidator is highly configurable, the settings can be applied via TSconfig for a page / user / group.

When checking links however, only the page TSconfig of the current start page is considered. Different page TSconfig on a subpage is not considered. It does not override the settings.

Steps to Reproduce

  1. Create 2 pages with 1 tt_content element each, with a broken link each in in tt_content.header and tt_content.bodytext. I page is parent of the other
  2. Set the TSconfig on the first page to scan bodytext and header
  3. Set the TSconfig of the child page to only scan bodytext
  4. Start "Check links" from the parent page and view report
  5. Start "Check links" from the child page and view report

Expected result

Get same number of broken links for child page: 1 (only bodytext)

Actual result

If "Check links" is started on child page, the result is correct.

If "Check links" is started on parent page, the result is 2 links for child page (not correct)

Solution

Either:

  • keep current behaviour and document this (I think having a different configuration on a subpage is highly unlikely to ever be required)
  • change behaviour to check for configuration on subpages
Actions #1

Updated by Sybille Peters over 6 years ago

  • Subject changed from pageTSconfig subpage level is not considered to pageTSconfig subpage level is not considered in Linkvalidator
Actions #2

Updated by Susanne Moog over 6 years ago

  • Target version changed from 9.3 to 9.4
Actions #3

Updated by Susanne Moog about 6 years ago

  • Target version changed from 9.4 to Candidate for patchlevel
Actions #4

Updated by Sybille Peters about 5 years ago

  • Description updated (diff)
Actions #5

Updated by Benni Mack almost 5 years ago

  • Status changed from New to Needs Feedback

Hey Sybille,

can you share your PageTS?

Actions #6

Updated by Oliver Bartsch about 4 years ago

Hi Sybille,

I had a look into this. It's currently not possible by design as the LinkAnalyzer gets initialised only once with the page TSconfig of the currently selected page and then traverses over all configured searchFields (table=>fields pairs) and tries to find broken links on all relevant pages (current page and subpages respecting configured depth) matching the table=>fields pairs.

To provide this functionality we had to change the LinkAnalyzer so that we traverse the pages list, get the TSconfig for the page and afterwards traverse over the searchFields for every single page. Also keep in mind that we then have to deal with a special case as pages itself is usually included in the searchFields which may need a different lookup then. In my opinion this may have a huge performance impact for generating results on root pages with hundreds of sub pages which all must be evaluated individually.

As you already said, it's very unlikely that this is a real use-case as one can still use different configurations by running the analyzation on the desired pages directly. I think we should document this properly and close this issue. What do you think?

Actions #7

Updated by Sybille Peters about 4 years ago

@Oliver, I would also opt to not make it more complicated. Especially, if it comes with a performance impact.

I personally think the configuration can be made globally for entire installation or per site, so we would not need to override the configuration on a subpage.

I think it just needs to be made clear in the docs. I would opt to check that and possibly add it there.

P.S. Thanks for taking care of these issues :)

Actions #8

Updated by Sybille Peters about 4 years ago

  • Status changed from Needs Feedback to New
Actions #9

Updated by Sybille Peters over 3 years ago

  • Assignee deleted (Sybille Peters)
Actions #10

Updated by Gerrit Code Review over 3 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/69407

Actions #11

Updated by Gerrit Code Review over 3 years ago

Patch set 1 for branch 10.4 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/69376

Actions #12

Updated by Gerrit Code Review over 3 years ago

Patch set 1 for branch 9.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/69377

Actions #13

Updated by Oliver Bartsch over 3 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #14

Updated by Benni Mack about 3 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF