Skip to content

Commit

Permalink
#810 Add a specific error if Log::addLogFileContentInMapData() method…
Browse files Browse the repository at this point in the history
… can not open the input log file

Signed-off-by: Dimitri Baron <[email protected]>
  • Loading branch information
barondim committed Jan 17, 2025
1 parent f83a962 commit 1cac7e3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions etc/Dictionaries/DFLError_en_GB.dic
Original file line number Diff line number Diff line change
Expand Up @@ -44,3 +44,4 @@ ConnexityError = slack node of id %1% not present in main conn
NetworkHasNoRegulatingGenerator = network file %1% has no generator regulating voltage in the main connex component
SlackNodeNotFound = no slack node found for network '%1%'
MissingFinalStateIIDMFile = steady state simulation did not generate a final state IIDM file
FailToOpenLogFile = failed to open %1% log file
2 changes: 1 addition & 1 deletion sources/Common/src/Log.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ Log::addLogFileContentInMapData(const std::string& logFileRelativePath,
mapData[logFileRelativePath] = strStream.str();
programLogFileStream.close();
} else {
std::cerr << "failed to open " << logFileAbsolutePath << '\n';
throw Error(FailToOpenLogFile, logFileAbsolutePath);
}
}

Expand Down

0 comments on commit 1cac7e3

Please sign in to comment.