Update to beta3 - Unexpected error in Renderer.php on line 797

Hello
I apologise for having problems on every update. I resolved most of them, but ended up with two that I cannot fix, and they may be related.

I extracted and update the code as usual, and when running update.php I see:

  • farmOS Google Maps - listed as installed but incompatible. I can’t uninstall it. Composer does not have any record of it.
  • Trying to access the site itself, yields an error:

The website encountered an unexpected error. Please try again later.

TypeError : Drupal\Core\Render\Renderer::doTrustedCallback(): Argument #1 ($callback) must be of type callable, array given, called in /home/farmos/public_html/web/core/lib/Drupal/Core/Render/Renderer.php on line 797 in Drupal\Core\Render\Renderer->doTrustedCallback() (line 57 of core/lib/Drupal/Core/Security/DoTrustedCallbackTrait.php ).

I tried a few things, I tried removing the module (but can’t even uninstall or find it).
Stuck on this one, so the site is now inaccesible.
Thanks in advance
M

Hi @marlonv - ah yea if you take a look at the project page for the Google Map module you’ll see that it is only compatible with Drupal 9. farmOS v3 is Drupal 10.

https://www.drupal.org/project/farm_map_google

Did you take a backup before beginning the upgrade? The best thing to do is revert back to the old version, uninstall that module, and then try the upgrade again. (But make sure to check any other modules you may have added to ensure they are compatible with Drupal 10 and farmOS v3! Otherwise you’ll have the same issue with those as well.)

Or, if you need that Google Map module, you can wait for it to be declared compatible and then update to v3. It may only require a one-line change: farm_map_google.info.yml · 2.x · project / farm_map_google · GitLab

1 Like

This kind of issue is a good reason to use Composer to manage your dependencies: Building farmOS with Composer | farmOS

It’s more complicated, but it will catch things like this.

Hi
Yes, have backups implemented on the server. Deps are managed by composer. This is why the issue confuses me. I will restore and try that, thanks Mike

1 Like

Oh interesting! I would think that would have prevented composer update from working then. I wonder if you still have the log output from the commands you ran?

To be honest, I am sure I did something stupid.
I haven’t checked logs, and did most of the stuff from under a tree using Termius. If I can find anything worthwhile, I’ll share here.
For now, this highlights the importance of backing up. My twice-daily crons made it a blast to recover.
Thanks for the help and work that you put into this release, Mike

1 Like