Enea Bastianini claimed pole for the second Grand Prix in a row, setting a new lap record in the process.