So first of all: Awesome mod. I really like the idea and it has been implemented in a nice way.
But there seems to be a bug which crashes my game. So after some testing and guessing I came to the conclusion that it arises from bots, trying to either scan or enter a not yet generated chunk (couldn't yet pinpoint which one it was). So I did some messing around with your code and it seems like I´ve found a solution that works, even though it is slightly performance heavy.
So I added into the squad.lua file in the robolib folder the following lines right after line 373
chunkposition = {x=math.floor(position.x/32+0.5), y=math.floor(position.y/32+0.5)}
xp=-4
while xp < 5 do
yp=-4
while yp < 5 do
if not game.surfaces[1].is_chunk_generated(chunkposition) then
game.surfaces[1].request_to_generate_chunks(position, 128)
xp=5
yp=5
end
yp=yp+1
end
xp=xp+1
end
So essentially this code just checks if the nearby chunks are generated and if not it requests that the get generated.
I've been running my game now for many hours consecutive and let them hunt down bitters and up to now the crash didn´t reappear.
I hope this helps with the development of the mod.
Anyway. Keep up the good work.