Edge functions silently skipped when running from a workspace package

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

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

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

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
65/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
node.js, typescript
領域
build-system, cli

調査の方向性

Start by tracing how the CLI passes packagePath and the working directory into @netlify/build, then find the code that resolves .netlify/v1/edge-functions and the tests for workspace builds. Reproduce with netlify build in apps/web from the linked repro. Done means the edge function is bundled and .netlify/edge-functions-dist is produced when invoked from a workspace package.

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

説明

Bug

In a pnpm workspace, running netlify build or netlify deploy from a package directory skips bundling for functions in .netlify/v1/edge-functions. There's no warning, and the deploy succeeds without edge functions. Serverless functions still deploy.

It works from the workspace root with --filter, and in standalone projects.

Reproduce

Repro: https://github.com/shamilkotta/netlify-edge-monorepo-repro

Run netlify build in apps/web.

Expected: hello is bundled.

Actual: the build completes with packagePath: apps/web, but there's no "Edge Functions bundling" step and no .netlify/edge-functions-dist.

Likely cause

packagePath is set while the build's working directory stays in the package, so resolve(buildDir, packagePath, ".netlify/v1/edge-functions") appears to point at apps/web/apps/web/....

Environment

netlify-cli 27.11.1, @netlify/build 37.4.0, Node 24.13.0, macOS

Related: #7702

主要言語
TypeScript
スター
1.9k
フォーク
482
平均マージ
2日 13時間
マージ済み PR(30日)
77

環境構築

はじめの一歩

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

netlify/cli のほかの issue

netlify/cli の issue をすべて見る

似ている issue

TypeScript の issue をもっと見る

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

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