The solution is to make sure that:
a) You have a copy of default.settings.php in the sites directory to which you are installing drupal and
b) Make sure the default directory still exists with its own copy of default.settings.php / settings.php
It’s a very weird bug