Backup app throwing errors - cannot run
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 272
- Forks
- 37
- PR merge metrics
- No merged PRs in 30d
Description
I have installed backup v1.0.6 and did composer install. In the web console, clicking the backup tab displays nothing.
I checked the logs, there are no errors related to backup app.
when trying to run the commands manually i get the following error (all commands throw the same error)
NC: v24.0.0
backup: 1.0.6
root@nextcloud:/var/www/nextcloud# sudo -u www-data php occ backup:external:list
+-----------+------+----------------+
| StorageId | Path | Storage Folder |
+-----------+------+----------------+
An unhandled exception has been thrown:
TypeError: Argument 3 passed to OC\DB\QueryBuilder\QueryBuilder::__construct() must implement interface Psr\Log\LoggerInterface, instance of OC\Log given, called in /var/www/nextcloud/apps/backup/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc23/NC23ExtendedQueryBuilder.php on line 74 and defined in /var/www/nextcloud/lib/private/DB/QueryBuilder/QueryBuilder.php:86
Stack trace:
#0 /var/www/nextcloud/apps/backup/vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc23/NC23ExtendedQueryBuilder.php(74): OC\DB\QueryBuilder\QueryBuilder->__construct()
#1 /var/www/nextcloud/apps/backup/lib/Db/CoreQueryBuilder.php(48): ArtificialOwl\MySmallPhpTools\Db\Nextcloud\nc23\NC23ExtendedQueryBuilder->__construct()
#2 /var/www/nextcloud/apps/backup/lib/Db/CoreRequestBuilder.php(124): OCA\Backup\Db\CoreQueryBuilder->__construct()
#3 /var/www/nextcloud/apps/backup/lib/Db/ExternalFolderRequestBuilder.php(75): OCA\Backup\Db\CoreRequestBuilder->getQueryBuilder()
#4 /var/www/nextcloud/apps/backup/lib/Db/ExternalFolderRequest.php(72): OCA\Backup\Db\ExternalFolderRequestBuilder->getExternalFolderSelectSql()
#5 /var/www/nextcloud/apps/backup/lib/Service/ExternalFolderService.php(126): OCA\Backup\Db\ExternalFolderRequest->getAll()
#6 /var/www/nextcloud/apps/backup/lib/Service/ExternalFolderService.php(819): OCA\Backup\Service\ExternalFolderService->getAll()
#7 /var/www/nextcloud/apps/backup/lib/Command/ExternalList.php(91): OCA\Backup\Service\ExternalFolderService->getStorages()
#8 /var/www/nextcloud/apps/backup/vendor/symfony/console/Command/Command.php(298): OCA\Backup\Command\ExternalList->execute()
#9 /var/www/nextcloud/core/Command/Base.php(168): Symfony\Component\Console\Command\Command->run()
#10 /var/www/nextcloud/apps/backup/vendor/symfony/console/Application.php(1015): OC\Core\Command\Base->run()
#11 /var/www/nextcloud/apps/backup/vendor/symfony/console/Application.php(299): Symfony\Component\Console\Application->doRunCommand()
#12 /var/www/nextcloud/apps/backup/vendor/symfony/console/Application.php(171): Symfony\Component\Console\Application->doRun()
#13 /var/www/nextcloud/lib/private/Console/Application.php(211): Symfony\Component\Console\Application->run()
#14 /var/www/nextcloud/console.php(99): OC\Console\Application->run()
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Reproduce the failure with sudo -u www-data php occ backup:external:list on the reported Nextcloud and backup versions. Start at vendor/artificial-owl/my-small-php-tools/lib/Db/Nextcloud/nc23/NC23ExtendedQueryBuilder.php:74 and compare it with lib/private/DB/QueryBuilder/QueryBuilder.php:86, then trace the callers in lib/Db/CoreQueryBuilder.php and lib/Command/ExternalList.php. Done means the command and backup tab no longer fail with this constructor TypeError.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100