R2: Keys with slashes in them need to be URL encoded
Does publicly accessing an R2 object with slashes in its name 404 unless you url encode the slashes?
I've got an object uploaded under the key "0cf9bed757176aabf247d9fd34f3e57a4cea05ec/_next/static/chunks/1046.d7427b02ac0637ec.js" and the domain "https://static.weights.gg/0cf9bed757176aabf247d9fd34f3e57a4cea05ec/_next/static/chunks/webpack-ae223e714b298506.js" - however, the url 404s when I use actual slashes (ie navigate to that url). However, if I use the one with %2F instead of slash, it works.
https://static.weights.gg/0cf9bed757176aabf247d9fd34f3e57a4cea05ec%2F_next%2Fstatic%2Fchunks%2F1046.d7427b02ac0637ec.js
This isn't really expected, is it? Was it a mistake when uploading the asset? Or is this a known issue?
1 Reply
What method are you using to upload the objects? The URL in the dash showing %2F instead of / is a known issue but if you uploaded with / it should serve with /