https://prefect.io logo
Join the conversationJoin Slack
Channels
announcements
ask-marvin
best-practices-coordination-plane
data-ecosystem
data-tricks-and-tips
events
find-a-prefect-job
geo-australia
geo-bay-area
geo-berlin
geo-boston
geo-chicago
geo-colorado
geo-dc
geo-israel
geo-japan
geo-london
geo-nyc
geo-seattle
geo-texas
gratitude
introductions
marvin-in-the-wild
prefect-ai
prefect-aws
prefect-azure
prefect-cloud
prefect-community
prefect-contributors
prefect-dbt
prefect-docker
prefect-gcp
prefect-getting-started
prefect-integrations
prefect-kubernetes
prefect-recipes
prefect-server
prefect-ui
random
show-us-what-you-got
Powered by Linen
prefect-community
  • a

    Andy Yeung

    01/08/2023, 6:15 AM
    I got a main flow and have 3 subflows within, the dashboard indicate all subflows has been completed the parent flow last line is the execute of subflow. So there isn’t any task afterward. However the parent flow is marked as failed with the following error:
  • y

    Yaron Levi

    01/08/2023, 1:00 PM
    Hi 👋 Trying to run the DaskTaskRunner() locally and getting “Failed to serialize”, “cannot pickle ‘SSLContext’ object” errors. https://discourse.prefect.io/t/error-when-using-local-dasktaskrunner-failed-to-serialize-cannot-pickle-sslcontext-object/2160 Any ideas?
    ✅ 1
    • 1
    • 1
  • t

    Tadej Svetina

    01/08/2023, 8:11 PM
    Hi, I'm using Prefect cloud - and it seems to sign me out automatically very frequently (enough to annoy me). Any way this could be changed? I'm using google SSO as log in
    b
    • 2
    • 1
  • t

    Tadej Svetina

    01/08/2023, 9:28 PM
    Hi, I have an issue: I have a task, where basically constitutes of polling an API every X seconds. I use
    asyncio.sleep
    to wait between querying the API. Running of this task occupies 100% of the CPU - how can I fix this?
    👀 1
    g
    m
    • 3
    • 8
  • b

    Ben Muller

    01/08/2023, 10:50 PM
    Hey - all of a sudden today I am unable to run
    prefect deployment apply my-deployment.yml, mydeployment2.yml --upload
    Error in 🧵
    :gratitude-thank-you: 1
    :hattip: 1
    ✅ 2
    t
    j
    d
    • 4
    • 7
  • d

    Dylan Lim

    01/09/2023, 1:44 AM
    Hi all, we
  • d

    Dylan Lim

    01/09/2023, 1:53 AM
    [Prefect 1.0] Hi all, we’ve encountered an issue since 4th January where one of our Flows runs indefinitely at the extract stage. For context, the Flow extracts records from another db using
    PostgresFetch
    , transforms it and loads it onto our warehouse using
    PostgresExecuteMany
    . The Flow gets stuck at the stage where it reads from the external db and when I cancel it via the UI, it also cancels indefinitely (I have flows that have been ‘cancelling’ since a few days ago). Can anyone point me towards any suggested areas to investigate? For context, I checked if it’s a volume issue but the number of rows historically retrieved are roughly the same amount, and other Flows that query from the same external db are not running into this issue.
    c
    • 2
    • 3
  • l

    lialzm

    01/09/2023, 8:01 AM
    I use the code to register the deployment, but when I modify the name, the re-registration does not take effect, what do I need to do in Perfect 2.0, and I use the -f parameter in Perfect 1.0
    c
    • 2
    • 11
  • k

    Kelvin DeCosta

    01/09/2023, 9:27 AM
    Hey everyone! With version 2.7.3, task concurrency limits don’t seem to account for tasks that are marked as running for cancelled flows / subflows. Furthermore, flows that are marked as cancelled, don’t seem to propagate the state to their subflows. These zombie / orphaned tasks, although not running, still take up concurrency slots for all their tags.
    c
    • 2
    • 4
  • d

    Danilo Drobac

    01/09/2023, 10:39 AM
    Hey folks - using the personal version of Prefect 2.0, what's the best way to programmatically login to Prefect Cloud on a VM Agent?
  • m

    Max Rostron

    01/09/2023, 11:01 AM
    Good morning - I'm migrating our flows over from Prefect 1 to Prefect 2 finally. I'm curious - whenever I run a flow locally from command line, it is now automatically created and run in the cloud UI console. Ideally, this would only happen once deployed like in Prefect 1. Am I doing something wrong? What should I be checking?
    a
    • 2
    • 2
  • s

    Stefan

    01/09/2023, 12:53 PM
    Has anyone been successfull in registering prefect orion start as a systemd service?
    a
    • 2
    • 1
  • b

    Bianca Hoch

    01/09/2023, 6:07 PM
    Hi Michal, to my understanding it should be
    <! here>
    (without the space).
    m
    m
    • 3
    • 10
  • m

    Matthew Scanlon

    01/09/2023, 2:40 PM
    Has anyone been seeing an issue with prefect deployments disappearing on 2.X? Deployments are showing up in "total results" But not in the search. In addition to this, some flows are failing with state message
    Submission failed. PrefectHTTPStatusError: Server error '500 Internal Server Error' for url '<https://api.prefect.cloud/api/accounts/XXXXXXXX/workspaces/XXXXXXXXX/deployments/XXXXXXXXX>' Response: {'exception_message': 'Internal Server Error'} For more information check: <https://httpstatuses.com/500>
    👀 1
    b
    • 2
    • 1
  • i

    Igor Morgunov

    01/09/2023, 2:55 PM
    Hi, I have a 2.x deployment question - I want to deploy my flows using python deployment object, here the code:
    cluster_config_block = KubernetesClusterConfig.load("data-engineering")
    
    k8s = KubernetesJob(
        cluster_config=cluster_config_block
    )
    
    deployment = Deployment.build_from_flow(
        flow=test,
        name="test",
        version="0.0.1",
        tags={"from-python-object"},
        parameters={"name": "test-run"},
        infra_overrides={"env": {"PREFECT_LOGGING_LEVEL": "DEBUG"}},
        work_queue_name="test",
        infrastructure=k8s
    )
    
    if __name__ == "__main__":
        result = deployment.apply()
        print(result)
    I don't see where/how to pass the AWS credentials to deployment, without which ofc the flow run results in
    401 Unauthorized
    response
    n
    • 2
    • 17
  • r

    Rasmus Lindqvist

    01/09/2023, 3:22 PM
    Hi there, We are planning to migrate from 1.0 to . We have figured out most of the things we need to change and are excited about Prefect 2. However, we are still struggling to understand how persisted results works in 2. We have several flows that run daily and for us it is very important to have backwards traceability. Is it possible to do path templating like in prefect 1.0 ? (code examples in thread). We’ve read documentation and searched Slack but are struggling to understand if templating still exists.
    t
    • 2
    • 8
  • s

    Scott Chamberlain

    01/09/2023, 6:50 PM
    Could someone point me to any examples of using
    try ... catch
    with Prefect 2 tasks, if it’s possible that is? I’d like to be able to skip a failed task and let downstream tasks proceed but it seems like a Failed task kills the entire flow. Or maybe I’m wrong?
    a
    m
    • 3
    • 6
  • j

    Jean-Michel Provencher

    01/09/2023, 7:13 PM
    Hello, there's something I don't understand, when launching a deployment using a KubernetesJob from the UI, I can see the logs of my Flow both in the Agent running in Kubernetes and in the Kubernetes Job pods. Is that expected? (my guess is no). Seems like it's executing my flow twice.
    m
    • 2
    • 9
  • a

    alex

    01/09/2023, 9:00 PM
    From my understanding, it appears that Prefect 2 only supports script based storage options. Is there any plan for adding built in support for pickle based storage like Prefect 1 had?
    a
    • 2
    • 5
  • n

    Nace Plesko

    01/10/2023, 12:36 AM
    Hi! I'm using prefect v1 and I'm trying to activate zombie killer to clean up tasks that are failed but are stuck in forever running state. From what I understood from this link, all I need to do to activate it is to add
    env={"PREFECT__CLOUD__HEARTBEAT_MODE": "thread"}
    to my run config. I added that but the tasks are still being stuck. Is there anything else I need to configure in order to activate zombie killer?
    c
    m
    • 3
    • 9
  • i

    iKeepo w

    01/10/2023, 3:57 AM
    Hi, I'm interesting one detail, it seems prefect will copy the script where flow defined to a /temp location every flow run, what's considered here?
    c
    • 2
    • 2
  • b

    Bryan Whiting

    01/10/2023, 4:38 AM
    Cross posting, thanks in advance
    c
    • 2
    • 5
  • t

    Tibs

    01/10/2023, 7:26 AM
    Hi, I have an issue in prefect 2.7.7, when trying to deploy a flow using an S3Bucket block:
    deployment build deployment_utils/maintenance.py:maintenance -n maintenance/maintenance -sb s3-bucket/<my_s3_bucket_block_name> -a
    
     f"Successfully uploaded {file_count} files to {deployment.location}",
        if not self.storage.basepath.endswith("/")
    AttributeError: 'NoneType' object has no attribute 'endswith'
    Files are uploaded to S3, but this error is raised. Anyone know what could be the issue?
    j
    a
    • 3
    • 2
  • r

    Rasmus Lindqvist

    01/10/2023, 9:43 AM
    Hi there! Does anyone know if it is possible to access the flow name inside a task? My use case is that I want to construct a cache key for a task based of both the task name and the flow name. If not, does anyone have a workaround to manually set the flow name in the context so it is accessible in the task context ?
    ✅ 1
    r
    • 2
    • 2
  • s

    Stephen Herron

    01/10/2023, 9:47 AM
    would there be any way to get the value from SecretStr in
    SnowflakeCredentials
    from a
    SnowflakeConnector
    ?
    ✅ 1
    a
    • 2
    • 3
  • k

    karthik

    01/10/2023, 9:54 AM
    Hey guys, I want to start a scheduled flow run immediately without the help of UI in prefect 1.2. Is it possible to do it from mutation or python itself?
    c
    • 2
    • 1
  • m

    Mark Nuttall-Smith

    01/10/2023, 10:38 AM
    Hi all. I've been trying to get a
    DockerRegistry
    block working with AWS ECR, but it seems the password expires after some hours. Another thread suggests that an ECR block is being worked on, but this PR is blocked for a variety of reasons. In the same thread @Anna Geller suggests using
    ECSTask
    as the run-infrastructure. Is that still the only workaround for using ECR? I'd prefer to continue using
    DockerContainer
    if possible, as I'm not familiar with ECS.
    ✅ 1
    c
    g
    +2
    • 5
    • 7
  • d

    Danilo Drobac

    01/10/2023, 11:23 AM
    Strange issue while building a Dockerfile...
    FROM prefecthq/prefect:2.7.7-python3.8
    RUN ["pip", "install", "gcsfs"]
    Returns the error:
    /bin/sh: 1: ["pip",: not found
    Has anybody else had this error/know what the fix it? I'm assuming its not an issue with the base image?
    ✅ 1
    m
    • 2
    • 2
  • b

    Bogdan Serban

    01/10/2023, 12:03 PM
    Hello Everyone! Thanks for this awesome repo! I am using
    Prefect 2.7.0
    and am trying to set up some hooks to do some stuff (db updates and sending queue messages) whenever the state of a flow changes. I have tried using prefect-alert, but unfortunately that does not trigger when I am running the flow from a deployment. I am thinking that I could try and create a custom notification block, but it is not very clear if it is possible and how I could do so. I would really appreciate any suggestions on that, or, if there are any other mechanisms to define custom flow state update callbacks.
    j
    • 2
    • 2
  • j

    James Phoenix

    01/10/2023, 1:00 PM
    I’m trying to decide between cloudrun jobs and k8s as the executor. My concern with cloudrun jobs is that there is a hard limit of 10k concurrent queues.
    ✅ 1
    m
    d
    • 3
    • 6
Powered by Linen
Title
j

James Phoenix

01/10/2023, 1:00 PM
I’m trying to decide between cloudrun jobs and k8s as the executor. My concern with cloudrun jobs is that there is a hard limit of 10k concurrent queues.
✅ 1
m

Mike Grabbe

01/10/2023, 1:33 PM
Im not sure about Prefect's ability to handle 10k concurrent tasks, but I do know you have the ability to throttle concurrent tasks either by setting a work queue concurrency limit or a tag-based task run concurrency limit.
j

James Phoenix

01/10/2023, 2:24 PM
And will the remaining tasks just be pending? I like the throttling idea, thanks @Mike Grabbe
m

Mike Grabbe

01/10/2023, 2:24 PM
Yes, they should stay in pending status until there's room in the queue
😛anda-dancing: 1
j

James Phoenix

01/10/2023, 2:24 PM
Perfect, thanks 🙂 Really appreciate it
d

Danilo Drobac

01/10/2023, 4:06 PM
@James Phoenix Out of interest, what's your use-case that will potentially run a Flow 10k times concurrently?
j

James Phoenix

01/10/2023, 4:23 PM
A GPT-3 article generator, all of the tasks are quite small so I’m hopefully expecting volume.
View count: 1