Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move timeintervals schema to schemas/ dir to include in build #573

Merged
merged 5 commits into from
Sep 21, 2023
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
# (Upcoming)

### Fixes

* Reorganize timeintervals schema to reside in `schemas/` dir to ensure its inclusion in package build. [PR #573](https://github.com/catalystneuro/neuroconv/pull/573)

# v0.4.3

### Fixes
Expand Down
3 changes: 2 additions & 1 deletion src/neuroconv/datainterfaces/text/timeintervalsinterface.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import os
from abc import abstractmethod
from pathlib import Path
from typing import Dict, Optional

import numpy as np
Expand Down Expand Up @@ -47,7 +48,7 @@ def get_metadata(self) -> dict:
return metadata

def get_metadata_schema(self) -> dict:
fpath = os.path.join(os.path.split(__file__)[0], "timeintervals.schema.json")
fpath = Path(__file__).parent / "../../schemas/timeintervals_schema.json"
CodyCBakerPhD marked this conversation as resolved.
Show resolved Hide resolved
return load_dict_from_file(fpath)

def get_original_timestamps(self, column: str) -> np.ndarray:
Expand Down
Loading