Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃殌 Feature Request: Local Testing for Tail Workers #5805

Open
sudowoodo200 opened this issue May 12, 2024 · 0 comments
Open

馃殌 Feature Request: Local Testing for Tail Workers #5805

sudowoodo200 opened this issue May 12, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@sudowoodo200
Copy link

Describe the solution

Right now, spinning up a quick start tailworker doesn't run on local environments, even when the tail_consumers = ... is set on the producer's wrangler.toml.

import type { TraceItem } from "@cloudflare/workers-types";
import type { Env } from "./env";

export default {
  async tail(events: TraceItem[], _env: Env, _ctx: ExecutionContext) {
    console.log("I'm HERE")
    for await (const event of events) {
      console.log(event);
    }
  },
};

I believe this should have the same behavior as any other service binding, but maybe there are complications with intercepting console, etc? I thought this was awesome: #1503

@sudowoodo200 sudowoodo200 added the enhancement New feature or request label May 12, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
Status: Untriaged
Development

No branches or pull requests

1 participant