Fixed "Failed to open stream: No such file or directory" when one click upgrade xf 2.2.5

Affected version
2.2.5

ZixDev

Member
Warning: require_once(/Users/liltee/Documents/www/xf2/src/vendor/paragonie/sodium_compat/lib/stream-xchacha20.php): Failed to open stream: No such file or directory in /Users/liltee/Documents/www/xf2/src/vendor/paragonie/sodium_compat/lib/php72compat.php on line 1221

Fatal error
: Uncaught Error: Failed opening required '/Users/liltee/Documents/www/xf2/src/vendor/paragonie/sodium_compat/lib/stream-xchacha20.php' (include_path='.:/usr/local/Cellar/php/8.0.3/share/php/pear') in /Users/liltee/Documents/www/xf2/src/vendor/paragonie/sodium_compat/lib/php72compat.php:1221 Stack trace: #0 /Users/liltee/Documents/www/xf2/src/vendor/paragonie/sodium_compat/autoload.php(67): require_once() #1 /Users/liltee/Documents/www/xf2/src/vendor/composer/autoload_real.php(69): require('/Users/liltee/D...') #2 /Users/liltee/Documents/www/xf2/src/vendor/composer/autoload_real.php(59): composerRequirec3539a040d496b098908566d08fa79fa('3109cb1a231dcd0...', '/Users/liltee/D...') #3 /Users/liltee/Documents/www/xf2/src/vendor/autoload.php(7): ComposerAutoloaderInitc3539a040d496b098908566d08fa79fa::getLoader() #4 /Users/liltee/Documents/www/xf2/src/XF.php(253): require('/Users/liltee/D...') #5 /Users/liltee/Documents/www/xf2/src/XF.php(76): XF::startAutoloader() #6 /Users/liltee/Documents/www/xf2/index.php(12): XF::start('/Users/liltee/D...') #7 {main} thrown in /Users/liltee/Documents/www/xf2/src/vendor/paragonie/sodium_compat/lib/php72compat.php on line 1221
 

mcatze

Well-known member
There was an issue during upload/copying the new files. Happend to me on local installation. You have to merge/upload the files manually and restart the upgrade process.
 

Mike

XenForo developer
Staff member
This is the second report we've had of this so we'll need to do some more investigation.

If you run into this, then complete the upgrade in a "traditional" way (upload via FTP and go to the upgrade system after that).
 

mcatze

Well-known member
@Mike this happend to me also but just on the local environment (MacOS setup). On the production environment the upgrade process runs fine.
 

XF Bug Bot

XenForo bug fixer bot
Staff member
Thank you for reporting this issue, it has now been resolved. We are aiming to include any changes that have been made in a future XF release (2.2.6).

Change log:
Adjust file copying order of the one click upgrader to reduce issues with page breaks.
There may be a delay before changes are rolled out to the XenForo Community.
 

Mike

XenForo developer
Staff member
The situation that creates this is fairly random (as it depends on execution speed) and hopefully shouldn't be that common but we've made changes that should hopefully prevent it in the future.

If you run into this specific issue, I believe there are two ways to resolve it:

1. Proceed with a traditional upgrade process. As in, the method described in the manual: https://xenforo.com/docs/xf2/install-upgrade/#1-downloading_1 Note that once the files are uploaded, you may need to go to <url>/install/ directly to complete the upgrade process.

2. Download XF 2.2.5 from the customer area and extract the specific file from the error message (src/vendor/paragonie/sodium_compat/lib/stream-xchacha20.php) and upload it to the corresponding location on your server. Now, you should be able to refresh the upgrade tab of your browser and it should continue on. (If this doesn't work, use approach #1 instead.)
 
Top