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.
Thanks Viviane. Yes, I’m happy to move that PR out of draft mode - I’ll ensure it’s ready and do that within the next two days. I’ve been conscious of how large this PR is getting, so breaking the work into smaller steps feels like a great plan.
It’s my pleasure to do this - I’ve really enjoyed learning more about the codebase through this task!
Anna
As your PR is now merged, I thought you may enjoy this Thank you for contributing! You are the first to check off a large item on our future work roadmap