diff --git a/.changeset/curly-lizards-rescue.md b/.changeset/curly-lizards-rescue.md new file mode 100644 index 000000000000..c645e2ae4b64 --- /dev/null +++ b/.changeset/curly-lizards-rescue.md @@ -0,0 +1,7 @@ +--- +"wrangler": patch +--- + +fix: kv:key put binary file upload + +As raised in https://github.com/cloudflare/wrangler2/issues/1254, it was discovered that binary uploads were being mangled by wrangler 2, whereas they worked in wrangler 1. This is because they were read into a string by providing an explicit encoding of `utf-8`. This fix reads provided files into a node `Buffer` that is then passed directly to the request.