Upload error image ContentBlocks: ExifMetadataReader

Das Hochladen von Bildern in ContentBlocks funktioniert nicht. Der grüne Balken bleibt hängen und ich bekomme folgende Fehlermeldung:

(ERROR @ /.../core/components/contentblocks/model/contentblocks/contentblocks.class.php : 1401) [ContentBlocks] Can't use the ExifMetaDataReader to automatically rotate images: The PHP EXIF extension is required to use the ExifMetadataReader
(ERROR @ /.../core/components/contentblocks/model/contentblocks/contentblocks.class.php : 1401) [ContentBlocks] Can't use the ExifMetaDataReader to automatically rotate images: The PHP EXIF extension is required to use the ExifMetadataReader
(ERROR @ /.../core/src/Revolution/Sources/modMediaSource.php : 2329) PHP warning: Undefined variable $image
(ERROR @ /.../core/src/Revolution/Sources/modMediaSource.php : 2329) PHP warning: Undefined variable $image

und einen Javascript-Fehler:

t.result is undefined
 /assets/components/contentblocks/dist/inputs/all-min.js?cbv=1.14.0-rc2:1

Das Bild hat eine Auflösung von 4032 x 3024 px. Sobald ich das Bild kleiner mache z.B. 2500 x 1875 px funktioniert es.

ModX 3.1.0
PHP 8.1

The log message about the “ExifMetaDataReader” seems to be more informative (about a missing PHP extension) than the real cause for the upload not working.

The actual issue could be that the file is just too large. Maybe check the system setting upload_maxsize or upload_max_filesize in php.ini.

upload_max_filesize = 4g
upload_maxsize does not exist in php-info

Yes, this one is a MODX system setting.

The EXIF error means your server lacks the extension but that shouldn’t be interfering with the upload. It’s something you’ll want to fix to make certain features (like fixing the image rotation automatically) work correctly, but is technically optional.

The undefined variable warning in the media source class suggests the media source can’t read the file while trying prepare a manager thumbnail. That could be a failed upload or the file just being too big to read, but doesn’t really explain the root cause specifically… that it works when you make the image smaller does suggest it’s potentially related to size.

What interests most is the javascript error. That suggests the response from the AJAX upload request is invalid. Can you try inspecting that with the browser dev tools to see what the response is?