Closed Angl0r closed 2 years ago
Same problem for me.
Also have the same problem
Same here
I had the same issue when upgrading running:
composer self-update --2
This worked for us
I ran php upgrade.php again and it said I didn't have php sodium installed, I installed it and restarted my IIS Server, ran php upgrade.php and it works now.
I had the same issue when upgrading running:
composer self-update --2
This worked for us
tryed this in a dev environment, this works. But also have to accept that package meteor (or similar) has changed. But is this the correct way to do this or will this lead to other problems in further Releases is the question :D
Same, can anyone confirm yet if composer self-update --2
is safe?
We’ve been using composer 2 for about a year - it’s safe. Also, if you run into any problems, you can always downgrade composer using composer self-update --1
.
Can you folks let me know if upgrading composer resolves this for you?
Upgrading composer worked for me. Then re-ran php upgrade.php and it updated.
Great, thanks for the heads up. I wonder if I should attempt the upgrade of composer in the upgrade.php file to make this easier for folks.
Can you folks let me know if upgrading composer resolves this for you?
I can confirm it worked for me.
I am on 5.3.8 and tried to run php upgrade.php and it failed (pastebin), so I found this thread and tried to run the composer upgrade and it failed. I had been warned previously not to just sudo/run as root, and my install was done via the install script (see issue #10581), so I'm not quite sure how it's failing. I confirmed I ran the install script not as sudo and not as root so upgrading composer not as root should still work, but doesn't.
tom@assets:/var/www/html/snipeit$ composer self-update --2
Upgrading to version 2.3.5 (2.x channel).
[Composer\Downloader\FilesystemException]
Filesystem exception:
Composer update failed: "/usr/local/bin/composer" could not be written.
rename(/home/tom/.cache/composer/composer-temp1376806.phar,/usr/local/bin/c
omposer): Permission denied
self-update [-r|--rollback] [--clean-backups] [--no-progress] [--update-keys] [--stable] [--preview] [--snapshot] [--1] [--2] [--set-channel-only] [--] [<version>]
I'm also confused how, if permission was denied to run git in the php upgrade.php, that the script didn't just stop there and instead tried to continue on. Is there no error catch? (I wanted to create a new issue for this but I don't want to lie about trying debug mode.)
EDIT: It seems that everything is owned by snipeitapp, if I do the commands with sudo -u snipeitapp they work. This might be how the system was setup, so, maybe worthwhile for a doc somewhere. "See who owns the files, and try to run as them, not root." I did have to run the upgrade.php twice (there is no update.php even though it is referenced in the docs here), but it worked.
I was running v5.3.8 on Windows Server 2022 and tried updated to 6.0.7 with the same failure. I found this issue and tried running "composer self-update" Was running composer v2.2.4, that command updated me to v2.3.9. Tried running "php upgrade.php" again, and this time it said "MISSING PHP EXTENSION: sodium" I added "extension=php_sodium.dll" to php.ini, ran "php upgrade.php" again and this time it worked.
Mine is telling me You are already using the latest available Composer version 2.3.9 (2.x channel).
when I run composer self-update --2
, but php upgrade.php
is telling me I'm using compose 1?
It's possible you have composer installed both locally and globally, and the upgrader is using a different one than your CLI. I'd need to see the output of your upgrade.
-- Updating local composer.phar
That means you updated your global composer, but you're using composer.phar, so that one isn't updated.
Try:
php composer.phar update
(or php composer.phar self-update --2
)
That cleared up v1 composer issue, running into more issues but I think it's just compose mad that things aren't updated fully as I've had to make adjustments to server settings due to insufficient resources.
Debug mode
Describe the bug
When Upgrading with upgrade.php i recive the Following Errors:
Step 5: Cleaning up old cached files:
√ No bootstrap/cache/compiled.php, so nothing to delete. √ No bootsrap/cache/services.php, so nothing to delete. √ No bootstrap/cache/config.php, so nothing to delete.
-- In ProviderRepository.php line 208:
Class 'Barryvdh\DomPDF\ServiceProvider' not found
-- In ProviderRepository.php line 208:
Class 'Barryvdh\DomPDF\ServiceProvider' not found
-- In ProviderRepository.php line 208:
Class 'Barryvdh\DomPDF\ServiceProvider' not found
-- In ProviderRepository.php line 208:
Class 'Barryvdh\DomPDF\ServiceProvider' not found
as well in Step 6:
Problem 1
and at the end:
Step 7: Migrating database:
In ProviderRepository.php line 208:
Class 'Barryvdh\DomPDF\ServiceProvider' not found
Step 8: Checking for OAuth keys:
√ OAuth keys detected. Skipping passport install.
Step 9: Taking application out of maintenance mode:
-- In ProviderRepository.php line 208:
Class 'Barryvdh\DomPDF\ServiceProvider' not found
got a clean page atm.
Reproduction steps
Expected behavior
Uprage fine to newest Major Version
Screenshots
No response
Snipe-IT Version
5.4.4 to 6.0.0
Operating System
Ubuntu 20.04
Web Server
Apache2
PHP Version
7.4.29
Operating System
Windows
Browser
Firefox
Version
100.0
Device
No response
Operating System
No response
Browser
No response
Version
No response
Error messages
No response
Additional context
No response