Errors during update to 21.08.4 #2418

Closed
opened 2026-02-05 04:05:11 +03:00 by OVERLORD · 2 comments
Owner

Originally created by @techauthoruk on GitHub (Oct 6, 2021).

Describe the bug
Errors occur when updating to the latest version of Bookstack (21.08.4); I used the following commands:

sudo git pull origin release && composer install --no-dev && php artisan migrate
sudo php artisan bookstack:regenerate-comment-content
sudo php artisan cache:clear
sudo php artisan view:clear

a summary of what appeared is shown below:

Deprecation Notice: Required parameter $path follows optional parameter $schema in /usr/share/php/JsonSchema/Constraints/UndefinedConstraint.php:62
Deprecation Notice: Required parameter $path follows optional parameter $schema  in /usr/share/php/JsonSchema/Constraints/UndefinedConstraint.php:108
Deprecation Notice: Method ReflectionParameter::getClass() is deprecated in /usr/share/php/Composer/Repository/RepositoryManager.php:130
Deprecation Notice: Method ReflectionParameter::getClass() is deprecated in /usr /share/php/Composer/Repository/RepositoryManager.php:130
> @php -r "!file_exists('bootstrap/cache/services.php') || @unlink('bootstrap/cache/services.php');"
Loading composer repositories with package information
Installing dependencies from lock file
PHP Fatal error:  Uncaught ArgumentCountError: array_merge() does not accept unknown named parameters in /usr/share/php/Composer/DependencyResolver/DefaultPolicy.php:84

Steps To Reproduce
Steps to reproduce the behavior:

  1. Update Bookstack using the commands shown above
  2. Console shows errors
  3. Log in to Bookstack produces the 'An error has occurred' page
  4. Click on 'Return to home'
  5. Use Bookstack; creating a new page throws an error page

Expected behavior
The update should throw no errors; you should be able to log in without seeing the error page and the app should work normally. As it stands, my instance is unusable

Your Configuration (please complete the following information):

  • Exact BookStack Version (Found in settings): 21.08.4
  • PHP Version: 8.0.3
  • Hosting Method (Nginx/Apache/Docker): Apache 2 on Ubuntu 20.04 LTS
Originally created by @techauthoruk on GitHub (Oct 6, 2021). **Describe the bug** Errors occur when updating to the latest version of Bookstack (21.08.4); I used the following commands: ```bash sudo git pull origin release && composer install --no-dev && php artisan migrate sudo php artisan bookstack:regenerate-comment-content sudo php artisan cache:clear sudo php artisan view:clear ``` a summary of what appeared is shown below: ```bash Deprecation Notice: Required parameter $path follows optional parameter $schema in /usr/share/php/JsonSchema/Constraints/UndefinedConstraint.php:62 Deprecation Notice: Required parameter $path follows optional parameter $schema in /usr/share/php/JsonSchema/Constraints/UndefinedConstraint.php:108 Deprecation Notice: Method ReflectionParameter::getClass() is deprecated in /usr/share/php/Composer/Repository/RepositoryManager.php:130 Deprecation Notice: Method ReflectionParameter::getClass() is deprecated in /usr /share/php/Composer/Repository/RepositoryManager.php:130 > @php -r "!file_exists('bootstrap/cache/services.php') || @unlink('bootstrap/cache/services.php');" Loading composer repositories with package information Installing dependencies from lock file PHP Fatal error: Uncaught ArgumentCountError: array_merge() does not accept unknown named parameters in /usr/share/php/Composer/DependencyResolver/DefaultPolicy.php:84 ``` **Steps To Reproduce** Steps to reproduce the behavior: 1. Update Bookstack using the commands shown above 2. Console shows errors 3. Log in to Bookstack produces the 'An error has occurred' page 4. Click on 'Return to home' 5. Use Bookstack; creating a new page throws an error page **Expected behavior** The update should throw no errors; you should be able to log in without seeing the error page and the app should work normally. As it stands, my instance is unusable **Your Configuration (please complete the following information):** - Exact BookStack Version (Found in settings): 21.08.4 - PHP Version: 8.0.3 - Hosting Method (Nginx/Apache/Docker): Apache 2 on Ubuntu 20.04 LTS
Author
Owner

@ssddanbrown commented on GitHub (Oct 6, 2021):

Hi @techauthoruk,
I have a feeling this would be due to an outdated composer version.
Could you run composer -V and confirm the output?

@ssddanbrown commented on GitHub (Oct 6, 2021): Hi @techauthoruk, I have a feeling this would be due to an outdated composer version. Could you run `composer -V` and confirm the output?
Author
Owner

@techauthoruk commented on GitHub (Oct 6, 2021):

@ssddanbrown
Hi Dan

Current composer version is 1.10.1 (2020-03-13)....so you were spot on! Just updated to 2.1.9 (from https://getcomposer.org/download/) and then re-ran the Bookstack update, and all seems fine. Composer -V is still showing 1.10.1 as the version but I haven't rebooted the server yet.

As an aside, I love having the IP address in the audit log - a really useful addition.

Thanks again Dan - I will close this now

Mark

@techauthoruk commented on GitHub (Oct 6, 2021): @ssddanbrown Hi Dan Current composer version is 1.10.1 (2020-03-13)....so you were spot on! Just updated to 2.1.9 (from https://getcomposer.org/download/) and then re-ran the Bookstack update, and all seems fine. Composer -V is still showing 1.10.1 as the version but I haven't rebooted the server yet. As an aside, I love having the IP address in the audit log - a really useful addition. Thanks again Dan - I will close this now Mark
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#2418