Why would updates to an existing worker not be apparent?

I have a Worker which I have published at https://my-ts-project.pups.workers.dev/ and works as it should.

I’ve then made some changes to the handler.ts file and did another wrangler publish. When I then accessed the https://my-ts-project.pups.workers.dev/ , after the publish, there was no change to the output. I repeated the publish process a number of times, never any change to the output.

I then deleted the worker and did another wrangler publish - still getting the same output.

When I went onto the worker console I could see the compiled version of handler.ts and it was the original version. When I used the editor within the console to change one of the strings in the output subsequent accesses to the https://my-ts-project.pups.workers.dev/ included the change to the string.

Am I missing something here ? If you create a new worker and do a wrangler publish I believe that you should be then be able to make changes to the source locally and do another wrangler publish to see the local changes reflected, is that correct ? I’d appreciate any suggestions for moving forward with my current situation.


If you want to use the workers.dev domain then you will need to have workers_dev = true in your wrangler.toml file and use wrangler publish

Hi Jake1st, thanks for your reply, I appreciate it. I do have workers_dev = true in wrangler.toml and I am using wrangler publish so I’m not sure that’s the problem. Here’s what my wrangler.toml looks like …

name = "my-ts-project"
type = "webpack"
zone_id = ""
account_id = "NOT_THIS_VALUE"
route = ""
workers_dev = true
compatibility_date = "2021-11-08"

command = "npm install && npm run build"
format = "service-worker"

Thanks again for your suggestion.