Skip to content

Commit

Permalink
localize an import the lead to circular imports
Browse files Browse the repository at this point in the history
This commit moves an import from global scope to
local scope to prevent a circular import error.
  • Loading branch information
christian-monch committed Sep 29, 2022
1 parent 6e24c4c commit 544a954
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions datalad_metalad/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
import os
import hashlib

from datalad.support.digests import Digester


__docformat__ = 'restructuredtext'

Expand Down Expand Up @@ -82,6 +80,8 @@ def get_file_id(rec):
DataLad-recognized ID. This prefix is defined in the main JSON-LD
context defintion.
"""
from datalad.support.digests import Digester

id_ = rec['key'] if 'key' in rec else 'SHA1-s{}--{}'.format(
rec['bytesize'] if 'bytesize' in rec
else 0 if rec['type'] == 'symlink'
Expand Down

0 comments on commit 544a954

Please sign in to comment.