From 44a57b9a6fcc775b922fc7a4e930ca182202a565 Mon Sep 17 00:00:00 2001 From: Paul Romano Date: Sat, 8 Apr 2023 14:34:02 +0200 Subject: [PATCH] Improve error message about missing settings.xml --- src/settings.cpp | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/settings.cpp b/src/settings.cpp index 2f8fbd1d0..6fa01708e 100644 --- a/src/settings.cpp +++ b/src/settings.cpp @@ -223,16 +223,11 @@ void read_settings_xml() std::string filename = settings::path_input + "settings.xml"; if (!file_exists(filename)) { if (run_mode != RunMode::PLOTTING) { - fatal_error( - fmt::format("Settings XML file '{}' does not exist! In order " - "to run OpenMC, you first need a set of input files; at a " - "minimum, this " - "includes settings.xml, geometry.xml, and materials.xml " - "or a single XML file containing all of these files. " - "Please consult " - "the user's guide at https://docs.openmc.org for further " - "information.", - filename)); + fatal_error("Could not find any XML input files! In order to run OpenMC, " + "you first need a set of input files; at a minimum, this " + "includes settings.xml, geometry.xml, and materials.xml or a " + "single model XML file. Please consult the user's guide at " + "https://docs.openmc.org for further information."); } else { // The settings.xml file is optional if we just want to make a plot. return;