Skip to content

Commit

Permalink
💬 Update type hints
Browse files Browse the repository at this point in the history
  • Loading branch information
arafune committed Feb 13, 2024
1 parent 6e38f05 commit 5a6601c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ build:

# Build documentation in the "docs/" directory with Sphinx
sphinx:
configuration: docs/conf.py
configuration: docs/source/conf.py
# You can configure Sphinx to use a different builder, for instance use the dirhtml builder for simpler URLs
# builder: "dirhtml"
# Fail on all warnings to avoid broken references
Expand Down
2 changes: 1 addition & 1 deletion docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
import os
import sys

sys.path.append(os.path.abspath("../arpes"))
sys.path.append(os.path.abspath("../src/arpes"))
sys.path.append(os.path.abspath(".."))

import datetime
Expand Down
6 changes: 4 additions & 2 deletions src/arpes/endstations/plugin/ALG_spin_ToF.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,8 +87,9 @@ def load_SToF_hdf5(self, scan_desc: SCANDESC | None = None) -> xr.Dataset:
"""
if scan_desc is None:
scan_desc = {}
data_loc = Path(scan_desc.get("path", scan_desc.get("file")))
data_loc = Path(scan_desc.get("path", scan_desc.get("file", "")))
if not data_loc.is_absolute():
assert arpes.config.DATA_PATH is not None
data_loc = Path(arpes.config.DATA_PATH) / data_loc

f = h5py.File(data_loc, "r")
Expand Down Expand Up @@ -120,8 +121,9 @@ def load_SToF_fits(self, scan_desc: SCANDESC) -> xr.Dataset:
Args:
scan_desc: [TODO:description]
"""
data_loc = Path(scan_desc.get("path", scan_desc.get("file")))
data_loc = Path(scan_desc.get("path", scan_desc.get("file", "")))
if not data_loc.exists():
assert arpes.config.DATA_PATH is not None
data_loc = Path(arpes.config.DATA_PATH) / data_loc

hdulist = fits.open(data_loc)
Expand Down

0 comments on commit 5a6601c

Please sign in to comment.