Build works but code breaks

I cloned a git repo with source code and a working build and it was working properly. However, when I made a new build in cocos creator, a part of the game stops working. There is a section with dragging shapes onto a tangram puzzle that won’t work (the piece won’t drag with the mouse).

Has anyone run into an issue where the build goes through with no errors, but a piece of the code stops working? There doesn’t seem to be any concrete difference between the working build code and the new build code.

If you can build without error but error occurs mid game, probably there is some logic error, maybe you tried to get some properties from an undefined object etc.
If the build works but preview breaks, probably you are using some functions that are limited to build only, use if (CC_BUILD) to enclose those functions

in your case could be the first problem, can you show the error and more details? can you run that part in preview?