Crossword Genius

Bail out a mostly wicked pantomime character (3,4)

Ross

I believe the answer is:

ali baba

I'm a little stuck... Click here to teach me more about this clue!

'pantomime character' is the definition.
(I've seen this before)

'bail out a mostly wicked' is the wordplay.
I cannot really see how this works, but
an anagram of 'bail' is 'alib' which is located in the answer.
'a' is present in the answer.
The remaining letters 'ba' is a valid word which might be clued in a way I don't see.
This explanation may well be incorrect...

Can you help me to learn more?

(Other definitions for ali baba that I've seen before include "Poor woodcutter and cave opener" , "Pantomime hero at odds with 40 thieves" , "1001 Nights hero" , "Folk hero associated with the Forty Thieves" , "One associated with forty thieves" .)

I've seen this clue in The Telegraph.
Want a hint initially instead of a full solution? Install my app