Repository navigation
fix(cloud_federation_api): ensure federated_invites table always exists - #66686
Merged
Merged
Conversation
max-nextcloud
requested review from
Altahrim and
CarlSchwan
and removed request for
a team
November 17, 2026 09:55
max-nextcloud
force-pushed
the
fix/federated_invites_table
branch
from
November 17, 2026 09:57
9279c9d to
c7927be
Compare
max-nextcloud
requested review from
ArtificialOwl,
icewind1991 and
mickenordin
November 17, 2026 09:58
Antreesy
approved these changes
Nov 17, 2026
| declare(strict_types=1); | ||
|
|
||
| /** | ||
| * SPDX-FileCopyrightText: 2025 Nextcloud GmbH and Nextcloud contributors |
Contributor
There was a problem hiding this comment.
2026, or it's a copy of previously existing migration?
Looks very much like files in https://github.com/nextcloud/contacts/tree/main/lib/Migration, maybe leave a comment that contacts one is the source of truth (the one that should be a correct migration), and this is a backup copy in case something went wrong?
mickenordin
approved these changes
Nov 17, 2026
Contributor
Author
|
/backport! to stable35 please |
Add another migration to create the table again on instances where it was removed. If the table already exists the migration does nothing. The table was originally created by this app Then responsibility was moved to the contacts app. For some time there was a repair job in this app that removed the table. That job could cause problems removing the table after the contacts app created it. So the cleanup job was removed. However there are still some instances without the table as the cleanup job removed it. This leads to warnings as `occ db:schema:check` expects the table to exist. It also leads to an inconsistent schema between instances depending on wether the repair job ran. Signed-off-by: Max <max@nextcloud.com>
max-nextcloud
force-pushed
the
fix/federated_invites_table
branch
from
November 18, 2026 13:39
c7927be to
69cdad5
Compare
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Add another migration to create the table again on instances where it was removed.
The table was originally created by this app
Then responsibility was moved to the contacts app.
For some time there was a repair job in this app that removed the table.
That job could cause problems removing the table after the contacts app created it.
So the cleanup job was removed.
However there are still some instances without the table as the cleanup job removed it.
This leads to warnings as
occ db:schema:checkexpects the table to exist.It also leads to an inconsistent schema between instances depending on wether the repair job ran.