Alerts are displayed, but disappear before I can accept it

For your information, see this

To help protect your account, Google doesn’t let you sign in from some browsers. Google might stop sign-ins from browsers that:

Are being controlled through software automation rather than a human

This is a proof that Chrome behaves specially when it is controlled by selenium.

I guess browsers may do something special for Alert. Alert dialog could be risky because malicious software may use Alerts to invade your peaceful life.