Closed emesika closed 1 year ago
@emesika please also provide the pylero version info, thanks. Also please don't include internal service url and user name info, which I have edited.
pip show pylero Name: pylero Version: 0.0.8 Summary: Python SDK for Polarion Home-page: https://github.com/RedHatQE/pylero Author: pylero Developers Author-email: dno-tools@redhat.com License: MIT Location:
Requires: click, suds Required-by:
I can't reproduce with current 0.0.8 version.
Where is your .pylero
config file, so pylero check home "~" dir and current dir for the config file .pylero
, could you check if you've configured both (only one is needed) and any difference with the token value?
Also make sure you are using the right token for the targeted server, like don't use a token from server A to access server B.
pylero.cfg is under ~/.local/lib/python3.9/site-packages/pylero/pylero.cfg Also , I am using the right token for the targeted server
Ok, so the error and prompt for token input only happen when token have been provided in the cfg file but failed to login to the server.
Could you try with manually enter the valid token when the token prompt happen with:
Invalid Token.
Enter Token:
and press enter to see if it could succeed to continue.
Tried it , same result , from some reason it does not accept a token that seems to be valid
I have cloned the pylero code and by debugging it ,it claims that I have no permission to add/edit work items in Polarion:
suds.WebFault: Server raised fault: 'com.polarion.platform.security.PermissionDeniedException: Permission com.polarion.persistence.object.instance.NEW.INSTANCE.key.type.modify denied for user XXXXX in context ContextId[cluster default, context Polarion].'
I am checking that with our Polarion admin and will update soon
Problem was not related to pylero
I am trying to run a python script that access Polarion API and I am constantly getting "Invalid Token" on the call I had created a valid access token and it is defined in my pylero conf file which looks like:
[webservice] url=https://polarion.example.com/polarion svn_repo=https://polarion.example.com/repo user=myuser password= token=<my token here , removed for security> default_project=MyProject
I am running this simple python test code :
$ python3 test.py Invalid Token. Enter Token: