Uploaded image for project: 'Nuxeo Drive '
  1. Nuxeo Drive
  2. NXDRIVE-1258

Better handle unknown digest algorithms

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.1.1
    • Fix Version/s: 4.0.0
    • Component/s: GUI

      Description

      The Issue

      We should be more robust against custom digests that do not exist in the hashlib module. For instance, this is a bad example because it is related to a template, but to see the current behavior:

      2018-07-06 10:52:52 1139 123145491992576 ERROR    nxdrive.engine.processor Unknown error
      Traceback (most recent call last):
        File "nxdrive/engine/processor.pyc", line 248, in _execute
        File "nxdrive/engine/processor.pyc", line 1000, in _synchronize_remotely_created
        File "nxdrive/engine/processor.pyc", line 1055, in _create_remotely
        File "nxdrive/engine/processor.pyc", line 834, in _download_content
        File "nxdrive/client/remote_file_system_client.pyc", line 115, in stream_content
      Exception: Unknown digest algorithm for notInBinaryStore
      2018-07-06 10:52:52 1139 123145491992576 DEBUG    nxdrive.engine.workers Increasing error [SYNC_HANDLER__synchronize_remotely_created] ("Exception(u'Unknown digest algorithm for notInBinaryStore',)") for <StateRow[8] local_path=u'/.../body.html', remote_ref=u'defaultFileSystemItemFactory#default#xxx', local_state=u'unknown', remote_state=u'created', pair_state=u'remotely_created', filter_path=None>
      

      This will end on an unknown error in the error window. Not really helpful.

      The Fix

      Raise a custom exception and put the document in error with a clair message.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 5 hours
                  5h