Skip to content

Commit c4cc3de

Browse files
committed
Stricter to use not none
1 parent 678523d commit c4cc3de

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

src/murfey/workflows/spa/flush_spa_preprocess.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ def register_grid_square(
6565
if grid_square_params.width is not None:
6666
grid_square_params.width_scaled = int(grid_square_params.width / 7.8)
6767

68-
if grid_square_params.sample:
68+
if grid_square_params.sample is not None:
6969
dcg = murfey_db.exec(
7070
select(DataCollectionGroup)
7171
.where(DataCollectionGroup.session_id == session_id)

tests/workflows/spa/test_flush_spa_preprocess.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ def test_register_grid_square_update_add_nothing(
6969
dcg = DataCollectionGroup(
7070
id=1,
7171
session_id=ExampleVisit.murfey_session_id,
72-
tag="session_tag",
72+
tag="processing_tag",
7373
atlas_id=90,
7474
sample=2,
7575
)
@@ -88,7 +88,7 @@ def test_register_grid_square_update_add_nothing(
8888
murfey_db_session.commit()
8989

9090
# Parameters to update with
91-
new_parameters = GridSquareParameters(tag="session_tag")
91+
new_parameters = GridSquareParameters(tag="session_tag", sample=2)
9292

9393
# Run the registration
9494
flush_spa_preprocess.register_grid_square(

0 commit comments

Comments
 (0)