Physics bugs usually fall into two categories: an object pair collided/didn't collide when it shouldn't have/should have, or the objects collided but something unexpected happened after the fact. The former case is generally easier to debug; it is often either due to mistakes in the Collision Matrix, incorrect Layers used in raycasting, or object colliders being the wrong size or shape. The latter case is often much more challenging to resolve because of three big problems:
- Determining which collided objects caused the issue
- Determining the conditions of the collision just before the resolution
- Reproducing the collision
Any of these three pieces of information would make resolution much easier, but they can all be difficult ...