Skip to content

Commit

Permalink
Version Packages (#2561)
Browse files Browse the repository at this point in the history
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
  • Loading branch information
github-actions[bot] and github-actions[bot] authored Jan 23, 2023
1 parent e6c9c5c commit 0697f28
Show file tree
Hide file tree
Showing 9 changed files with 67 additions and 81 deletions.
21 changes: 0 additions & 21 deletions .changeset/cuddly-spoons-search.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/fast-badgers-pump.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/green-planets-wink.md

This file was deleted.

5 changes: 0 additions & 5 deletions .changeset/nasty-fishes-carry.md

This file was deleted.

23 changes: 0 additions & 23 deletions .changeset/odd-beers-hear.md

This file was deleted.

20 changes: 0 additions & 20 deletions .changeset/tiny-swans-kick.md

This file was deleted.

2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

65 changes: 65 additions & 0 deletions packages/wrangler/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,70 @@
# wrangler

## 2.8.1

### Patch Changes

- [#2501](https://github.com/cloudflare/wrangler2/pull/2501) [`a0e5a491`](https://github.com/cloudflare/wrangler2/commit/a0e5a4913621cffe757b2d14b6f3f466831f3d7f) Thanks [@geelen](https://github.com/geelen)! - fix: make it possible to query d1 databases from durable objects

This PR makes it possible to access D1 from Durable Objects.

To be able to query D1 from your Durable Object, you'll need to install the latest version of wrangler, and redeploy your Worker.

For a D1 binding like:

```toml
[[d1_databases]]
binding = "DB" # i.e. available in your Worker on env.DB
database_name = "my-database-name"
database_id = "UUID-GOES-HERE"
preview_database_id = "UUID-GOES-HERE"
```

You'll be able to access your D1 database via `env.DB` in your Durable Object.

* [#2280](https://github.com/cloudflare/wrangler2/pull/2280) [`ef110923`](https://github.com/cloudflare/wrangler2/commit/ef1109235fb81200f32b953e9d448f9684d0363c) Thanks [@penalosa](https://github.com/penalosa)! - Support `queue` and `trace` events in module middleware. This means that `queue` and `trace` events should work properly with the `--test-scheduled` flag

- [#2526](https://github.com/cloudflare/wrangler2/pull/2526) [`69d379a4`](https://github.com/cloudflare/wrangler2/commit/69d379a48dd49c9c1812c89b2c7f1680e2196c0f) Thanks [@jrf0110](https://github.com/jrf0110)! - Adds unstable_pages module to JS API

* [#2558](https://github.com/cloudflare/wrangler2/pull/2558) [`b910f644`](https://github.com/cloudflare/wrangler2/commit/b910f644c7440ad034ffcaab288fcbb64deaa83b) Thanks [@caass](https://github.com/caass)! - Add metrics for deployments

- [#2554](https://github.com/cloudflare/wrangler2/pull/2554) [`fbeaf609`](https://github.com/cloudflare/wrangler2/commit/fbeaf6090e5eca4730358caa1838d0866d7b6006) Thanks [@CarmenPopoviciu](https://github.com/CarmenPopoviciu)! - feat: Add support for wasm module imports in `wrangler pages dev`

Currently it is not possible to import `wasm` modules in either Pages
Functions or Pages Advanced Mode projects.

This commit caries out work to address the aforementioned issue by
enabling `wasm` module imports in `wrangler pages dev`. As a result,
Pages users can now import their `wasm` modules withing their Functions
or `_worker.js` files, and `wrangler pages dev` will correctly bundle
everything and serve these "external" modules.

```
import hello from "./hello.wasm"
export async function onRequest() {
const module = await WebAssembly.instantiate(hello);
return new Response(module.exports.hello);
}
```

* [#2563](https://github.com/cloudflare/wrangler2/pull/2563) [`5ba39569`](https://github.com/cloudflare/wrangler2/commit/5ba39569e7ca6e341635b9beb8edebc60ad17dcd) Thanks [@CarmenPopoviciu](https://github.com/CarmenPopoviciu)! - fix: Copy module imports related files to outdir

When we bundle a Worker `esbuild` takes care of writing the
results to the output directory. However, if the Worker contains
any `external` imports, such as text/wasm/binary module imports,
that cannot be inlined into the same bundle file, `bundleWorker`
will not copy these files to the output directory. This doesn't
affect `wrangler publish` per se, because of how the Worker
upload FormData is created. It does however create some
inconsistencies when running `wrangler publish --outdir` or
`wrangler publish --outdir --dry-run`, in that, `outdir` will
not contain those external import files.

This commit addresses this issue by making sure the aforementioned
files do get copied over to `outdir` together with `esbuild`'s
resulting bundle files.

## 2.8.0

### Minor Changes
Expand Down
2 changes: 1 addition & 1 deletion packages/wrangler/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "wrangler",
"version": "2.8.0",
"version": "2.8.1",
"description": "Command-line interface for all things Cloudflare Workers",
"keywords": [
"wrangler",
Expand Down

0 comments on commit 0697f28

Please sign in to comment.