Dependencies issues with two sites with grav cms

What app is this about, and its version: Grav, 2.0.8~ynh1
What YunoHost version are you running: 12.1.40.1
What type of hardware are you using: VPS bought online

Describe your issue

I have two Grav apps on my server. since few days only one can works, the other have an error trying to read a file on the other one and have not permissions to do it.

Here is the message error in grav__2

 Whoops \ Exception \ ErrorException (E_WARNING)
include(/var/www/grav/vendor/composer/../symfony/event-dispatcher/Event.php): Failed to open stream: Permission denied

If I restart the service php8.4-fpm the first site grav failed with similar error and the second one grav__2 is back ??

 Whoops \ Exception \ ErrorException (E_WARNING)
include(/var/www/grav__2/vendor/composer/../symfony/event-dispatcher/Event.php): Failed to open stream: Permission denied

How can I resolve this ?? It’s very strange !!

Share relevant logs or error messages

/var/www/grav__2/logs/grav.log

[2026-07-12T22:56:51.269924+00:00] grav.CRITICAL: include(/var/www/grav/vendor/composer/../symfony/event-dispatcher/Event.php): Failed to open stream: Permission denied - Trace: #0 /var/www/grav__2/system/src/Grav/Common/Errors/Errors.php(67): Whoops\Run->handleError() #1 /var/www/grav__2/system/src/Grav/Common/Debugger.php(952): Grav\Common\Errors\Errors::{closure:Grav\Common\Errors\Errors::resetHandlers():61}() #2 /var/www/grav__2/vendor/composer/ClassLoader.php(576): Grav\Common\Debugger->deprecatedErrorHandler() #3 /var/www/grav__2/vendor/composer/ClassLoader.php(576): include('...') #4 /var/www/grav__2/vendor/composer/ClassLoader.php(427): {closure:Composer\Autoload\ClassLoader::initializeIncludeClosure():575}() #5 [internal function]: Composer\Autoload\ClassLoader->loadClass() #6 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport/AbstractTransport.php(38): class_exists() #7 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport/SendmailTransport.php(54): Symfony\Component\Mailer\Transport\AbstractTransport->__construct() #8 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport/SendmailTransportFactory.php(24): Symfony\Component\Mailer\Transport\SendmailTransport->__construct() #9 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport.php(172): Symfony\Component\Mailer\Transport\SendmailTransportFactory->create() #10 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport.php(161): Symfony\Component\Mailer\Transport->fromDsnObject() #11 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport.php(113): Symfony\Component\Mailer\Transport->parseDsn() #12 /var/www/grav__2/user/plugins/email/vendor/symfony/mailer/Transport.php(74): Symfony\Component\Mailer\Transport->fromString() #13 /var/www/grav__2/user/plugins/email/classes/Email.php(539): Symfony\Component\Mailer\Transport::fromDsn() #14 /var/www/grav__2/user/plugins/email/classes/Email.php(365): Grav\Plugin\Email\Email::getTransport() #15 /var/www/grav__2/user/plugins/email/classes/Email.php(40): Grav\Plugin\Email\Email->initMailer() #16 /var/www/grav__2/user/plugins/email/email.php(59): Grav\Plugin\Email\Email->__construct() #17 /var/www/grav__2/vendor/symfony/event-dispatcher/EventDispatcher.php(206): Grav\Plugin\EmailPlugin->onPluginsInitialized() #18 /var/www/grav__2/vendor/symfony/event-dispatcher/EventDispatcher.php(56): Symfony\Component\EventDispatcher\EventDispatcher->callListeners() #19 /var/www/grav__2/system/src/Grav/Common/Grav.php(674): Symfony\Component\EventDispatcher\EventDispatcher->dispatch() #20 /var/www/grav__2/system/src/Grav/Common/Processors/PluginsProcessor.php(36): Grav\Common\Grav->fireEvent() #21 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Traits/RequestHandlerTrait.php(50): Grav\Common\Processors\PluginsProcessor->process() #22 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Traits/RequestHandlerTrait.php(62): Grav\Framework\RequestHandler\RequestHandler->handle() #23 /var/www/grav__2/system/src/Grav/Common/Processors/InitializeProcessor.php(129): Grav\Framework\RequestHandler\RequestHandler->handle() #24 /var/www/grav__2/system/src/Grav/Common/Debugger.php(650): Grav\Common\Processors\InitializeProcessor::{closure:Grav\Common\Processors\InitializeProcessor::process():129}() #25 /var/www/grav__2/system/src/Grav/Common/Processors/InitializeProcessor.php(129): Grav\Common\Debugger->profile() #26 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Traits/RequestHandlerTrait.php(50): Grav\Common\Processors\InitializeProcessor->process() #27 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Traits/RequestHandlerTrait.php(62): Grav\Framework\RequestHandler\RequestHandler->handle() #28 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Middlewares/MultipartRequestSupport.php(40): Grav\Framework\RequestHandler\RequestHandler->handle() #29 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Traits/RequestHandlerTrait.php(50): Grav\Framework\RequestHandler\Middlewares\MultipartRequestSupport->process() #30 /var/www/grav__2/system/src/Grav/Framework/RequestHandler/Traits/RequestHandlerTrait.php(62): Grav\Framework\RequestHandler\RequestHandler->handle() #31 /var/www/grav__2/system/src/Grav/Common/Grav.php(297): Grav\Framework\RequestHandler\RequestHandler->handle() #32 /var/www/grav__2/index.php(127): Grav\Common\Grav->process() #33 {main} [] []

I have also open a issue here Dependencies problem with 2 grav · Issue #229 · YunoHost-Apps/grav_ynh · GitHub

Sorry for this dumb suggestion, but have you tried forcing an upgrade?

This issue comes just before last upgrade, the apps were on version 2.0.6~ynh1 and I have just upgraded the 2 to 2.0.8~ynh1 .

But if needed I can try another force upgrade, but I don’t believe it will change this strange bug… After trying a force upgrade for grav__2 (is the one actually broken), nothing chnage

I have also try debug changing some parameters like for cache… It did not solve this conflict…

I don’t what can I do ??

Same here with two instances upgraded to 2.0.8.
This seems related to php8.4 : downgrading to 8.3 fixes the issue for me. (Will try further with 8.5).

Can you try upgrading from GitHub - YunoHost-Apps/grav_ynh at test_fix · GitHub ?

NB: With php8.4, there is no issue with two fresh installations of grav (but cannot log in to the admin panel…)

I try upgrade the 2 grav with this fix ??

Yes, that’s what I did and both instances are working now. That is just a workaround…

Thanks a lot !! you will save my day, it works !

Well, I’m afraid this is just a workaround and idk what is the root cause…

it’s really strange why the symphony will try to read a file in another path… perhaps an env to add ??

Well, the thing is I installed two fresh instances of grav and such issue doesn’t occur…

Ok, so perhaps there is old configs from previous versions which create a mistake…

Mmmh, upgrading to php8.5 doesn’t cause any issue either…
I’m wondering if it could be related to the number of workers in the php pool… The 8.4 pool was the largest one in ly case. What about yours ?

ls /etc/php/8.4/fpm/pool.d/
nextcloud.conf  signaturepdf.conf  www.conf


The issue is with the admin2 plugin : removing it and authenticating with the (legacy?) admin solves this issue.

I did not try use the admin2 plugin, still using Admin Panel v1.10.52 1.7

I also use DevTools v1.9.1 1.7 because I have child themes on each grav

But like this it’s working again for the 2 sites with php8.3…

Yes, same here with my 2 upgraded grav, which is why there was no issue with them. But fresh installations come with admin2 enabled as default and it’s impossible to authenticate to admin panel (need to uninstall admin2 via cli).

Trying the upgrade to 2.0.10 and php 8.5…

[edit]: works smoothly