Update: So it turned out that it was indeed an installation problem. I managed to uninstall Python 3.6, and then with brew link python link to the 3.7 installation that somehow co-existed with 3.6 before. Thanks very much again to @LBerger for spotting the root cause of my issue!