Thread
#prefect-community
    Nadav Nuni

    Nadav Nuni

    1 year ago
    hey guys, I’m facing a kind of an obscure error using running a flow with GitHub storage…it seems like I’m downloading the files successfully, but then the flow fails for not finding a certain file…is there a way to produce more verbose logs so I can know exactly what file it fails on?
    Zach Angell

    Zach Angell

    1 year ago
    Hi @Nadav Nuni - setting log level to DEBUG for the flow run might be helpful. The most common cause of this error is trying to load other files from within your flow file. For example, something like
    from prefect import task, Flow
    
    # this will fail because the file is
    # not available when the flow is loaded from storage
    with open('my_config.toml', 'r') as f:
        my_config = f.read()
    
    # ... meaningless boilerplate flow code
    @task
    def foo():
       return my_config
    
    with Flow('foo') as flow:
        foo()
    Any chance you're doing something like the above in your flow file?
    Nadav Nuni

    Nadav Nuni

    1 year ago
    Thanks @Zach Angell! I’m actually not accessing any files directly…could it be the
    KubernetesRun.template_path
    or
    storage.GitHub.path
    ? I’ll try to change the logging level and get more clues
    Zach Angell

    Zach Angell

    1 year ago
    Hmm perhaps. If you can share a minimum example of your flow that would help narrow things down
    Could you double check how
    flow_path
    is specified? This actually could also cause issues https://prefect-community.slack.com/archives/CL09KU1K7/p1631548699136700?thread_ts=1631166492.384100&cid=CL09KU1K7
    Nadav Nuni

    Nadav Nuni

    1 year ago
    Hey @Zach Angell, thanks for the help. the problem was indeed the template_path!