MotoGP championship leader Pecco Bagnaia will have to fight through the first segment of qualifying in Indonesia on Saturday, after finishing 16th in an Aprilia-headlined Friday practice.
Bagnaia, who is three points clear of Pramac rider Jorge Martin in the title fight, was on course to secure a spot in the all-important top-10 in the hour-long second Friday practice session with his final lap.
But he made a big error at the penultimate corner, running wide and abandoning the lap, which means his participation in the pole shootout tomorrow will now be contingent on him getting one of the two spots available in the first segment.
It was an Aprilia 1-2 for much of the session, Aleix Espargaro ahead of Maverick Vinales, and that was exactly the order in which it shook out, too, after the late time attacks.
Espargaro had a crash at Turn 10 but shrugged it off to post a 1m30.474s, which stands as the new lap record at Mandalika and was 0.154s clear of what team-mate Vinales managed.
Marco Bezzecchi, who had fractured his collarbone in a dirtbike training crash last week and was far from a certain participant in this weekend, impressed by being the lead Ducati in third place on the year-old bike run by VR46.
KTM's Brad Binder took fourth, aided by him following Martin on his fastest lap - with Martin himself in fifth, 11 places up on Bagnaia.
There were also Q2 spots for Marc Marquez (Honda), Miguel Oliveira (RNF Aprilia), Fabio Di Giannantonio (Gresini Ducati), Jack Miller (KTM) and Fabio Quartararo (Yamaha).
For Miller, ninth place came despite a session of two crashes.
First, he had come off at Turn 11, when seemingly "disturbed" - as his team boss Francesco Guidotti put it - by a slowing Enea Bastianini. Just minutes earlier, two other KTMs had hit the deck at that corner, Augusto Fernandez (Tech3 Gas Gas) tucking the front and taking down Binder, who had himself run wide.
Miller then had a crash at Turn 1 late on.
There was a fall for Bastianini himself, too, ruling him out of any sort of top-1o bid, and one for Honda's Joan Mir, who looked to have struck gold when he tucked in behind Bagnaia on the final lap but crashed right as Bagnaia made his own lap-ruining error.
Straight to Q2
Aprilia: A Espargaro, Vinales, Oliveira
Ducati: Bezzecchi, Martin, Di Giannantonio
KTM: Binder, Miller
Honda: M Marquez
Aprilia: R Fernandez
Ducati: Marini, Zarco, Bagnaia, Bastianini (A Marquez withdrew)
KTM/Gas Gas: P Espargaro, A Fernandez
Honda: Nakagami, Mir, Rins