Hi,
I’ve upgraded a project from 3.9 to 4.2 and managed to run it locally, but on production I get the following issue at https://stage.muehlehunziken.ch
Error thrown with message "Class "Kirby\Content\Field" not found"
Stacktrace:
#2 Error in /home/muehlehu/public_html/stage/kirby/src/Cms/AppPlugins.php:673
#1 Kirby\Cms\App:extensionsFromSystem in /home/muehlehu/public_html/stage/kirby/src/Cms/App.php:143
#0 Kirby\Cms\App:__construct in /home/muehlehu/public_html/stage/index.php:5
Any idea what it could be?
- Running on PHP 8.2
- Plugins updated “as much as possible”, works on dev / localhost
- Works well when I manually change the kirby folder back to 3.9
What am I missing?
Sure all files were properly uploaded? How did you update?
Basically replaced the “kirby” (from here if I remember correctly). This worked out of the box on dev / localhost, just had to update one or two plugins, when I had an issue in the panel.
Did I miss something?
I just double checked the guides and it seems it’s currently actually not stated clearly how to update – and there is a link that links with the page itself 
Once your site code and plugins have been updated, you can update Kirby itself. Please follow our general update instructions.
A shot in the dark: replace the /vendor
folder if you have one.
If you installed kirby via composer, it’s possible that the autoloader (in /vendor/composer/autoload_static.php
) still points to v3 filepaths (Kirby\Cms\Field
has been renamed to Kirby\Content\Field
).
Hmm, that wasn’t it, but good to know.
Hmm, interestingly it works without any problems with 4.1.2. cc @texnixe @bastianallgeier
Nothing has changed with that file from 4.1.2 to 4.3? Did you try to reupload the kirby folder to the server. It really just feels like the file is just missing. Maybe a broken/incomplete upload?
Ooooh, I found it out! My .gitignore was showing content
instead of /content
. This lead the /kirby/src/Content
folder to not commit 
Thanks Bastian, replacing the kirby
folder manually via FTP worked which made things even more bizarre – but after some investigation I found out about the missing Content
folder in /kirby/src