Undefined property Cms\Components\ViewBag::assetUrlPath

Hi there,

I just updated my October website from v3.7 to v4.0 and followed the upgrade guide, but I get the following error when viewing the front-end website or settings pages in the backend (SettingsModel):

Call to undefined property Cms\Components\ViewBag::assetUrlPath
~/vendor/october/rain/src/Extension/ExtendableTrait.php line 457

I have tried removing PHP files from the storage/framework folder and cleared cache. I also wanted to run the ‘php artisan october:optimize’ command, but this too returns the same error.

I use a local environment with Laravel Herd and using php 8.3.

Does anybody have an idea how to fix this?

Thanks!