Skip to content

Commit

Permalink
Merge pull request #4861 from voxel51/robust-migration
Browse files Browse the repository at this point in the history
Make v1.0.0 migration robust to in-progress terminations
  • Loading branch information
brimoor authored Sep 27, 2024
2 parents 3e1a9b1 + ba40b0e commit 7ebfd94
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions fiftyone/migrations/revisions/v1_0_0.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ def up(db, dataset_name):
added_last_modified_at_frames,
) = _up_fields(dataset_name, frame_fields)

db.datasets.replace_one(match_d, dataset_dict)

# Populate `Sample.created_at` values
sample_collection_name = dataset_dict.get("sample_collection_name", None)
if sample_collection_name:
Expand All @@ -62,6 +60,8 @@ def up(db, dataset_name):
now,
)

db.datasets.replace_one(match_d, dataset_dict)


def down(db, dataset_name):
pass
Expand Down

0 comments on commit 7ebfd94

Please sign in to comment.