Hey,
I’m currently working on an app with following bootstrap code
<?php
declare(strict_types=1);
/**
* SPDX-FileCopyrightText: 2024 synyx GmbH & Co. KG
* SPDX-License-Identifier: AGPL-3.0-or-later
*/
namespace OCA\Cleanup\AppInfo;
use OCP\AppFramework\App;
use OCP\AppFramework\Bootstrap\IBootContext;
use OCP\AppFramework\Bootstrap\IBootstrap;
use OCP\AppFramework\Bootstrap\IRegistrationContext;
use Psr\Container\ContainerInterface;
use Throwable;
class Application extends App implements IBootstrap {
public const APP_ID = 'cleanup';
public const APP_NAME = 'Cleanup';
/**
* Application constructor.
*
* @param array $params
*/
public function __construct(array $params = []) {
parent::__construct(self::APP_ID, $params);
}
/**
* @param IRegistrationContext $context
*/
public function register(IRegistrationContext $context): void {
include_once __DIR__ . '/../../vendor/autoload.php';
}
/**
* @param IBootContext $context
*
* @throws Throwable
*/
public function boot(IBootContext $context): void {
}
}
in my composer.json i have this
"require-dev": {
"psalm/phar": "^5.26.1",
"nextcloud/coding-standard": "^1.2",
"nextcloud/ocp": "dev-stable30"
},
This works for Nextcloud 30, as soon as I test my app on Nextcloud 29, loading the app fails and breaks the Nextcloud instance. So I have to change the dependency back to dev-stable29
.
Is it possible to support all recent Nextcloud versions withtout the need to change the dependency?
Regards
Jonas