This is my prefect.yaml deployment: - name: Githu...
# pacc-aug-28-29-2024
c
This is my prefect.yaml deployment: - name: Github Pull Test version: 1.0 tags: - test description: Tests the ability to pull code from Github entrypoint: 101/weather1-bare.py:fetch_weather work_pool: name: Chris_Work_Pool_01 work_queue_name: default job_variables: {} schedules: [] pull: - prefect.deployments.steps.git_clone: repository: https://github.com/PrefectHQ/pacc-2024-v4.git branch: main This is the error I get. It only wants to look in my current working directory. : FileNotFoundError: [Errno 2] No such file or directory: '101\\weather1-bare.py'
👀 1
b
did you already add a @flow() decorator to the python function in
weather1-bare.py
?
IIRC, that has just a plain python function to start
j
It’s in my repo, so that’s the issue
c
but I still have the same issue.
Do I not have access to pull from that repo?
j
You have pull access. Sending Mason over.
c
@Mason Menges I was able to create a deployment using the method you described: I ran this python code: from prefect import flow flow.from_source( source="https://github.com/PrefectHQ/pacc-2024-v4.git", entrypoint="102/weather2-tasks.py:pipeline" ).deploy( name="github pull test 2", work_pool_name="Chris_Work_Pool_01" )
🚀 2
marvin 2
wizard2 2
Mason's explanation of the difference between the YAML file and the Deploy methods really should be explained to everyone. There is no way I would have known about the assumptions the process makes with the YAML file.
💯 1
👍 1
j
Thank you, Chris! Adding a slide for it.