Skip to content

Upgrade Error - ValueError: str_repeat(): Argument #2 ($times) must be greater than or equal to 0 #29023

@kinimodmeyer

Description

@kinimodmeyer

How to use GitHub

  • Please use the 👍 reaction to show that you are affected by the same issue.
  • Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
  • Subscribe to receive notifications on status change and new comments.

Steps to reproduce

  1. try to upgrade from 22.1.1 to 22.2.1

Expected behaviour

System should not crash and be broken

Actual behaviour

2021-10-01T18:14:47+02:00 Updating <accessibility> ...
2021-10-01T18:14:47+02:00 Repair step: Migrate old user config
2021-10-01T18:14:47+02:00 Migrate old user config
2021-10-01T18:14:47+02:00 
2021-10-01T18:14:47+02:00  Starting ...
    0/0 [>-]   0%2021-10-01T18:14:47+02:00 
 Starting ...
   70/0 [->]   0%An unhandled exception has been thrown:
ValueError: str_repeat(): Argument #2 ($times) must be greater than or equal to 0 in /var/.../3rdparty/symfony/console/Helper/ProgressBar.php:497
Stack trace:
#0 /var/.../3rdparty/symfony/console/Helper/ProgressBar.php(497): str_repeat()
#1 /var/.../3rdparty/symfony/console/Helper/ProgressBar.php(568): Symfony\Component\Console\Helper\ProgressBar::Symfony\Component\Console\Helper\{closure}()
#2 [internal function]: Symfony\Component\Console\Helper\ProgressBar->Symfony\Component\Console\Helper\{closure}()
#3 /var/.../3rdparty/symfony/console/Helper/ProgressBar.php(581): preg_replace_callback()
#4 /var/.../3rdparty/symfony/console/Helper/ProgressBar.php(393): Symfony\Component\Console\Helper\ProgressBar->buildLine()
#5 /var/.../3rdparty/symfony/console/Helper/ProgressBar.php(352): Symfony\Component\Console\Helper\ProgressBar->display()
#6 /var/.../3rdparty/symfony/console/Helper/ProgressBar.php(312): Symfony\Component\Console\Helper\ProgressBar->setProgress()
#7 /var/.../core/Command/Upgrade.php(142): Symfony\Component\Console\Helper\ProgressBar->advance()
#8 /var/.../3rdparty/symfony/event-dispatcher/EventDispatcher.php(264): OC\Core\Command\Upgrade->OC\Core\Command\{closure}()
#9 /var/.../3rdparty/symfony/event-dispatcher/EventDispatcher.php(239): Symfony\Component\EventDispatcher\EventDispatcher->doDispatch()
#10 /var/.../3rdparty/symfony/event-dispatcher/EventDispatcher.php(73): Symfony\Component\EventDispatcher\EventDispatcher->callListeners()
#11 /var/.../lib/private/EventDispatcher/SymfonyAdapter.php(123): Symfony\Component\EventDispatcher\EventDispatcher->dispatch()
#12 /var/.../lib/private/Repair.php(251): OC\EventDispatcher\SymfonyAdapter->dispatch()
#13 /var/.../lib/private/Repair.php(282): OC\Repair->emit()
#14 /var/.../apps/accessibility/lib/Migration/RepairUserConfig.php(85): OC\Repair->advance()
#15 /var/.../lib/private/User/Manager.php(646): OCA\Accessibility\Migration\RepairUserConfig->OCA\Accessibility\Migration\{closure}()
#16 /var/.../apps/accessibility/lib/Migration/RepairUserConfig.php(86): OC\User\Manager->callForSeenUsers()
#17 /var/.../lib/private/Repair.php(123): OCA\Accessibility\Migration\RepairUserConfig->run()
#18 /var/.../lib/private/legacy/OC_App.php(1059): OC\Repair->run()
#19 /var/.../lib/private/legacy/OC_App.php(996): OC_App::executeRepairSteps()
#20 /var/.../lib/private/Updater.php(345): OC_App::updateApp()
#21 /var/.../lib/private/Updater.php(262): OC\Updater->doAppUpgrade()
#22 /var/.../lib/private/Updater.php(130): OC\Updater->doUpgrade()
#23 /var/.../core/Command/Upgrade.php(241): OC\Updater->upgrade()
#24 /var/.../3rdparty/symfony/console/Command/Command.php(255): OC\Core\Command\Upgrade->execute()
#25 /var/.../3rdparty/symfony/console/Application.php(1009): Symfony\Component\Console\Command\Command->run()
#26 /var/.../3rdparty/symfony/console/Application.php(273): Symfony\Component\Console\Application->doRunCommand()
#27 /var/.../3rdparty/symfony/console/Application.php(149): Symfony\Component\Console\Application->doRun()
#28 /var/.../lib/private/Console/Application.php(209): Symfony\Component\Console\Application->run()
#29 /var/.../console.php(99): OC\Console\Application->run()
#30 /var/.../occ(11): require_once('...')
#31 {main}
Keep maintenance mode active? [y/N] 

restart upgrade throws the exact same error.
if you make the upgrade step without the updater.phar it went through.

i had such a error on last upgrade too but on circles nextcloud/circles#807

Metadata

Metadata

Labels

Type

No type

Projects

Status

☑️ Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions