Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Dec 19, 2024
1 parent 5a955b1 commit 40f36dc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/nwbinspector/checks/_time_series.py
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ def check_timestamp_of_the_first_sample_is_not_negative(time_series: TimeSeries)
if first_timestamp < 0:
message = (
"Timestamps should not be negative. This usually indicates a temporal misalignment of the data. "
" It is recommended to align the `session_start_time` or `timestamps_reference_time` to be the earliest time value that occurs in the data, and shift all other signals accordingly."
" It is recommended to align the `session_start_time` or `timestamps_reference_time` to be the earliest time value that occurs in the data, and shift all other signals accordingly."
)
return InspectorMessage(message=message)

Expand Down
2 changes: 1 addition & 1 deletion tests/unit_tests/test_time_series.py
Original file line number Diff line number Diff line change
Expand Up @@ -278,7 +278,7 @@ def test_check_timestamp_of_the_first_sample_is_not_negative_with_timestamps_fai
time_series = pynwb.TimeSeries(name="test_time_series", unit="test_units", data=[1, 2, 3], timestamps=[-1, 0, 1])
message = (
"Timestamps should not be negative. This usually indicates a temporal misalignment of the data. "
" It is recommended to align the `session_start_time` or `timestamps_reference_time` to be the earliest time value that occurs in the data, and shift all other signals accordingly."
" It is recommended to align the `session_start_time` or `timestamps_reference_time` to be the earliest time value that occurs in the data, and shift all other signals accordingly."
)
assert check_timestamp_of_the_first_sample_is_not_negative(time_series) == InspectorMessage(
message=message,
Expand Down

0 comments on commit 40f36dc

Please sign in to comment.