I am one little step further now. This line in gridelements:
$BEfunc = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance('TYPO3\CMS\Backend\Utility\BackendUtility');
$pageTSconfig = $BEfunc->getPagesTSconfig($pageId);
returns different configs, depending if it is cached or not. The pageId is identically...