The notebook editor for jupyterlab seems to not recognise match-case statements properly, if the condition isn't extra simple. Of course, this means bad highlighting which is a bit disappointing, but ...