Why am I receiving the invalid assignment type error?
I am using the ArcGIS Notebooks supplied on GitHub to add assignments to a Workforce project via CSV.
I used the sample csv and added a field called assignment_type to store the GUID for each assignment.
When I upload the CSV, I received ValidationError: Invalid Assignment Type
The CSV successfully loads
I've updated the Notebook to retrieve the assignment_type just like the other columns.
I've even tried assignmenttype (which is the actual field name in the assignments layer)
Thanks for your help.
Solved! Go to Solution.
Hi David,
I think with new workforce projects the api requires the assignment description not the globalid (the first workforce version was the id number). Hopefully the Description column in your df is the correct description for your workforce project making your fix pretty simple change row["assignment_type"] to row["Description"], otherwise you can get the assignment description text from the assignment table.
Hope that helps.
Cheers, Graeme
Hi David,
I think with new workforce projects the api requires the assignment description not the globalid (the first workforce version was the id number). Hopefully the Description column in your df is the correct description for your workforce project making your fix pretty simple change row["assignment_type"] to row["Description"], otherwise you can get the assignment description text from the assignment table.
Hope that helps.
Cheers, Graeme
That was it!
I thought since the assignment_type field stored the GUID that I had to feed it the actual GUID. Using assignment_type=row["Description"] worked! Thank you very much.