Test: a cancel during the live stills pre-pass hold ends the collection
Build Packages / Unit tests (push) Failing after 1h43m30s
Build Packages / build:jfjoch:rocky8:cuda (push) Successful in 31m56s
Build Packages / HDF5 consumer tests (DIALS, XDS) (push) Successful in 29m41s
Build Packages / Generate python client (push) Successful in 58s
Build Packages / Create release (push) Successful in 8s
Build Packages / build:portable:linux-x86_64:nocuda (push) Successful in 16m29s
Build Packages / build:portable:windows-x86_64:nocuda (push) Successful in 25m50s
Build Packages / build:portable:windows-x86_64:cuda (push) Successful in 29m31s
Build Packages / build:jfjoch:ubuntu2204:cuda (push) Successful in 26m23s
Build Packages / Build documentation (push) Successful in 45s
Build Packages / build:portable:macos-arm64:nocuda (push) Successful in 5m27s
Build Packages / build:rugnux:linux-aarch64:cuda (push) Successful in 11m19s
Build Packages / build:jfjoch:ubuntu2204:nocuda (push) Successful in 26m26s
Build Packages / build:portable:linux-x86_64:cuda (push) Successful in 21m42s
Build Packages / build:jfjoch:rocky8:nocuda (push) Successful in 31m18s
Build Packages / build:jfjoch:rocky9:nocuda (push) Successful in 32m12s
Build Packages / build:jfjoch:rocky8:cuda-sls9 (push) Successful in 32m9s
Build Packages / build:jfjoch:ubuntu2404:nocuda (push) Successful in 27m0s
Build Packages / build:jfjoch:rocky9:cuda-sls9 (push) Successful in 33m42s
Build Packages / build:jfjoch:ubuntu2404:cuda (push) Successful in 30m3s
Build Packages / build:jfjoch:rocky9:cuda (push) Successful in 33m6s
Build Packages / Validation Battery (push) Successful in 44m48s

On the simulated device, a 900-image live stills collection with a cell is cancelled while
its frames are held for the pre-pass; the collection has to stop.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01HVeDQsU5a8AJUdJPgWevAK
This commit is contained in:
leonarski_fandClaude Opus 5.5 committed 2026-11-10 08:39:03 +01:00
1 parent 2b6291c20f
commit bb4f64a010
1 file changed
+33
+33
View File
@@ -253,6 +253,39 @@ TEST_CASE("JFJochIntegrationTest_ZMQ_GPUStills_writer_down", "[JFJochReceiver]")
REQUIRE_NOTHROW(writer_future.get());
}
TEST_CASE("JFJochIntegrationTest_GPUStills_cancel_during_prepass", "[JFJochReceiver]") {
// A cancel while the frames are held for the pre-pass ends the collection.
Logger logger(Catch::getResultCapture().getCurrentTestName());
DiffractionExperiment experiment(DetJF4M());
experiment.ImagesPerTrigger(900).NumTriggers(1).UseInternalPacketGenerator(true)
.FilePrefix("gpu_stills_cancel").JungfrauConvPhotonCnt(false)
.DetectorDistance_mm(75).BeamY_pxl(1136).BeamX_pxl(1090).IncidentEnergy_keV(12.4)
.SetUnitCell(UnitCell{.a = 36.9, .b = 78.95, .c = 78.95, .alpha =90, .beta = 90, .gamma = 90});
PixelMask pixel_mask(experiment);
AcquisitionDeviceGroup aq_devices;
aq_devices.Add(std::make_unique<HLSSimulatedDevice>(0, 64));
NonePusher pusher;
JFJochReceiverService service(aq_devices, logger, pusher);
service.NumThreads(4);
service.Indexing(experiment.GetIndexingSettings());
service.RugnuxLive(true, nullptr, 4, 60);
service.Start(experiment, pixel_mask, nullptr);
std::this_thread::sleep_for(std::chrono::seconds(10));
const auto t0 = std::chrono::steady_clock::now();
service.Cancel(false);
try {
service.Stop();
} catch (const JFJochException &) {}
const double stop_s = std::chrono::duration<double>(std::chrono::steady_clock::now() - t0).count();
logger.Info("Stopped {:.1f} s after the cancel", stop_s);
CHECK(stop_s < 120.0);
}
TEST_CASE("JFJochIntegrationTest_ZMQ_crystal_spot_and_index_refinement", "[JFJochReceiver]") {
Logger logger(Catch::getResultCapture().getCurrentTestName());