Imposing disadvantage on another creature's attack, such as with Warding Flare or the Protection fighting style, is designed to happen when the attack is announced but before the roll is made. This is important because it can also be used to cancel advantage on the attack roll and helps avoid confusion about which of the cancelled advantage dice is the "correct" one.