1. I have installed Joomla 4 and integrated a JEvent calendar via menu manager.
2. under Cassiopeia the calendar was displayed without errors.
3. with nina the view was broken. Among other things, the scripts and styles in the header were not set correctly.
4. first I commented out the line <?php require("inc/layouts/main.php" ?> in the file j4/templates/j51_nina/index.php. Result: No more errors, but of course no calendar either.
5. I undid the change from 4. and only removed <?php if ($this->getBuffer( 'message' )) : ?> and <?php endif; ?> around <jdoc:include type="message" /> in the file j4/templates/j51_nina/inc/layouts/main.php. So
<jdoc:include type="message" />
instead of
<?php if ($this->getBuffer( 'message' )) : ?>
<jdoc:include type="message" />
<?php endif; ?>
in the file j4/templates/j51_nina/inc/layouts/main.php. This solved my problem at first sight.
6. what getBuffert does can be seen in the file j4/libraries/src/Document/HtmlDocument.php in line 542. But I have stopped here now, because I am sure you know better where the problem lies and how it can be solved.