Skip to content

[stable34] fix(files): Continue scanning after StorageInvalidException - #66292

Merged
DerDreschner merged 1 commit into
stable34from
backport/65585/stable34
Nov 5, 2026
Merged

DerDreschner merged 1 commit into
stable34from
backport/65585/stable34

Conversation

@backportbot

@backportbot backportbot Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

Backport of #65585

Warning, This backport's changes differ from the original and might be incomplete ⚠️

Todo

  • Review and resolve any conflicts
  • Review and verify the backported changes
  • Amend HEAD commit to remove the line stating to skip CI

Learn more about backports at https://docs.nextcloud.com/server/stable/go.php?to=developer-backports.

When a federated share was already removed on the remote end, accessing it triggers a `StorageInvalidException` after the share and its mount are removed locally. When running `occ files:scan`, this exception isn't caught by the scanner and aborts the scan of all remaining mounts of that user, printing a stack trace instead. This can be pretty frustrating on larger instances with many federated shares.

To avoid that, the `StorageInvalidException` is now caught and handled the same way as the `StorageNotAvailableException`: log it as an error, report it through the `StorageNotAvailable` hook and continue with the next mount.

Assisted-by: ClaudeCode:claude-opus-5-5
Signed-off-by: David Dreschner <david.dreschner@nextcloud.com>
@DerDreschner
DerDreschner force-pushed the backport/65585/stable34 branch from a0591c2 to d9682f9 Compare November 4, 2026 13:45
@DerDreschner
DerDreschner marked this pull request as ready for review November 4, 2026 13:47
@DerDreschner
DerDreschner requested review from a team as code owners November 4, 2026 13:47
@DerDreschner
DerDreschner requested review from GhassenKefi, pabzm and provokateurin and removed request for a team November 4, 2026 13:47
@DerDreschner
DerDreschner merged commit 86f0be8 into stable34 Nov 5, 2026
214 of 227 checks passed
@DerDreschner
DerDreschner deleted the backport/65585/stable34 branch November 5, 2026 03:58
@github-actions

Copy link
Copy Markdown
Contributor

This pull request has been automatically locked because it has been closed for more than 7 days. As we do not monitor merged or closed pull requests, we are locking this pull request to prevent further comments from getting lost in the noise.
If you discovered any issues with this pull request, please open a new issue instead. In case you want to discuss this pull request or have further questions, please use our forum: https://help.nextcloud.com

@github-actions github-actions Bot locked as resolved and limited conversation to collaborators Nov 13, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants