I\'ve tried pip install time and sudo -H pip install time, but I keep getting the error:
Could not find a version that sati
The time module is part of Python's standard library. It's installed along with the rest of Python, and you don't need to (nor can you!) install it with pip.
I can import time in the Python Console
Yes, because it's already installed.
but not in my actual code
I don't believe you. Show us the exact error message you get when you try.