ARTICLE AD BOX
The world number one made it onto a tennis court in Melbourne, after a judge ruled against the Australian government's decision to cancel his visa - but he could still be deported.
Ros Atkins looks at how he got to this point.
Produced by Michael Cox