Hacker News new | ask | show | jobs
by banana_giraffe 1891 days ago
Back when I had a large python2 and python3 code bases side by side, I had a small handler that I installed for .py files that read the #! line and tried to figure out which python version to call, and defaulted to Python3 if it couldn't find a #! line. I always felt this was the "correct" way of solving this.

Nowadays, I just only install Python3 on machines, so it's not really a problem for me anymore.