Hello! I wanted to give an update as it’s been a while since I last posted: I spent some time debugging another segfault, this time caused by the test_can_save_and_load test in base_config.py, where more than one experiment was created in a single test, and management of the simulator environment wasn’t correctly handled. When I ran the test on its own it was successful, but running it with the other tests in the file caused the segfault. Commenting out the second with context manager/experiment block also avoided the issue.
As before, the error happened outside the python scope in the clean up logic of the underlying C++ libraries, triggered by incorrect resource management.
To fix it, I moved the Dataloader close() method, which handles closing the environment, to the MontyExperiment class, which makes sense as that’s now where we’re instantiating the environment in the first place.
Tests are all passing now, and I’m onto step 3 of Tristan’s outline.