Skip to content

Improve monotonic assert + fix black formatting in vscode #162

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

Merged
merged 4 commits into from
Jan 20, 2023
Merged
Show file tree
Hide file tree
Changes from all 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
Original file line number Diff line number Diff line change
Expand Up @@ -780,7 +780,11 @@ def _construct_hf_data_dict(
hf_series = self._to_hf_series(x=dc.x, y=dc.y)

# Checking this now avoids less interpretable `KeyError` when resampling
assert hf_series.index.is_monotonic_increasing
assert hf_series.index.is_monotonic_increasing, (
"In order to perform time series aggregation, the data must be "
"sorted in time; i.e., the x-data must be (non-strictly) "
"monotonically increasing."
)

# As we support prefix-suffixing of downsampled data, we assure that
# each trace has a name
Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ ignore = ["E501"] # Never enforce `E501` (line length violations).

# Formatting
[tool.black]
color = true
line-length = 88

# Sort imports
Expand Down