Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Cloudflare deploy refuses placement.region (targeted placement) once the Worker has secrets

オープン
#546 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

メンテナーはふだん 1 日以内に返信

まだ誰も着手していません。

評価

難易度
5/5
見積もり時間
1週間以上
初心者へのやさしさ
38/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
typescript
領域
cloud, devops

調査の方向性

Start with packages/void/src/cli/cf-version-api.ts and inspect placementFromOutput, then trace the Cloudflare deploy flow that uploads and deploys Worker versions. Compare the beta version endpoint behavior with the classic Wrangler upload path; the issue describes several possible approaches but leaves the design open. Done means targeted placement works for Workers with secrets without risking deployment of a version whose placement was dropped.

索引モデルが issue の本文から書いたものです。

説明

Summary

void deploy --platform cloudflare refuses cloudflare.placement with a region (also host / hostname) once the Worker has any secret. The only option left is { mode: 'smart' }.

Cloudflare placement.region cannot be deployed while the Worker has secrets. Remove cloudflare.placement from void.config.ts, or set it to { mode: 'smart' }.

Thrown from placementFromOutput in packages/void/src/cli/cf-version-api.ts (still present in v1.2.1).

Why it matters

Targeted placement is how you keep a Worker next to a single-region database. Our Worker talks to Postgres in us-east-1 through Hyperdrive, so we need placement: { region: 'aws:us-east-1' }. Smart placement takes time to learn and doesn't guarantee that. Almost every production Worker has secrets, so in practice this rule rules out targeted placement for real apps on Void. Plain Wrangler deploys the same config with no problem.

Repro

  1. Set cloudflare: { placement: { region: 'aws:us-east-1' } } in void.config.ts.
  2. void secret put SOME_SECRET
  3. void deploy --platform cloudflare: refused with the error above.

Notes

The code comment says this is on purpose: the Workers beta version endpoint can drop the target, and an atomic upload goes live before a read-back could catch it. Some possible ways forward:

  • Fall back to Wrangler's / the classic upload path when targeted placement is set, or
  • Upload a version without deploying it, read it back to confirm placement, then deploy it, or
  • Deploy and then verify (and roll back on a mismatch), behind an opt-in flag.

Seen on 1.1.12, still present in 1.2.1.

主要言語
TypeScript
スター
402
フォーク
32
平均マージ
10時間 18分
マージ済み PR(30日)
113

環境構築

このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

voidzero-dev/void のほかの issue

voidzero-dev/void の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。