Hey guys and gals,
This issue will be fixed with the 1.07 patch. There are a lot of smaller changes, that weren't explicitly listed in the patch notes.
Also, this will be a retroactive fix, meaning it will fix the failed quest even if you already finished "Cave of Dreams" and "King's Gambit" and have "Cave of Dreams" marked as 'Failed' in your journal.