v1.90.0
Added
sampling_contextparameter onbn.run(): an optional context manager that wraps only the sampling phase. Its__exit__is guaranteed to run before the Panel/Bokeh server starts, so external resources (DB pools, GPU handles, simulators) are released while nothing blocks.saveandpublishstill execute inside the context. Defaults toNone(fully backward-compatible).