hey - what's the best way to diagnose why an agent...
# prefect-community
m
hey - what's the best way to diagnose why an agent might not accept a flow? I have a scheduled run of a flow tagged with my local machine name, and I'm running an agent with the label. Is there any debug logging for the agent to show what flows it's considering? (I should mention I don't think this is related to the agents, as the UI says it's querying)
n
Hi @Matt Wong-Kemp - running the agent with
--verbose
should give you some info as the agent starts up, such as what labels it's running with and which endpoint it's querying.
c
Note: the backend does the filtering of what work should be released to an agent, so you won’t see any logs of any agent deciding not to run something
m
ok, so my agent ID is
Agent ID: 1d83b054-081a-437f-873b-dafd8a650ff4:LocalAgent:agent:ad622f995598:azure-flow-storage:gcs-flow-storage:github-flow-storage:s3-flow-storage
and my flow run is
8d6886e8-7530-4b64-ade4-e6f38dd442b2
- any idea why these two aren't matching?
n
Those are separate entities so it makes sense those would be different; what labels is your agent running with and what labels are on your flow?
To clarify, those are intended to be different because those are their respective database identifiers
m
I understand they're different - however both have the label
ad622f995598
applied
the agent's labels are a superset in that it also has the azure/s3/gcs tags applied, but I think supersets are OK?
n
Hm yes, that sounds like your agent should be picking up your flow, if they both have the
ad622f995598
label
@Matt Wong-Kemp do you mind restarting your agent? It might be that the recent outage is impacting your agent's ability to poll
m
already done that once to turn on
verbose
- will try again
πŸ‘ 1
sorted, nothing at your end. By any chance does the query for flows use the current date and time?
n
That's the next area of investigation, it's going to try to match your system time
So it's possible there's a time issue
m
I'm running in a docker container and some esoteric feature of the windows docker daemon is that the clock doesn't move on if your machine goes to sleep, so my container was querying for around 5pm UTC πŸ™‚
thanks for your help
πŸš€ 1
n
ooooh, that might do it, are you able to restart the container?
m
it only fixes it if you restart the daemon, which worked (did however give me a different set of labels to match)
out of interest what's the max parallelism of local environment flows on local agents?
n
There should be no limits on the number of flows, since each flow is spun up as a separate process. Tasks on the local executor are limited to 1 in parallel in each flow though.
m
ok, thanks
πŸ‘ 1