Skip to content

Commit

Permalink
Add more logging while saving annotations
Browse files Browse the repository at this point in the history
  • Loading branch information
manthey committed May 17, 2024
1 parent 7f38fe2 commit e8c4590
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
.g-item-info-header
i.icon-picture
span Image Viewer
select.form-control.input-sm.image-viewer-control
select#image-viewer-control.form-control.input-sm.image-viewer-control
each viewer in viewers
option(value=viewer.name) #{viewer.label}
.image-controls
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -978,7 +978,10 @@ def insertElements(doc, *args, **kwargs):
annotation.pop('groups', None)
self.injectAnnotationGroupSet(annotation)

logger.debug('Saved annotation in %5.3fs' % (time.time() - starttime))
if annotation['annotation'].get('elements') is not None:
logger.info(
'Saved annotation in %5.3fs with %d element(s)',
time.time() - starttime, len(annotation['annotation']['elements']))
events.trigger('large_image.annotations.save_history', {
'annotation': annotation,
}, asynchronous=True)
Expand Down

0 comments on commit e8c4590

Please sign in to comment.