aboutsummaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorSébastien Dailly <sebastien@dailly.me>2025-02-13 18:30:34 +0100
committerSébastien Dailly <sebastien@dailly.me>2025-02-13 18:30:43 +0100
commit67320d8f04e1f302306b9aafdaaf4bafcf443839 (patch)
tree48ab0f3e3a500d44309b9cf6d440c3f8ecce31ee /lib
parentd3e0821b9c1551177afb34220d951b087acdea22 (diff)
Ignore the dates outside of the julian period
Diffstat (limited to 'lib')
-rw-r--r--lib/sql/date.ml5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/sql/date.ml b/lib/sql/date.ml
index e8933c7..b1a8d6a 100644
--- a/lib/sql/date.ml
+++ b/lib/sql/date.ml
@@ -14,6 +14,11 @@ let f : Sqlite3.Data.t -> Sqlite3.Data.t -> Sqlite3.Data.t =
in
Sqlite3.Data.INT period
with
+ | CalendarLib.Date.Out_of_bounds ->
+ prerr_endline
+ @@ Printf.sprintf "Date ignored (outside of Julian period): %s"
+ content;
+ Sqlite3.Data.NULL
| Invalid_argument e ->
prerr_endline e;
Sqlite3.Data.NULL)