Nelson Griffiths

    Nelson Griffiths

    7 months ago
    I am running into some unexpected behavior with extra loggers in prefect cloud. When I add my extra loggers to the config and run my flow with a local agent everything works as expected. When then switching to the DockerRun config and Bitbucket storage my extra loggers no longer get passed to the Cloud Logs. Is there something extra I need to be doing when moving from a local agent to a docker agent to get my logs to be passed through?
    Kevin Kho

    Kevin Kho

    7 months ago
    Where is the config located? On your local? Does DockerRun have the config?
    Nelson Griffiths

    Nelson Griffiths

    7 months ago
    The config is located on the machine where the Docker Agent is running. Does the config need to exist in the Docker Container being used by DockerRun?
    Kevin Kho

    Kevin Kho

    7 months ago
    Yes but you can pass the env variable in the RunConfig
    DockerRun(env={"PREFECT__LOGGING___EXTRA__LOGGERS": "['some_logger']"})
    Nelson Griffiths

    Nelson Griffiths

    7 months ago
    Ah okay. I was under the impression that the agent needed it. Thanks for clarifiying!
    Kevin Kho

    Kevin Kho

    7 months ago
    Note the syntax of
    "
    . It’s quite specific