Repository navigation
SharePoint Online: fetch Site Pages by URL to support non-English sites - #4926
Open
Jan-Kazlouski-elastic wants to merge 4 commits into
Open
Jan-Kazlouski-elastic wants to merge 4 commits into
Jan-Kazlouski-elastic wants to merge 4 commits into
Conversation
There was a problem hiding this comment.
🟡 Changes recommended
The new SharePoint missing-library warnings bypass the injected logger and lose sync-job context, so they and their tests need to use client._logger.
1 open issue
What changed in this PR
This PR makes SharePoint Site Pages discovery independent of localized library titles, preventing non-English sites from silently syncing zero pages.
Changes:
- Fetch Online pages and page permissions by library URL, resolving the localized title for inherited permissions.
- Detect Server page libraries by URL and warn when Online libraries are missing.
- Update fixtures, add localization and URL-handling tests, and refresh two dependency notice versions.
| File | Description |
|---|---|
app/connectors_service/tests/sources/test_sharepoint_server.py |
Tests URL-based library detection with localized titles. |
app/connectors_service/tests/sources/test_sharepoint_online.py |
Tests URL escaping, title resolution, warnings, and inherited permissions. |
app/connectors_service/tests/sources/fixtures/sharepoint_online/fixture.py |
Updates page routes and pagination links to use GetList. |
app/connectors_service/NOTICE.txt |
Updates bracex and soupsieve version notices. |
app/connectors_service/connectors/sources/sharepoint/sharepoint_server/datasource.py |
Identifies page libraries by their root folder URL. |
app/connectors_service/connectors/sources/sharepoint/sharepoint_online/datasource.py |
Resolves the localized library title once for inherited permissions. |
app/connectors_service/connectors/sources/sharepoint/sharepoint_online/client.py |
Adds URL-based library access, title escaping, and missing-library warnings. |
Review effort: Balanced
| ) | ||
| return response.get("Title") or SITE_PAGES_LIST_NAME | ||
| except NotFound: | ||
| logger.warning( |
Jan-Kazlouski-elastic
requested review from
artem-shelkovnikov,
erikcurrin-elastic and
tara-elastic
November 16, 2026 07:13
Jan-Kazlouski-elastic
marked this pull request as ready for review
November 16, 2026 07:13
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.

Closes elastic/sdh-search#2024
Problem
Site pages were fetched via
GetByTitle('Site Pages'). SharePoint localizes that library title (e.g. "Pages du site" on French sites), so the call returned 404,site_pages()swallowed it, and the sync succeeded with 0 pages.Fix
/_api/web/GetList('<web path>/SitePages')for page fetch and page role assignments.GetByTitle), resolve the real library title viaGetList(...)?$select=Title(falls back to "Site Pages").Notes
SharePoint Server: the Site Pages library is now detected by its
/SitePagesroot folder URL instead ofTitle == "Site Pages"(permission lookups there already use the real list title).