Skip to content

fix: skip SharePointHomeCacheList during SharePoint Online sync - #4306

Merged
Jan-Kazlouski-elastic merged 2 commits into
mainfrom
fix/1940-skip-sharepoint-home-cache-list
Jul 30, 2026
Merged

fix: skip SharePointHomeCacheList during SharePoint Online sync#4306
Jan-Kazlouski-elastic merged 2 commits into
mainfrom
fix/1940-skip-sharepoint-home-cache-list

Conversation

@Jan-Kazlouski-elastic

@Jan-Kazlouski-elastic Jan-Kazlouski-elastic commented Jul 30, 2026

Copy link
Copy Markdown
Contributor

Part of https://github.com/elastic/sdh-search/issues/1940

Skip the system list SharePointHomeCacheList by name during SharePoint Online sync. Graph can return this list; fetching its attachments via SharePoint REST returns Unauthorized and aborts the whole sync. Sync-rule exclusions cannot prevent this because they apply after fetch. This change skips the list early in site_lists() before DLS/item/attachment REST follow-ups.

Checklists

Pre-Review Checklist

  • this PR does NOT contain credentials of any kind, such as API keys or username/passwords (double check config.yml.example)
  • this PR has a meaningful title
  • this PR links to all relevant github issues that it fixes or partially addresses
  • if there is no GH issue, please create it. Each PR should have a link to an issue
  • this PR has a thorough description
  • Covered the changes with automated tests
  • Tested the changes locally
  • Added a label for each target release version (example: v7.13.2, v7.14.0, v8.0.0)
  • For bugfixes: backport safely to all minor branches still receiving patch releases
  • Considered corresponding documentation changes
  • Contributed any configuration settings changes to the configuration reference
  • if you added or changed Rich Configurable Fields for a Native Connector, you made a corresponding PR in Kibana

Changes Requiring Extra Attention

  • Security-related changes (encryption, TLS, SSRF, etc)
  • New external service dependencies added.

Related Pull Requests

Release Note

SharePoint Online connector now skips the system list SharePointHomeCacheList so syncs are not aborted by Unauthorized responses when fetching its attachments.

Made with Cursor

Graph can return this system list; fetching its attachments via REST
returns Unauthorized and aborts the whole sync. Skip it by name before
any list/item REST follow-ups.

Relates to elastic/sdh-search#1940

@erikcurrin-elastic erikcurrin-elastic left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice feature

@github-actions

Copy link
Copy Markdown

💔 Failed to create backport PR(s)

Status Branch Result
9.4 #4307
8.19 Commit could not be cherrypicked due to conflicts
9.5 #4308
9.3 #4309

Successful backport PRs will be merged automatically after passing CI.

To backport manually run:
backport --pr 4306 --autoMerge --autoMergeMethod squash

Jan-Kazlouski-elastic added a commit that referenced this pull request Jul 30, 2026
…#4306) (#4307)

Backports the following commits to 9.4:
- fix: skip SharePointHomeCacheList during SharePoint Online sync
(#4306)

Co-authored-by: Jan-Kazlouski-elastic <jan.kazlouski@elastic.co>
Jan-Kazlouski-elastic added a commit that referenced this pull request Jul 30, 2026
…#4306) (#4308)

Backports the following commits to 9.5:
- fix: skip SharePointHomeCacheList during SharePoint Online sync
(#4306)

Co-authored-by: Jan-Kazlouski-elastic <jan.kazlouski@elastic.co>
Jan-Kazlouski-elastic added a commit that referenced this pull request Jul 30, 2026
…#4306) (#4309)

Backports the following commits to 9.3:
- fix: skip SharePointHomeCacheList during SharePoint Online sync
(#4306)

Co-authored-by: Jan-Kazlouski-elastic <jan.kazlouski@elastic.co>
Jan-Kazlouski-elastic added a commit that referenced this pull request Jul 30, 2026
#4306) (#4310)

Backports the following commits to 8.19:
- fix: skip SharePointHomeCacheList during SharePoint Online sync
(#4306)

> **Manual backport.** The auto-backport could not cherry-pick cleanly
because on
> `8.19` the SharePoint Online source is still the monolithic
> `connectors/sources/sharepoint_online.py` rather than the refactored
> `sharepoint/sharepoint_online/` package used on `main`/`9.x`. The
change itself
> is identical (same skip-by-name logic and tests).

## Related Pull Requests

* #4306 — original PR (merged to `main`)
* #4307 — `[9.4]` backport
* #4308 — `[9.5]` backport
* #4309 — `[9.3]` backport


Made with [Cursor](https://cursor.com)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants