Skip to content

test(reading): run the same-file virtual dataset tests serially - #181

Merged
Apollo3zehn merged 1 commit into
Apollo3zehn:devfrom
Blackclaws:test/vds-shared-state-collection
Aug 21, 2026
Merged

test(reading): run the same-file virtual dataset tests serially#181
Apollo3zehn merged 1 commit into
Apollo3zehn:devfrom
Blackclaws:test/vds-shared-state-collection

Conversation

@Blackclaws

Copy link
Copy Markdown
Contributor

VirtualDatasetSameFileTests prepares its files through TestUtils.PrepareTestFile, which drives the HDF5 C library, and that library's file tracking is process-global. Running the class in parallel with everything else therefore fails intermittently:

System.IO.IOException : The process cannot access the file '/tmp/tmpoCdT0D.tmp'
because it is being used by another process.
   at PureHDF.VOL.Native.NativeFile.InternalOpenAsync(...)
   at PureHDF.Tests.Reading.VirtualDatasetSameFileTests.CanReadAVirtualDatasetWhoseSourceIsInTheSameFile()

Both tests in the class hit it, and it reproduced in roughly 2 of 8 full-suite runs here on dev, on both net8.0 and net10.0. Each one passes when the class is run on its own.

[Collection(SharedHdf5StateCollection.Name)] is what the other classes in this position already use — H5MemoryDriverTests, H5MemoryMappedFileDriverTests, AsyncDatasetReadTests, AsyncRegionReferenceTests and FilterTests all opt in. This class looks to have simply been missed.

Sent separately from #179 and #180 because it is unrelated to either, but worth landing first: until it does, it will flake in their CI runs too.

TestUtils.PrepareTestFile drives the HDF5 C library, whose file tracking is
process-global, so these tests fail intermittently against whatever else is
creating a file at the same moment:

  System.IO.IOException : The process cannot access the file '/tmp/tmpXXXXXX.tmp'
  because it is being used by another process.

Every other class that prepares a file through the C library already opts into
SharedHdf5StateCollection.

Co-Authored-By: Claude <noreply@anthropic.com>
@Apollo3zehn
Apollo3zehn merged commit 82cea5c into Apollo3zehn:dev Aug 21, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants