Repository navigation
mendelu: disallow heavy Discovery facet/pagination browse URLs (cherry-pick upstream 9b03e82a14) - #1650
Open
Kasinhou wants to merge 1 commit into
Open
mendelu: disallow heavy Discovery facet/pagination browse URLs (cherry-pick upstream 9b03e82a14)#1650Kasinhou wants to merge 1 commit into
Kasinhou wants to merge 1 commit into
Conversation
Cherry-pick of upstream DSpace/dspace-angular 9b03e82. On 8.x+ the community landing page renders the search section on the bare /communities/<uuid> route (default child route), so its pagination is emitted as /communities/<uuid>?spc.page=N - not covered by the existing /communities/*/search or facet rules. Also blocks /collections/*?f. Not applied to 7.x branches: there the community page has no such route, so ?spc.page is never generated. Refs dataquest-dev/dspace-customers#1085 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Cherry-pick of upstream
DSpace/dspace-angular@9b03e82a14— adds two directives to theUser-agent: *block:Why mendelu (and why not the 7.x branches)
mendelu is on 9.1.0. On 8.x+ the community landing page renders the search section on the bare
/communities/<uuid>route (it's the default empty-path child route →ComcolSearchSectionComponent, paginationIdspc). So its pagination is emitted as/communities/<uuid>?spc.page=N, which the existing rules do not cover:Disallow: /communities/*/searchneeds the/searchsegment (absent here)Disallow: /*?f.//*&f.only match facet params (f.), notspc.pageSo this rule adds genuinely new coverage on 9.x. (
/collections/*?fis largely redundant with the existing/*?f., kept only for parity with upstream/jcu.)This is not applied to the 7.x customer branches (TUL, zcu-data, zcu-pub, lindat, vsb-tuo, sav, uk): there the community page has a separate
/communities/<uuid>/searchroute (no default search on the landing URL), so?spc.pageis never generated and the rule would be a no-op. Verified viacommunity-page.component.html(9.x has<router-outlet>, 7.x does not) andcommunity-page-routes.ts(9.x haspath: '' → ComcolSearchSectionComponent).jcu already has these rules, so it is unchanged.
Refs dataquest-dev/dspace-customers#1085
🤖 Generated with Claude Code