Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions concoredocker.java
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ public class concoredocker {
private static Map<String, Object> params = new HashMap<>();
// simtime as double to preserve fractional values (e.g. "[0.0, ...]")
private static double simtime = 0;
private static int maxtime;
private static double maxtime;

public static void main(String[] args) {
try {
Expand Down Expand Up @@ -109,12 +109,12 @@ private static Map<String, Object> parseFile(String filename) throws IOException
* Sets maxtime from concore.maxtime file, or uses defaultValue if file not found.
* Catches both IOException and RuntimeException to match Python safe_literal_eval.
*/
private static void defaultMaxTime(int defaultValue) {
private static void defaultMaxTime(double defaultValue) {
try {
String content = new String(Files.readAllBytes(Paths.get(inpath + "1/concore.maxtime")));
Object parsed = literalEval(content.trim());
if (parsed instanceof Number) {
maxtime = ((Number) parsed).intValue();
maxtime = ((Number) parsed).doubleValue();
} else {
maxtime = defaultValue;
}
Expand Down