diff --git a/core_pe/cache.py b/core_pe/cache.py index e7f97cc7..db95fb0c 100644 --- a/core_pe/cache.py +++ b/core_pe/cache.py @@ -81,9 +81,9 @@ class Cache(object): try: self.con.execute(sql, [value, key]) except sqlite.OperationalError: - logging.warning('Picture cache could not set %r for key %r', value, key) + logging.warning('Picture cache could not set value for key %r', key) except sqlite.DatabaseError as e: - logging.warning('DatabaseError while setting %r for key %r: %s', value, key, str(e)) + logging.warning('DatabaseError while setting value for key %r: %s', key, str(e)) def _create_con(self, second_try=False): def create_tables(): diff --git a/core_pe/matchbase.py b/core_pe/matchbase.py index 87eb43b2..e3e5534e 100644 --- a/core_pe/matchbase.py +++ b/core_pe/matchbase.py @@ -34,8 +34,9 @@ def prepare_pictures(pictures, cache_path, j=job.nulljob): prepared = [] # only pictures for which there was no error getting blocks try: for picture in j.iter_with_progress(pictures, tr("Analyzed %d/%d pictures")): - picture.dimensions picture.unicode_path = str(picture.path) + logging.debug("Analyzing picture at {}".format(picture.unicode_path)) + picture.dimensions # pre-read dimensions try: if picture.unicode_path not in cache: blocks = picture.get_blocks(BLOCK_COUNT_PER_SIDE)