I am very happy with the update to MIUI 12,
the proximity sensor works properly.