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

Build-test fixtures that no longer test what they claim

オープン 初心者向け
#8,827 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

@cknitt がすでに取り組んでいます。

2026年10月12日 から。

  • #8838 @cknitt による — オープン

評価

難易度
2/5
見積もり時間
1〜3時間
初心者へのやさしさ
78/100
issue の種類
バグ
明瞭さ
明確に書かれている
活発さ
活発
技術スタック
javascript, node.js, ocaml
領域
testing

調査の方向性

tests/build_tests/rescript_tools_binary_path/input.jsとそのfixtureの設定を読み、weird_depsとweird_devdepsのrescript.jsonファイルを調べてください。rescript_tools_binary_path用のfixture package.jsonを追加し、他のfixtureのsourcesを空のリストに設定してください。fixtureが意図したパッケージのインポート動作を検証し、削除済みのソースフォルダーを列挙しなくなれば完了です。

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

説明

Found by adversarial experiments on semantic analysts.

Each item below is a build-test fixture whose setup no longer matches its purpose.

  • rescript_tools_binary_path passes with the import it guards against.
    • input.js runs the compiled src/Main.mjs and src/Main.cjs inside the repository.
    • The fixture has no package.json, so Node resolves # specifiers in those files against the repository root package.json, which defines #cli/*.
    • The bug fixed by #8694 (@module("#cli/bins") emitted into user code) therefore does not reproduce here. The commit message of 45446347c says the test uses its own package.json, but none is checked in.
    • Reproduction at 8d51b9ce7 in tests/build_tests/rescript_tools_binary_path, with node_modules/rescript linked to the repo root as input.js does. The two files contain the JS that bsc emits for the pre-#8694 external:
      printf 'import * as Bins from "#cli/bins";\nconsole.log(Bins.rescript_tools_exe);\n' > src/Old.mjs
      printf 'let Bins = require("#cli/bins");\nconsole.log(Bins.rescript_tools_exe);\n' > src/Old.cjs
      node src/Old.mjs; node src/Old.cjs   # both print …/bin/rescript-tools.exe
      echo '{"name":"user-project","private":true}' > package.json
      node src/Old.mjs   # ERR_PACKAGE_IMPORT_NOT_DEFINED
      node src/Old.cjs   # Error: Cannot find module '#cli/bins'
      
    • With that package.json in place, the current Main.mjs and Main.cjs (importing rescript/tools) still print the binary path.
    • Fix: check in a fixture package.json.
  • weird_deps and weird_devdeps list deleted source folders.
主要言語
OCaml
スター
7.5k
フォーク
484
平均マージ
18時間 19分
マージ済み PR(30日)
116

環境構築

Codespaces で開く

このプロジェクトの開発コンテナを、あなたの GitHub アカウントでブラウザ上に起動します。

はじめの一歩

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

rescript-lang/rescript のほかの issue

rescript-lang/rescript の issue をすべて見る

似ている issue

Testing & QA の issue をもっと見る

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

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