fierce-farmer-40956
12/08/2025, 12:29 PMduplicate key value violates unique constraint "tasks_pkey" (SQLSTATE 23505)
and our executions are all in UNKNOWN state. Would you have a pointer?acceptable-knife-37130
12/08/2025, 1:14 PMtask def and and the workflow details it is very difficult to point out the issue.
See the example how to create a map task below:
https://www.union.ai/docs/v1/flyte/user-guide/core-concepts/tasks/map-tasks/
If you are using concurrency , set it to 1 and see if you get the issue. Also check the infa that you are running your task on :- container,kubernetesCluster etc. Register your workflow witha different version flytectl register files --project myproj --domain development --version v1.2.3 and see if the error persist
You have to provide the issue/error with the code so someone can help like below:
THRESHOLD = 11
@fl.task
def detect_anomalies(data_point: int) -> bool:
return data_point > THRESHOLD
@fl.workflow
def map_workflow(data: list[int] = [10, 12, 11, 10, 13, 12, 100, 11, 12, 10]) -> list[bool]:
# Use the map task to apply the anomaly detection function to each data point
return fl.map_task(detect_anomalies)(data_point=data)