I've recently ran into:
Unexpected scopes found in folder 'TrivialDrive_v2\mobile\build\intermediates\transforms\dexMerger\debug'. Required: EXTERNAL_LIBRARIES. Found: EXTERNAL_LIBRARIES, PROJECT, SUB_PROJECTS
which has a fix suggested here, which fixes it but now, the debugger won't stop on breakpoints (tested on the main activity's onCreate()).
Other suggestions, mention adding:
multiDexEnabled true //important
to defaultConfig {} in the gradle build files. Already have that (ran into this earlier), but execution still doesn't stop at breakpoints. Initially it did. Why?
The app is trivial drive v2, extended with predefined testing SKUs (android.test.purchased, etc.)
Deleting the directories .idea and .gradle in the project's root directory, invalidating caches and restarting android worked (at least for now).