diff --git a/containers/pyproject.toml b/containers/pyproject.toml index c9f8b5a..bf04a19 100644 --- a/containers/pyproject.toml +++ b/containers/pyproject.toml @@ -9,7 +9,6 @@ authors = [ requires-python = ">=3.12" dependencies = [ "typing-extensions>=4.12", - "workers-runtime-sdk>=1.9.0", ] license = "MIT OR Apache-2.0" @@ -48,4 +47,5 @@ dev = [ "pytest-asyncio>=1.4.0", "ruff>=0.16.9", "ty>=0.0.84", + "workers-runtime-sdk>=1.9.0", ] diff --git a/docs/docs/containers/getting-started.md b/docs/docs/containers/getting-started.md index 11fca0b..db43715 100644 --- a/docs/docs/containers/getting-started.md +++ b/docs/docs/containers/getting-started.md @@ -11,8 +11,9 @@ container and routes requests to it from a Python Worker. By the end, each - [`uv`](https://docs.astral.sh/uv/) and Node.js, to build and deploy [Python Workers](https://developers.cloudflare.com/workers/languages/python/). - `containers-py` needs Python 3.12 or later and installs - `workers-runtime-sdk` 1.9.0 or later with it. + `containers-py` needs Python 3.12 or later and works with either + `crosswind-workers` or `workers-runtime-sdk`. This guide uses pywrangler, + which installs `workers-runtime-sdk`. - Docker, or another Docker-compatible engine, running locally. Check with `docker info`. Wrangler builds your image with it in both `dev` and `deploy`. diff --git a/docs/docs/containers/overview.md b/docs/docs/containers/overview.md index 95c022d..30e99a2 100644 --- a/docs/docs/containers/overview.md +++ b/docs/docs/containers/overview.md @@ -85,8 +85,8 @@ Add the package to a Python Worker project: uv add containers-py ``` -It needs Python 3.12 or later and installs `workers-runtime-sdk` 1.9.0 or -later with it. Running a container also needs Docker locally and the Workers +It needs Python 3.12 or later and works with either `crosswind-workers` or +`workers-runtime-sdk`, whichever your project declares. Running a container also needs Docker locally and the Workers Paid plan. To create a project first, follow [Getting started](getting-started.md). diff --git a/docs/docs/index.md b/docs/docs/index.md index 8912d5a..f574b7e 100644 --- a/docs/docs/index.md +++ b/docs/docs/index.md @@ -125,9 +125,7 @@ makes the JavaScript calls. | [Workers](workers/overview.md) | `crosswind-workers` | Drop-in replacement for the official `workers` package, with type hints on bindings, requests and Durable Objects. | [Write a Worker](workers/getting-started.md) | ![crosswind-workers on PyPI](https://img.shields.io/pypi/v/crosswind-workers) | | [Wynd](wynd/overview.md) | `wynd` | Replaces pywrangler. It drops vendored files your Worker never imports before each upload. | [Switch from pywrangler](wynd/getting-started.md) | ![wynd on PyPI](https://img.shields.io/pypi/v/wynd) | -For a new Python Worker that doesn't need an agent or a container, use -`crosswind-workers` and deploy it with Wynd. `containers-py` depends on the -official `workers-runtime-sdk`, so its guides use that package instead. +For a new Python Worker, use `crosswind-workers` and deploy it with Wynd. ## How the packages work diff --git a/docs/docs/introduction.md b/docs/docs/introduction.md index a72d529..887a5b3 100644 --- a/docs/docs/introduction.md +++ b/docs/docs/introduction.md @@ -52,20 +52,15 @@ A project ships exactly one package named `workers`. Both `crosswind-workers` and Cloudflare's `workers-runtime-sdk` provide it, and `crosswind-workers` refuses to import when it finds the stock SDK installed. That choice decides your build tool, because pywrangler always installs -`workers-runtime-sdk`. - -| Package | With `crosswind-workers` and Wynd | With `workers-runtime-sdk` and pywrangler | -| --------------------- | --------------------------------- | ----------------------------------------- | -| `cf-agents` | Yes | Yes | -| `crosswind-sandboxes` | Yes | Yes | -| `containers-py` | No. It depends on `workers-runtime-sdk` 1.9.0 or later. | Yes | +`workers-runtime-sdk`. `cf-agents`, `containers-py` and `crosswind-sandboxes` work with +either SDK and install neither, so your project declares the one it uses. Wynd builds both kinds of project. It installs whichever runtime SDK your `pyproject.toml` declares, so you can switch an existing pywrangler project to Wynd and keep `workers-runtime-sdk`. `wynd types`, which writes a typed `Env` class from your Wrangler config, works only with `crosswind-workers`. -For a new Worker that doesn't use `containers-py`, use `crosswind-workers` and +For a new Worker, use `crosswind-workers` and Wynd. `uvx wynd init` writes that project for you. ## Which package to start with