Skip to content

Commit

Permalink
Fix circular imports
Browse files Browse the repository at this point in the history
  • Loading branch information
rdimaio committed Nov 7, 2024
1 parent d714662 commit 404b4f2
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 9 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"

[project]
name = "belleii_rucio_policy_package"
version = "0.0.3"
version = "0.0.4"
authors = [
{ name="Belle II", email="[email protected]" },
]
Expand Down
4 changes: 2 additions & 2 deletions src/belleii_rucio_policy_package/lfn2pfn.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from rucio.rse.translation import RSEDeterministicTranslation
import rucio.rse.translation

class BelleIIRSEDeterministicTranslation(RSEDeterministicTranslation):
class BelleIIRSEDeterministicTranslation(rucio.rse.translation.RSEDeterministicTranslation):

def __init__(self, rse=None, rse_attributes=None, protocol_attributes=None):
"""
Expand Down
4 changes: 2 additions & 2 deletions src/belleii_rucio_policy_package/non_deterministic_pfn.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
from typing import Optional

from rucio.common.utils import NonDeterministicPFNAlgorithms
import rucio.common.utils


class BelleIINonDeterministicPFNAlgorithm(NonDeterministicPFNAlgorithms):
class BelleIINonDeterministicPFNAlgorithm(rucio.common.utils.NonDeterministicPFNAlgorithms):
"""
Belle II specific non-deterministic PFN algorithm
"""
Expand Down
4 changes: 2 additions & 2 deletions src/belleii_rucio_policy_package/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@

from jsonschema import ValidationError, validate

from rucio.common.exception import InvalidObject
import rucio.common.exception

ACCOUNT_LENGTH = 25

Expand Down Expand Up @@ -405,4 +405,4 @@ def validate_schema(name, obj):
if obj:
validate(obj, SCHEMAS.get(name, {}))
except ValidationError as error: # NOQA, pylint: disable=W0612
raise InvalidObject(f'Problem validating {name}: {error}')
raise rucio.common.exception.InvalidObject(f'Problem validating {name}: {error}')
5 changes: 3 additions & 2 deletions src/belleii_rucio_policy_package/scope.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
from typing import TYPE_CHECKING, Optional
from rucio.common.utils import ScopeExtractionAlgorithms

import rucio.common.utils

if TYPE_CHECKING:
from collections.abc import Sequence

class BelleIIScopeExtractionAlgorithm(ScopeExtractionAlgorithms):
class BelleIIScopeExtractionAlgorithm(rucio.common.utils.ScopeExtractionAlgorithms):
def __init__(self) -> None:
"""
Initialises scope extraction algorithm object
Expand Down

0 comments on commit 404b4f2

Please sign in to comment.