Skip to content

Commit

Permalink
test path
Browse files Browse the repository at this point in the history
  • Loading branch information
btylerburton committed Jan 17, 2024
1 parent 316c2f5 commit d7ae026
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions harvester/harvest.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,9 @@

ckan = ckanapi.RemoteCKAN(os.getenv("CKAN_URL"), apikey=os.getenv("CKAN_API_TOKEN_DEV"))

ROOT_DIR = Path(__file__).parents[1]
dirname = os.path.dirname
SCHEMA_PATH = os.path.join(dirname(dirname(__file__)), os.path.join('data', 'dcatus',
'schemas/dataset.json'))


@dataclass
Expand All @@ -34,9 +36,7 @@ class HarvestSource:
_waf_config: dict = field(default_factory=lambda: {})
_extra_source_name: str = "harvest_source_name" # TODO: update this
_dataset_schema: dict = field(
default_factory=lambda: open_json(
ROOT_DIR / "data" / "dcatus" / "schemas" / "dataset.json"
)
default_factory=lambda: open_json(SCHEMA_PATH)
)

# not read-only because these values are added after initialization
Expand Down

0 comments on commit d7ae026

Please sign in to comment.