The problem was naming a local module with the same name as an imported module. I had a file called ./tokenize.py and moving it to ./run_tokenize.py solved the problem.
https://cityad-all-prod.s3.amazonaws.com/public/2025-07/200x200%20python-5%20tiny.png