Raphinha was the sole constant in a chaotic contest between Barcelona and Barbastro, with the Brazilian winger scoring one and setting up another as the La Liga side edged the fourth division hosts 3-2.
This was never going to be an easy one. Barbastro packed their stadium to the brim, and a messy playing surface made things as tricky as possible.
Still, Barca's dominance in possession was apparent from the outset. Raphinha and Ferran Torres both came close, but it was Fermin Lopez who opened the scoring. The Spaniard finished a well-worked move, having been handed a simple tap-in from Raphinha after a smart cut-back.
The Blaugrana had the ball in the net again, shortly before half time, only for Joao Felix to see his goal dubiously ruled out. But the linesman didn't get involved early in the second half, when Raphinha snuck in at the back post to make it 2-0 with a tidy poke.
Barbastro pulled one back from a corner, with Adria de Mesa reacting first to a bobbling ball in the Barca goalmouth. And for a brief passage, the home side looked as if they might level proceedings. But Barca did enough to see them off. A late Robert Lewandowski penalty gave the Blaugrana an insurmountable lead - one a stoppage time spot-kick from Marc Prat couldn't overturn.
Questions will be continue to be asked about Xavi, but the win - however awkward - is hard to knock.
GOAL rates Barcelona's players from Estadio Municipal de Deportes...