After building and removing entities some drones will not return to the players inventory.
I originally found the bug in my heavily modded playthrough. I then did a test for the bug using a fresh install of Factorio 0.18.22 and made a save with only two mods using Construction Drones 0.5.4 and Creative Items 1.5.0.
I can replicate the bug by using a blueprint on ore patches. After building the blueprint some drones will not return to the players inventory.
I can then replicate the bug again after using the Deconstruction Planner. Again, some of the drones will not return to the players inventory.
Save File: https://drive.google.com/open?id=1a8OP54ibS5TRn5zONL2BTYpTkTNvHKsQ