Function not updating

I deployed a static site to Pages and am now trying to use Functions to authenticate Decap CMS with Gitlab OAuth. I placed the OAuth handling functions in functions/auth. After deploying them the first time there were some things that needed fixing, but it seems like only the first version of the functions is now used, although every new build log states:
20:18:42.379 Found Functions directory at /functions. Uploading.
20:18:42.385 ⛅️ wrangler 3.101.0
20:18:42.385 -------------------
20:18:43.284 ✨ Compiled Worker successfully
20:18:42.379 Found Functions directory at /functions. Uploading.
20:18:42.385 ⛅️ wrangler 3.101.0
20:18:42.385 -------------------
20:18:43.284 ✨ Compiled Worker successfully
As far as I can tell a wrangler file is not mandatory, so I haven't added one. This is my first time using Cloudflare and Pages, so I'm probably missing something, but so far I haven't managed to figure out what it is. Any clues how I could fix this?
2 Replies
Viktor
Viktorthis hour
Pages keeps old versions of your deployments under different subdomains; e.g. 123aa678.myproject.pages.dev. If you upload a new version, your old version is still available under that domain, and your new version has e.g. 234bb789.myproject.pages.dev. Did you check, that you are either using the updated url, or the root url myproject.pages.dev?
roign
roignOPthis hour
Thanks for answering. I am definitely using the root URL without the version subdomains.

Did you find this page helpful?