Suppression comments in inactive code are reported as unused
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 55/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 活発
- 領域
- backend, testing-qa
調査の方向性
Start by reproducing the report in the Pyrefly sandbox using the provided configuration and Python example. Then trace how inactive branches and # type: ignore comments are analyzed; the payload names no source files or tests, so locate the relevant test entry point. Done when the reported suppression is recognized as used and a regression test covers the example.
索引モデルが issue の本文から書いたものです。
説明
Describe the Bug
# Pyrefly sandbox configuration.
# See https://pyrefly.org/en/docs/configuration/ for available configuration options.
python-version = "3.12"
[errors]
unimported-directive = 'ignore'
not-required-key-access = 'warn'
no-any-return = 'error'
unused-type-ignore = 'error'
import sys
def via_else() -> int:
if sys.version_info < (3,13):
return 0
else:
x = 1
return "x" # type: ignore
ERROR sandbox.py:8:21-35: Unused `# type: ignore` comment [[unused-type-ignore](https://pyrefly.org/en/docs/error-kinds/#unused-type-ignore)]
I don't think the "unused # type: ignore" diagnostic is right? The return 'x' is incompatible with -> int so the # type: ignore isn't in fact unused?
Sandbox Link
(Only applicable for extension issues) IDE Information
No response
- 主要言語
- Rust
- スター
- 7.2k
- フォーク
- 578
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
facebook/pyrefly のほかの issue
-
pytorch tensor-shapes typechecking
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
-
good first issue typechecking
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
-
cargo b warning: unused dependency `zstd`対応中かも @Narendersingh007 が 4 日前に担当しました。 オープンgood first issue
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
-
難易度 4/5 3〜5日 初心者へのやさしさ 30/100
-
pydantic
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
facebook/pyrefly の issue をすべて見る
似ている issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
eventflux-io/eventflux#203 ·
メンテナーはふだん 1 日以内に返信
-
bug ui
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
userFRM/egui-charts#4068 ·
メンテナーはふだん 1 日以内に返信
-
fuzz-crash review-followup
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
marketing
難易度 2/5 半日 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
aws/aws-emulator#610 ·