Skip to content

[BUG] Class can not be instantiated during app installation #320

Description

@rubenvdlinde

Beschrijving

When trying to install the LaunchPad app from the Nextcloud app store, the installation fails during the request.

The error message shown by Nextcloud is:

"An error occurred during the request. Cannot proceed.
Could not resolve OCA\LaunchPad\Migration\Version001000Date20240101000000! Class can not be instantiated"

It looks like Nextcloud tries to load the migration class under the namespace OCA\LaunchPad\Migration, but the migration class may not be instantiable or the namespace/app id does not match the actual app code.

Stappen om te reproduceren

  1. Open Nextcloud as an administrator.
  2. Go to Apps.
  3. Search for "LaunchPad".
  4. Click install.
  5. The installation fails with the class instantiation error.

Verwacht gedrag

The LaunchPad app should install successfully and its database migrations should run without errors.

Werkelijk gedrag

The installation fails and Nextcloud shows the following error:

"Could not resolve OCA\LaunchPad\Migration\Version001000Date20240101000000! Class can not be instantiated"

Omgeving

  • Namespace/environment: Nextcloud running as TrueNAS SCALE App / Docker container
  • Nextcloud version: 33.0.3.2
  • App version/image tag: LaunchPad 1.0.10 from the Nextcloud app store
  • Browser: Firefox 152.0, but the failure appears to be server-side during app installation

Logs / Screenshots

Relevant Nextcloud log excerpt from the failed installation attempt:

Nextcloud version: 33.0.3.2
App id: mydash
App name: LaunchPad
App version: 1.0.10
Installation path: /var/www/html/custom_apps/mydash

The installation fails during schema migration:

Migrating schema only
- Reading 001000Date20240101000000

Exception:

OCP\AppFramework\QueryException:
Could not resolve OCA\LaunchPad\Migration\Version001000Date20240101000000! Class can not be instantiated

Trace excerpt:

OC\DB\MigrationService->createInstance("001000Date20240101000000")
OC\DB\MigrationService->migrateSchemaOnly("latest")
OC\DB\MigrationService->migrate("latest", true)
OC\Installer->installAppLastSteps("/var/www/html/custom_apps/mydash", ...)
OC\Installer->installApp("mydash")

Additional app metadata from the same log entry:

"id": "mydash"
"name": "LaunchPad"
"version": "1.0.10"
"namespace": "LaunchPad"

Acceptatiecriteria (fix)

  • App installation no longer fails with "Class can not be instantiated"
  • Migration OCA\LaunchPad\Migration\Version001000Date20240101000000 can be resolved and executed
  • Regression test added for app installation / migration loading
  • Fix tested in supported Nextcloud versions
  • No new security findings
  • Code reviewed

Severity

🟡 Medium — beperkte impact


Gemigreerd van Codeberg — oorspronkelijk Conduction/launchpad#106, geopend door sherlook op 2026-06-18.

Metadata

Metadata

Assignees

Labels

triageAwaiting triage

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions