From 71830845d4bfbe8015abbf7e35e72b14ed08087c Mon Sep 17 00:00:00 2001 From: Ethan Dalool Date: Sun, 7 Nov 2021 18:52:50 -0800 Subject: [PATCH] Add note that get_objects_by_id does not raise. --- voussoirkit/worms.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/voussoirkit/worms.py b/voussoirkit/worms.py index f7a5491..d45833c 100644 --- a/voussoirkit/worms.py +++ b/voussoirkit/worms.py @@ -199,6 +199,10 @@ class Database(metaclass=abc.ABCMeta): This is better than calling get_object_by_id in a loop because we can use a single SQL select to get batches of up to 999 items. + This method does not raise exceptions for IDs that are not present in + the database. You will need to compare the set of returned objects with + the set of requested IDs. + Note: The order of the output is not guaranteed to match the order of the input. Consider using get_objects_by_sql if that is a necessity. '''