Error using the Shotgun API

We have created a user for running integration tests with. We are able to log in to the web UI using the user credentials and have followed the steps from Help to create a PAT, link it and created a personal access token. However, when trying to use the Python API it errors:

>>> from shotgun_api3 import Shotgun
>>> base_url = "https://<DOMAIN>.shotgunstudio.com/"
>>> login = "<USER>@<BASE>.com"
>>> password = "<PASSWORD>"
>>> sg = Shotgun(base_url, login=login, password=password)
>>> print(sg.find('Project', [], ['name']))
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File ".../shotgun_api3/3.5.1/python-3/ext/python/shotgun_api3/shotgun.py", line 1057, in find
    result = self._call_rpc("read", params)
  File ".../shotgun_api3/3.5.1/python-3/ext/python/shotgun_api3/shotgun.py", line 3460, in _call_rpc
    self._response_errors(response)
  File ".../shotgun_api3/3.5.1/python-3/ext/python/shotgun_api3/shotgun.py", line 3759, in _response_errors
    raise AuthenticationFault(sg_response.get("message", "Unknown Authentication Error"))
shotgun_api3.shotgun.AuthenticationFault: Can't authenticate user 'ptester01@netflixpartner.com' because the account is locked.

I have followed the documentation from Help to remove the “Locked Until” field but on retrying it is locking it again. The credentials I am using enable me to login into the web UI.

Any help much appreciated,

Dominique

Have a look at the event logs to see if some other process is locking the account.