darnit audit silently resolves upstream and never prints the audited repo
メンテナーはふだん 3 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 76/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- cli, github, python
調査の方向性
まず packages/darnit/src/darnit/core/utils.py、特に detect_repo_from_git と detect_owner_repo を確認し、次に cmd_audit と現在の監査ログを探してください。リポジトリの解決時に検出されたリモートソースを保持し、解決された owner/repo とソースを監査出力に含めてください。関連する監査CLIテストを実行してください。ユーザーがどのリポジトリとリモートが監査されたのか確認できれば完了です。
索引モデルが issue の本文から書いたものです。
説明
Description
darnit audit <path> auto-detects owner/repo preferring the upstream remote, and never prints which owner/repo it resolved. On a fork checkout (both origin and upstream present), the live checks target upstream — potentially a different repo than the one the user is working in — with no indication in the output.
Steps to Reproduce
- Clone a fork so the checkout has both
origin(your fork) andupstreamremotes. - Run
darnit audit <path>with authenticatedgh. - Inspect which
owner/repothe livegh apichecks target.
Expected Behavior
The audit output states the resolved owner/repo and which remote it came from, so it's obvious which repository was audited.
Actual Behavior
The checks target upstream silently; the CLI logs only Auditing {path} with {N} controls. Details:
packages/darnit/src/darnit/core/utils.py:186, :302—prefer_upstream: bool = True.utils.py:231—remotes = ["upstream", "origin"] if prefer_upstream else ["origin", "upstream"].cmd_auditcallsdetect_owner_repo(str(repo_path))with no override and prints no repo identity.
The information already exists internally: detect_repo_from_git returns a source field (utils.py:263, 275), but the detect_owner_repo wrapper (:299) collapses it to (owner, repo) and the CLI discards it.
Environment
- darnit version:
main@86f9cfa - Python version: 3.12 (uv-managed)
- OS: any
Additional Context
Suggested fix (visibility only): print the resolved owner/repo + source remote at the top of audit output. A new --owner/--repo flag is likely unnecessary — the origin-preference path (prefer_upstream=False) already resolves origin correctly.
- 主要言語
- Python
- スター
- 22
- フォーク
- 27
- 平均マージ
- 4日 20時間
- マージ済み PR(30日)
- 75
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
darnitdevorg/darnit のほかの issue
-
ci needs triage
難易度 2/5 1〜3時間 初心者へのやさしさ 62/100
darnitdevorg/darnit#607 ·
メンテナーはふだん 3 日以内に返信
-
good first issue maintenance
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
darnitdevorg/darnit#587 · コメント 2 件 ·
メンテナーはふだん 3 日以内に返信
-
Container image has no zizmor, so OSPS-AC-04.02 always reports missing_tool対応中かも @mlieberman85 が 20 日前に担当しました。 オープンinfrastructure module-baseline
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
darnitdevorg/darnit#585 · コメント 1 件 ·
メンテナーはふだん 3 日以内に返信
-
documentation module-core
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
darnitdevorg/darnit#196 ·
メンテナーはふだん 3 日以内に返信
-
module-core
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
darnitdevorg/darnit#195 ·
メンテナーはふだん 3 日以内に返信
darnitdevorg/darnit の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
strawberry-graphql/strawberry#4794 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
dataforgoodfr/cetolog#21 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
btclib-org/btclib#2932 ·
メンテナーはふだん 1 日以内に返信
-
metrics priority: medium
難易度 1/5 1〜3時間 初心者へのやさしさ 86/100
LearningCircuit/local-deep-research#8336 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 80/100