diff --git a/Manifest.toml b/Manifest.toml
index 846393d1bad59809863a236de83a9c78ec1155d4..0424e0330a3f3d206b3fb49261580b2adad85688 100644
--- a/Manifest.toml
+++ b/Manifest.toml
@@ -312,7 +312,7 @@ version = "1.9.0"
 
 [[deps.PlanarLarvae]]
 deps = ["DelimitedFiles", "HDF5", "JSON3", "LinearAlgebra", "MAT", "Meshes", "OrderedCollections", "Random", "SHA", "StaticArrays", "Statistics", "StatsBase", "StructTypes"]
-git-tree-sha1 = "fe89d5f592c8ba763a13330cde6696f721f828c7"
+git-tree-sha1 = "6d1f48b16424c847829a325cc9f49329becf9cf8"
 repo-rev = "dev"
 repo-url = "https://gitlab.pasteur.fr/nyx/planarlarvae.jl"
 uuid = "c2615984-ef14-4d40-b148-916c85b43307"
diff --git a/src/LarvaDatasets.jl b/src/LarvaDatasets.jl
index fa8a0f1efc5b288759edd8d063978e59d4afbda4..2f6f45c6d3e9aeaf4718d97e8bf3062c187366a9 100644
--- a/src/LarvaDatasets.jl
+++ b/src/LarvaDatasets.jl
@@ -626,9 +626,8 @@ function new_write_larva_dataset_hdf5(output_dir, input_data;
     win = window_length # shorter name to keep next line within the allowed text width
     output_file = "larva_dataset_$(date)_$(win)_$(win)_$(total_sample_size).hdf5"
     output_file = joinpath(output_dir, output_file)
-    c = Threads.Condition()
     h5open(output_file, "w") do h5
-        create_group(h5, "samples")
+        g = create_group(h5, "samples")
         sample(loader, :spine) do _, file, counts, segments
             sampleid, nsegments = counts
             @assert length(segments) == nsegments