Deploying a worker with pattern */*

Hey folks.

I’ve been using workers for a while, but only ever used the web UI for writing the code and configuring them. Today I decided to try to set this up with Wrangler so I can work on the code locally and version it in git.

The code in the worker is fine, but when I set the pattern in the wrangler.toml file to / it won’t deploy. It throws a generic error message “Error: Invalid URL”. I can change it to something else and it deploys fine. I need it to be / though, or at least something that works for all routes on all domains.

I can set this exact pattern in the dashboard UI and it works great, but if I deploy from wrangler like I should it removes this pattern and replaces it with what I’ve defined in wrangler.toml.

Am I doing something wrong or is this a bug? I’ve found this issue from October reporting the same thing, but is was closed with no resolution.

Hi @paulmcbride were you able to get this Worker to work? Sorry for the issues.