summaryrefslogtreecommitdiff
path: root/prolog/problems/license_plates
diff options
context:
space:
mode:
Diffstat (limited to 'prolog/problems/license_plates')
-rw-r--r--prolog/problems/license_plates/checklicenseplate_3/common.py2
-rw-r--r--prolog/problems/license_plates/firstminus_2/common.py2
-rw-r--r--prolog/problems/license_plates/genexp_2/common.py2
-rw-r--r--prolog/problems/license_plates/getdigits_2/common.py2
-rw-r--r--prolog/problems/license_plates/joindigits_2/common.py2
5 files changed, 5 insertions, 5 deletions
diff --git a/prolog/problems/license_plates/checklicenseplate_3/common.py b/prolog/problems/license_plates/checklicenseplate_3/common.py
index 028b077..3a403d2 100644
--- a/prolog/problems/license_plates/checklicenseplate_3/common.py
+++ b/prolog/problems/license_plates/checklicenseplate_3/common.py
@@ -81,7 +81,7 @@ def test(code, aux_code):
for query, answers in test_cases:
if prolog.engine.check_answers(engine_id, query=query, answers=answers, timeout=1.0):
n_correct += 1
- except:
+ except socket.timeout:
pass
finally:
if engine_id:
diff --git a/prolog/problems/license_plates/firstminus_2/common.py b/prolog/problems/license_plates/firstminus_2/common.py
index e4b09a0..dd967b6 100644
--- a/prolog/problems/license_plates/firstminus_2/common.py
+++ b/prolog/problems/license_plates/firstminus_2/common.py
@@ -32,7 +32,7 @@ def test(code, aux_code):
for query, answers in test_cases:
if prolog.engine.check_answers(engine_id, query=query, answers=answers, timeout=1.0):
n_correct += 1
- except:
+ except socket.timeout:
pass
finally:
if engine_id:
diff --git a/prolog/problems/license_plates/genexp_2/common.py b/prolog/problems/license_plates/genexp_2/common.py
index 28d9b57..4e2ebdf 100644
--- a/prolog/problems/license_plates/genexp_2/common.py
+++ b/prolog/problems/license_plates/genexp_2/common.py
@@ -53,7 +53,7 @@ def test(code, aux_code):
for query, answers in test_cases:
if prolog.engine.check_answers(engine_id, query=query, answers=answers, timeout=1.0):
n_correct += 1
- except:
+ except socket.timeout:
pass
finally:
if engine_id:
diff --git a/prolog/problems/license_plates/getdigits_2/common.py b/prolog/problems/license_plates/getdigits_2/common.py
index 68b28b8..33c45c6 100644
--- a/prolog/problems/license_plates/getdigits_2/common.py
+++ b/prolog/problems/license_plates/getdigits_2/common.py
@@ -37,7 +37,7 @@ def test(code, aux_code):
for query, answers in test_cases:
if prolog.engine.check_answers(engine_id, query=query, answers=answers, timeout=1.0):
n_correct += 1
- except:
+ except socket.timeout:
pass
finally:
if engine_id:
diff --git a/prolog/problems/license_plates/joindigits_2/common.py b/prolog/problems/license_plates/joindigits_2/common.py
index ed08b28..ed284e7 100644
--- a/prolog/problems/license_plates/joindigits_2/common.py
+++ b/prolog/problems/license_plates/joindigits_2/common.py
@@ -36,7 +36,7 @@ def test(code, aux_code):
for query, answers in test_cases:
if prolog.engine.check_answers(engine_id, query=query, answers=answers, timeout=1.0):
n_correct += 1
- except:
+ except socket.timeout:
pass
finally:
if engine_id: