load_audit("Nope") fails with a bare FileNotFoundError that does not say an audit folder was expected
メンテナーはふだん 1 日以内に返信
関連するプルリクエストがすでにマージされています。
- #1123 @dxnnystyles による — マージ済み
評価
調査の方向性
faircode/benchmark.py の load_audit と tests/test_load_audit.py の既存ケースから始め、フォルダーパス、マニフェストパス、discover_manifests の処理を確認してください。フォルダーが存在しない場合、audit.yaml のないフォルダーが存在する場合、似た誤記がある場合のテストを追加してください。各エラーに試行したパスが示され、利用可能な監査フォルダーまたはマニフェストパスが説明されていれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Where: faircode/benchmark.py (load_audit), tests/test_load_audit.py.
Current gap: load_audit accepts a folder or a manifest path. For a name that is neither it raises FileNotFoundError: [Errno 2] No such file or directory: 'Nope', which does not say that it looked for Nope/audit.yaml, and a typo such as "Benefits denial" (the folder is Benefits Denial) gives no hint. A name that is a real folder without an audit.yaml reports the missing file only as a path from yaml loading. The strategy error is already clear (unknown strategy: 'bogus').
Repro:
$ python3 -c "from faircode.benchmark import load_audit; load_audit('Nope')"
FileNotFoundError: [Errno 2] No such file or directory: 'Nope'
Suggested approach: raise a FileNotFoundError that names the path it tried (Nope/audit.yaml), says that folder must be an audit folder or a manifest path, and, if the folder does not exist, lists the audit folders found next to it (use discover_manifests). Add tests for a missing folder, a folder without a manifest and a close misspelling.
Done when: each of those cases produces a message that names what was tried and what exists.
- 主要言語
- HTML
- スター
- 47
- フォーク
- 45
- 平均マージ
- 3時間 15分
- マージ済み PR(30日)
- 92
環境構築
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
yakew7/Fair-Code のほかの issue
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
メンテナーはふだん 1 日以内に返信
-
enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
メンテナーはふだん 1 日以内に返信
-
bug
難易度 4/5 3〜5日 初心者へのやさしさ 57/100
メンテナーはふだん 1 日以内に返信
-
enhancement help wanted
難易度 3/5 1〜2日 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
-
enhancement help wanted
難易度 3/5 1〜2日 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信
yakew7/Fair-Code の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 82/100
neondatabase/neon-pkgs#941 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
-
bundle: ignores the manifest entry対応中かも @huacnlee が今日担当しました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 85/100
longbridge/gpui-kit#3675 ·
メンテナーはふだん 1 日以内に返信
-
area:bash bug
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
anthropics/claude-code#104799 ·
メンテナーはふだん 1 日以内に返信
-
tui: PHP code blocks without `<?php` are not syntax highlighted対応中かも @SwastikTripathi が 1 日前に担当しました。 オープンreproduced
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
anomalyco/opencode#58664 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信