after installing the new SR18, below function crashes Rhino for Mac. It worked fine before the update. The version is (7.18.22124.3002, 2022-05-4).
Please run the script from the _EditPythonScript editor. If it does not crash on the first run, run it again a few times. In my case it crashes on the second or third run.