Next time it would be useful if you post the whole error message:
Traceback (most recent call last):
File "/root/shared/mwe123.py", line 49, in <module>
mesh_obj, a, b = dolfinx.io.gmshio.model_to_mesh(
File "/usr/local/dolfinx-real/lib/python3.10/dist-packages/dolfinx/io/gmshio.py", line 232, in model_to_mesh
cell_id = cell_information[perm_sort[-1]]["id"]
IndexError: index -1 is out of bounds for axis 0 with size 0
You can search for the IndexError on the forum to find