Skip to content

fix(installer): re-enable version-incompatible apps after appstore update#60591

Draft
miaulalala wants to merge 1 commit into
masterfrom
fix/installer-reenable-disabled-app-after-update
Draft

fix(installer): re-enable version-incompatible apps after appstore update#60591
miaulalala wants to merge 1 commit into
masterfrom
fix/installer-reenable-disabled-app-after-update

Conversation

@miaulalala
Copy link
Copy Markdown
Contributor

Summary

  • When a Nextcloud server is upgraded to a new major version, apps incompatible with the old version range are automatically disabled. Updating such an app via the web UI or occ app:update would upgrade the files but leave the app disabled, requiring a manual re-enable or reinstall.
  • updateAppstoreApp() now checks whether the app was disabled due to version incompatibility before downloading the update. After a successful upgradeApp(), if those conditions were true, enableApp() is called automatically.
  • Adds debug logging to previously-silent return false paths in isUpdateAvailable() (git-installed app, no newer version, app not in store) — this was causing update failures to appear as "keine Hinweise" (no hints) in debug logs.

Context

Reported in nextcloud/files_mindmap#269 — users upgrading from NC 31 to NC 32+ had files_mindmap auto-disabled during the server upgrade (old version declared max-version="31"). Clicking "Update" in the web UI downloaded the new compatible release but did not re-enable the app, so it remained invisible/broken until manually re-enabled.

cc @AndyScherzinger

Test plan

  • New unit tests in tests/lib/InstallerTest.php cover the four cases: re-enable on incompatible-disabled, no re-enable on compatible-disabled (manually disabled), no re-enable on already-enabled, no re-enable when upgrade itself fails
  • Manual test: install an app with max-version below current NC, trigger server upgrade to auto-disable it, then update via web UI and confirm the app is re-enabled
  • Check debug log output now shows specific reason when isUpdateAvailable() returns false

🤖 Generated with Claude Code

@miaulalala miaulalala self-assigned this May 19, 2026
@miaulalala miaulalala added this to the Nextcloud 35 milestone May 19, 2026
@miaulalala miaulalala force-pushed the fix/installer-reenable-disabled-app-after-update branch 2 times, most recently from e0eac7b to 2503f7a Compare May 19, 2026 21:35
…pdate

When a Nextcloud server is upgraded to a new major version, apps incompatible
with the old version range are automatically disabled. Previously, updating
such an app via the web UI (or occ app:update) would download and upgrade the
app files but leave the app disabled, requiring a manual re-enable or
reinstall.

updateAppstoreApp() now checks whether the app was disabled due to version
incompatibility before downloading the update. After a successful upgradeApp(),
if those conditions were true, enableApp() is called automatically.

Also adds debug logging to previously-silent return paths in
isUpdateAvailable() (git-installed apps, no newer version found, app not in
store), making update failures diagnosable from debug logs.

Signed-off-by: Anna Larch <anna@nextcloud.com>
@miaulalala miaulalala force-pushed the fix/installer-reenable-disabled-app-after-update branch from 2503f7a to ce489a2 Compare May 19, 2026 21:39
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.

1 participant