<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _calculate_unique_id(self, xblock):
 """ Provide a default value for fields with `default=UNIQUE_ID`. Returned string is a SHA1 hex digest that is deterministically calculated for the field in its given scope. """

        key = scope_key(self, xblock)
        return hashlib.sha1(key.encode('utf-8')).hexdigest()