dixudx / rtcclient

RTCClient for Rational Team Concert
https://readthedocs.org/projects/rtcclient/
Apache License 2.0
37 stars 44 forks source link

how does the createworkitem work?I use it as below!thank you! #115

Closed hylsp closed 4 years ago

hylsp commented 5 years ago

a=myclient.createWorkitem(item_type='Task', title='test1', description=None,projectarea_id=None, projectarea_name="[PROD]eRPO_Base_MBSE_PATAC_RTC",template=None, copied_from="144265", keep=False)

the console shows like this: RuntimeError: OrderedDict mutated during iteration issue

AlldreenDev commented 4 years ago

same for me as well. test4 =myclient.createWorkitem("Story", "New Test Bug2", description = "Sample Description",projectarea_id = "_tAlJ4LshEeS6sqoyGG6bXQ", projectarea_name = "RBEI Internal (SCRUM Process)", copied_from ="846734", keep=False)

Error logs:"""""""""""""""""""""""""""""""""""""" File "C:\Python37\lib\site-packages\rtcclient\client.py", line 1047, in createWorkitem **kwargs) File "C:\Python37\lib\site-packages\rtcclient\client.py", line 1150, in _checkMissingParamsFromWorkitem keep=keep) File "C:\Python37\lib\site-packages\rtcclient\client.py", line 879, in listFieldsFromWorkitem keep=keep) File "C:\Python37\lib\site-packages\rtcclient\template.py", line 180, in listFieldsFromWorkitem keep=keep) File "C:\Python37\lib\site-packages\rtcclient\template.py", line 270, in getTemplate self._remove_long_fields(wk_raw_data) File "C:\Python37\lib\site-packages\rtcclient\template.py", line 354, in _remove_long_fields for key in wk_raw_data.keys(): RuntimeError: OrderedDict mutated during iteration

dixudx commented 4 years ago

@AlldreenDev Please clone the latest code in development branch. Hope it works.

AlldreenDev commented 4 years ago

@AlldreenDev Please clone the latest code in development branch. Hope it works.

It works well.Thanks

Narendra0908 commented 11 months ago

when i am trying to create a work item, getting the folllowing waring : Error creating work item: At least choose either-or between template and copied_from . How to solve this error???

dixudx commented 11 months ago

@Narendra0908 Would you please share your snippet of creating a workitem? Thanks.

Narendra0908 commented 11 months ago

Code Snippet : created_work_item = myclient.createWorkitem( work_item_type, work_item_title, projectarea_id = project_area_id, projectarea_name = project_area_name, ownedBy = owned_by_value, filedAgainst = file_against, dueDate = due_date, description = work_item_description, estimate = estimate_time, template = None, copied_from = None, keep = False )

dixudx commented 11 months ago

@Narendra0908 Move the discussion to #194.