Skip to content

pylero fails with "normId is invalid: /default/${Project}'" when missing default project argument #161

@KwisatzHaderach

Description

@KwisatzHaderach

Running pylero with defined env variables POLARION_PASSWORD, POLARION_USERNAME, POLARION_REPO and POLARION_URL fails with nasty exception:

[0 13:07:48 pmatyas@pmatyas-fedora ~]$ pylero
Traceback (most recent call last):
...
During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/pmatyas/.local/bin/pylero", line 85, in <module>
    main()
  File "/home/pmatyas/.local/bin/pylero", line 75, in main
    imp_mod = __import__("pylero.{0}".format(the_mod), fromlist=[""])
              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmatyas/.local/lib/python3.11/site-packages/pylero/build.py", line 8, in <module>
    from pylero.build_linked_work_item import ArrayOfBuildLinkedWorkItem
  File "/home/pmatyas/.local/lib/python3.11/site-packages/pylero/build_linked_work_item.py", line 9, in <module>
    from pylero.work_item import _WorkItem
  File "/home/pmatyas/.local/lib/python3.11/site-packages/pylero/work_item.py", line 1582, in <module>
    vals = bp.get_valid_field_values("workitem-type")
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmatyas/.local/lib/python3.11/site-packages/pylero/base_polarion.py", line 1052, in get_valid_field_values
    enums = self.session.tracker_client.service.getEnumOptionsForIdWithControl(
            ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmatyas/.local/lib/python3.11/site-packages/suds/client.py", line 586, in __call__
    return client.invoke(args, kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmatyas/.local/lib/python3.11/site-packages/suds/client.py", line 728, in invoke
    result = self.send(soapenv, timeout=timeout)
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmatyas/.local/lib/python3.11/site-packages/suds/client.py", line 776, in send
    return self.process_reply(content, e.httpcode, tostr(e))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/pmatyas/.local/lib/python3.11/site-packages/suds/client.py", line 840, in process_reply
    raise WebFault(fault, replyroot)
suds.WebFault: Server raised fault: 'java.lang.IllegalArgumentException: normId is invalid: /default/${Project}'

Instead of clean fail mentioning missing POLARION_PROJECT

Same behaviour when missing default_project argument from .pylero config

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions