Skip to content

Commit 8e18343

Browse files
Include users in db standardization script (#121)
Co-authored-by: Andrew Howe <arhowe00@gmail.com>
1 parent 4be97d9 commit 8e18343

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

scripts/standardize_database.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -79,3 +79,9 @@
7979
run_ids = db.get_run_ids(subject_id, session_id)
8080
db.write_run_ids(subject_id, session_id, run_ids)
8181
# (Runs are read only at the moment so it's just the runs.json and no individual runs to standardize)
82+
83+
db.write_user_ids(db.get_user_ids())
84+
for user_id in db.get_user_ids():
85+
user = db.load_user(user_id)
86+
assert user_id == user.id
87+
db.write_user(user, on_conflict=OnConflictOpts.OVERWRITE)

0 commit comments

Comments
 (0)