Has anyone successfully set up a tail worker?

Seems like several people (including myself) are having trouble getting it working. The configuration is set on the producing worker in the settings -> variables, but the tail worker doesn't report that it is tailing any worker. However i was seeing successful "requests" on the metrics page... but it doesn't seem to do anything. No console.logs. nothing.
17 Replies
kian
kian2y ago
You can't tail a Tail Worker, if that's what you're trying to do.
Well Caffeinated
Well CaffeinatedOP2y ago
no i'm trying to tail a normal fetch worker
tanushree │ Workers PM
Hi! PM for Tail Workers here -- sounds like you're seeing invocations on your tail worker but no messages being sent? Is that a correct understanding
Well Caffeinated
Well CaffeinatedOP2y ago
It looks like it but the tail() handler isn't being executed. I just was seeing activity in the metrics dashboard. I have a console log and a kv put in the handler but see no logs or kv data
pigri
pigri17mo ago
@wellcaffeinated do you have a solution for this problem? not working to me also I attached a simple worker to another with tail worker but tail function is never executed. If you have any advice @tanushree I appreciate it!
Well Caffeinated
Well CaffeinatedOP17mo ago
Unfortunately still not working for me too
kian
kian17mo ago
What is your Tail Worker doing?
pigri
pigri17mo ago
console.log(events); that's all
kian
kian17mo ago
^ You'll never see them since you can't view the logs of a Tail Worker
pigri
pigri17mo ago
okay i understand that's little bit hard to debugging or developing tail worker tail working bindig is it working in local?
kian
kian17mo ago
Not that I'm aware of iirc there's also a bug (which I've experienced) where you need to republish the Worker you're tailing whenever you publish a new revision of your Tail Worker, otherwise it still runs the old code They're pretty rough to use
pigri
pigri17mo ago
hmm... I need to drop my original idea
kian
kian17mo ago
If it works for you, Logpush for Workers is much more stable currently
pigri
pigri17mo ago
yeah logpush working fine my original idea is i have an analytics service currently use a http endpoint but have latency here that's why I want to use the tail worker
kian
kian17mo ago
If you're unlikely to make any changes to the Tail Worker, once it's working, there isn't any big issues with it It's just the development stage which is rough
pigri
pigri17mo ago
yeah it's a little bit blackbox thanks for the help @kiannh
Well Caffeinated
Well CaffeinatedOP17mo ago
I'm not tailing a tail worker, I'm setting a kv entry but it never runs
Want results from more Discord servers?
Add your server