I have this pull steps defined in my prefect 3 de...
# ask-community
j
I have this pull steps defined in my prefect 3 deployments file. I seem to have issues with the the git_clone steps or the pip step, it often fails on first try when i have flows with sub flows fan-out, thus concurrency. Seems like these deployment steps do not handle concurrency very well. A retry of these failed flows, then works (thus at a time where there are no concurrency issues). What would be the best way to fix this. I do not find a way to enforce concurrency locks during this deployment phase.
Copy code
pull: &id001
      - prefect.deployments.steps.run_shell_script:
          id: ensure-directory
          script: mkdir -p /opt/prefect/repos && echo "Directory ready"
          stream_output: false
      - prefect.deployments.steps.set_working_directory:
          directory: "/opt/prefect/repos"
      - prefect.deployments.steps.git_clone:
          id: clone_step
          repository: <https://github.com/MY_ORG/bess-prefect.git>
          branch: "{{ $PREFECT_VAR_deployment_branch }}"
          access_token: "{{ prefect.blocks.secret.github-access-token }}"
      - prefect.deployments.steps.set_working_directory:
          directory: "/opt/prefect/repos/{{ clone_step.directory }}"
      - prefect.deployments.steps.pip_install_requirements:
          requirements_file: requirements.txt
          stream_output: false