Closed alexdriedger closed 2 years ago
Thanks for the find! Took me a while to get to this. I successfully defended my PhD on Friday.
I've corrected the issue in the most recent commit.
Any other issues/bugs you have encountered would be great to see! I'll try to fix them as quickly as I can. I think the library here is starting to become fairly robust/reliable.
Congrats on the defense! I ran the test again and it passed with the latest update 👍
https://github.com/manny405/sapai/blob/6e7ef0ab272b6cb3348711e20537514c599363e6/sapai/pets.py#L268
There appears to be a bug in
buy_food_trigger
when purchasing food. I'm not sure how these triggers work, so I'm not sure how to fix it, but the line above is where the exception is raised. Here is a minimal test to reproduce it. I tested it with rabbit and worm, and apple and honey and all of those combinations threw exceptions.As a side note, I found this by writing an agent to take random actions. I've also ran into some other bugs as well and will try to create reproducible tests for them as well.