Pre-commit causes commit to fail

When I install pre-commit and try to commit from Atom it complains that my python wouldn’t have an SSL module. But from the command line it works.

[INFO] Installing environment for https://github.com/psf/black.
[INFO] Once installed this environment will be reused.
[INFO] This may take a few minutes...
An unexpected error has occurred: CalledProcessError: command: ('C:\\Users\\robin\\.cache\\pre-commit\\repoiuu2irsk\\py_env-python\\Scripts\\pip.exe', 'install', '.')
return code: 1
expected return code: 0
stdout:
    Processing c:\users\robin\.cache\pre-commit\repoiuu2irsk
      Installing build dependencies: started
      Installing build dependencies: finished with status 'error'
    
stderr:
    WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
      ERROR: Command errored out with exit status 1:
       command: 'c:\users\robin\.cache\pre-commit\repoiuu2irsk\py_env-python\scripts\python.exe' 'c:\users\robin\.cache\pre-commit\repoiuu2irsk\py_env-python\lib\site-packages\pip' install --ignore-installed --no-user --prefix 'C:\Users\robin\AppData\Local\Temp\pip-build-env-ko21wnqy\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=41.0' setuptools-scm wheel
           cwd: None
      Complete output (12 lines):
      WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
      Collecting setuptools>=41.0
        WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/setuptools/
        WARNING: Retrying (Retry(total=3, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/setuptools/
        WARNING: Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/setuptools/
        WARNING: Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/setuptools/
        WARNING: Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'SSLError("Can't connect to HTTPS URL because the SSL module is not available.")': /simple/setuptools/
        Could not fetch URL https://pypi.org/simple/setuptools/: There was a problem confirming the ssl certificate: HTTPSConnectionPool(host='pypi.org', port=443): Max retries exceeded with url: /simple/setuptools/ (Caused by SSLError("Can't connect to HTTPS URL because the SSL module is not available.")) - skipping
        ERROR: Could not find a version that satisfies the requirement setuptools>=41.0 (from versions: none)
      ERROR: No matching distribution found for setuptools>=41.0
      WARNING: You are using pip version 19.2.3, however version 19.3.1 is available.
      You should consider upgrading via the 'python -m pip install --upgrade pip' command.
      ----------------------------------------
    ERROR: Command errored out with exit status 1: 'c:\users\robin\.cache\pre-commit\repoiuu2irsk\py_env-python\scripts\python.exe' 'c:\users\robin\.cache\pre-commit\repoiuu2irsk\py_env-python\lib\site-packages\pip' install --ignore-installed --no-user --prefix 'C:\Users\robin\AppData\Local\Temp\pip-build-env-ko21wnqy\overlay' --no-warn-script-location --no-binary :none: --only-binary :none: -i https://pypi.org/simple -- 'setuptools>=41.0' setuptools-scm wheel Check the logs for full command output.
    WARNING: You are using pip version 19.2.3, however version 19.3.1 is available.
    You should consider upgrading via the 'python -m pip install --upgrade pip' command.
    
Check the log at C:\Users\robin/.cache\pre-commit\pre-commit.log