How to do the assignments in workforce with python?

265
2
08-07-2021 03:26 PM
Jcordovafredes
Occasional Contributor II

Hi, I am trying to create mappings using a csv file with the following code: 

Jcordovafredes_0-1628374680099.png

 

the csv file was loaded successfully and is located in the variable "assignments"

the error is as follows:

Jcordovafredes_1-1628374797215.png

I do not know what the error is, if you could help me it would be great

 

Thanks

 

 

0 Kudos
2 Replies
Marco_E_Cadario
New Contributor II

hello,

check if assignment_types already exist, if not  

assignment_types = project.assignment_types.add(name="Inspecciòn de Grifo")
regards
M.
Jcordovafredes
Occasional Contributor II

Thanks for the answer, in any case the assignments in a "code 1", while to assign the assignments through csv they are in a "code 2", I will also try to join the codes so that the error does not appear.

Greetings

0 Kudos