microsoft / microsoft/TypeScript

Maximum call stack size exceeded

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

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

Domain: API Needs More Info
主要言語
Go
スター
111k
フォーク
14.3k
平均マージ
2日 4時間
マージ済み PR(30日)
132

説明

🔎 Search Terms

call stack exceeded

🕗 Version & Regression Information
  • This changed between versions 5.8.3 and 5.9.2
  • This changed in commit or PR _______
  • This is the behavior in every version I tried, and I reviewed the FAQ for entries about _________
  • I was unable to test this on prior versions because _______
⏯ Playground Link

No response

💻 Code
// Your code here
🙁 Actual behavior

We noticed that there's a potential regression between the versions 5.8.3 and 5.9.2.

When allowing Dependabot to bump from 5.8.3 to 5.9.2, we started seeing the yarn astro check command failing with the following output:

🤟 ~/Sites/[project] (dependabot/npm_and_yarn/dev/typescript-5.9.2): yarn astro check          
19:42:18 [content] Syncing content
19:42:18 [content] Synced content
19:42:18 [types] Generated 103ms
19:42:18 [check] Getting diagnostics for Astro files in project...
Maximum call stack size exceeded
  Location:
    [project]/node_modules/typescript/lib/typescript.js:3371:46
  Stack trace:
    at String.replace (<anonymous>)
    at getCanonicalFileName ([project]/node_modules/typescript/lib/typescript.js:129084:17)
    at toPath3 ([project]/node_modules/typescript/lib/typescript.js:127606:12)
    at findSourceFile ([project]/node_modules/typescript/lib/typescript.js:128749:20)
    at findSourceFile ([project]/node_modules/typescript/lib/typescript.js:128749:20)
🙂 Expected behavior

I would expect the yarn astro check command to succeed with hopefully no type issues since nothing else was changed in the PR other than the version being bumped.

Additional information about the issue

No response

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

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

調査の方向性

まず、報告された yarn astro check コマンドを使い、TypeScript 5.8.3 と 5.9.2 で失敗を再現します。node_modules/typescript/lib/typescript.js 内のスタックトレースの位置、特に getCanonicalFileNametoPath3findSourceFile を調査します。回帰を特定し、maximum call stack エラーなしで check が完了すれば完了です。

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

評価

技術スタック
typescript
領域
compilers
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
25/100

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

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