No explanation-- other than from what you described-- sounds like a bug ate some of your bugs....
As to how to solve the prob-- I would be hesitant to use any 'chemical' for a number of reasons-- the most obvious-- health concerns in your house-- I doubt a one time chemical application will be sufficient-- probably would need multiple applications.
Also, residual chemical on the box or flies that can come into contact with your waters.... don't know how big of a threat this is, but I wouldn't want to be the guy that introduced a chemical to the habitat.....
Better solutions-- ($1.00)- pack fly box in seal-able bag? (a bit more $$$ up to 40 or 50.00, possibly)-New fly box?
where was the box stored? could you store it in a safer place?