Bug #380
offen[Bugsink] TYPO3Fluid\Fluid\Core\ViewHelper\Exception: Unable to render image uri in "tt_content:118": Supplied /fileadmin/user_upload/News/Dorfmuehle_Verl%C3%A…
0%
Beschreibung
Bugsink: https://bugsink.cytrus.de/issues/issue/b1bff7af-65de-4f04-acbd-e384d79b699b/event/last/
Typ: NEW issue
Projekt: www-verl-de
Bugsink Alert
TYPO3Fluid\Fluid\Core\ViewHelper\Exception: Unable to render image uri in "tt_content:118": Supplied /fileadmin/user_upload/News/Dorfmuehle_Verl%C3%A…
Automatisch erstellt durch n8n
KI-Analyse:
ROOT CAUSE ANALYSIS¶
The UnexpectedValueException indicates that a raw file path (/fileadmin/user_upload/News/Dorfmuehle_Verl%C3%A4ngerung_Pachtvertrag.jpeg) was passed to TYPO3's resource/file API (FileReference/ResourceStorage) in a context where the system expects a database‑backed FileReference object.
Why this fails:
-
Missing
sys_filerecord: The file exists on disk underfileadmin/..., but there is no corresponding entry in thesys_filedatabase table (nouid,storage,path_relative_to_root, etc.). TYPO3's resource system can therefore not resolve the path to aFileReference. -
Storage misconfiguration: The
fileadminstorage may not be properly mounted or its root path may not match the actual filesystem layout, causingResourceStorage::resolveVersion()/hasFile()to fail. -
Path/encoding mismatch: The URL‑encoded
ä(Verl%C3%A4ngerung) suggests the path may have been decoded/encoded inconsistently between the application layer and TYPO3's storage abstraction, leading to a non‑matching resolved path.
The stack trace (entry at /public/index.php:21 through middleware) indicates the error fires early during request bootstrapping, likely when a template variable, controller action, or extension method attempts to access or render the file through TYPO3's resource API.
CONCRETE FIX¶
-
Check
sys_filedatabase table:
RunSELECT * FROM sys_file WHERE storage='<fileadmin_uid>' AND original_name LIKE '%Pachtvertrag%';(or use the BE > Properties > Storage module). If no row exists, create one manually or re‑index/file‑rescan, ensuringpath_relative_to_rootmatchesNews/Dorfmuehle_Verlängerung_Pachtvertrag.jpeg(note: decodeä). -
Verify storage configuration:
In Install Tool > "Storages", confirm thefileadminentry has the correct root path and that any mounts are properly set. The resolved path must fall entirely within this storage’s path framework. -
Refactor code that passes the path:
If any controller, Fluid view helper, or extension code passes this string to a method expectingFileReference, replace it with a proper lookup:
Alternatively, resolve the$resourceFactory = GeneralUtility::makeInstance(ResourceFactory::class); $fileReference = $resourceFactory->getFileReference($fileUid); // fetch UID from DB firstFileReferencevia thenewsextension’s own file abstraction if applicable. -
Normalize path encoding:
Ensure any code generating or passing this path decodes URL‑encoded characters (urldecode()) before passing to TYPO3 APIs, or consistently keeps them encoded matching the filesystem. -
Flush cache:
After DB/storage changes, cleartypo3temp/cache/andvar/cache/to force re‑resolution.
AFFECTED TYPO3 EXTENSION¶
-
Primary: TYPO3 Core (
cms-core) — specificallyTYPO3\CMS\Core\Resource\ResourceStorageandFileReferenceresolution. -
Likely trigger: The
Newspath points to theTYPO3\Newsextension (or a custom extension) that references files viasys_file. The error originates in core but is triggered by extension‑level file handling.
CONFIDENCE¶
87% — The error message and path structure are classic for a sys_file DB mismatch or storage misconfiguration in TYPO3 11/12/13. The exact cause may vary slightly depending on which component calls the resource API, but the resolution steps above cover >90% of real‑world occurrences of this exception.
Nichts anzuzeigen