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

Attestation predicate reads `project_config.project_type`, which `ProjectConfig` does not define

オープン
#521 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

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

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

2026年10月16日 から。

  • #614 @mlieberman85 による — オープン

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
62/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
活発
技術スタック
python
領域
security

調査の方向性

Read packages/darnit-baseline/src/darnit_baseline/attestation/predicate.py alongside the ProjectConfig schema at packages/darnit/src/darnit/config/schema.py, then inspect the predicate callers and existing tests. Add coverage for building a predicate with a real ProjectConfig; done means the predicate no longer raises and its no-config type behavior is decided and documented in the predicate changelog.

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

説明

module-baseline quality

packages/darnit-baseline/src/darnit_baseline/attestation/predicate.py:147 builds the predicate with:

"project_type": project_config.project_type if project_config else "software",

ProjectConfig (packages/darnit/src/darnit/config/schema.py) has a type field, not project_type (create_minimal_config(..., project_type=...) maps its argument to type=). When a project configuration is passed (attestation/__init__.py:22, attestation/generator.py:92), this raises AttributeError instead of producing a predicate. It has gone unnoticed because the common paths pass None and fall back to "software".

Proposed fix:

  • Read project_config.type.
  • Decide whether the "software" fallback is right when no configuration exists: it states a project type nobody confirmed. Omitting the field, or recording it as unknown, may be more accurate. This is a predicate field, so the change is observable by attestation consumers and should be noted in the predicate's changelog.
  • Add a test that builds a predicate with a real ProjectConfig.
主要言語
Python
スター
22
フォーク
27
平均マージ
1日 19時間
マージ済み PR(30日)
39

環境構築

はじめの一歩

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

darnitdevorg/darnit のほかの issue

darnitdevorg/darnit の issue をすべて見る

似ている issue

Python の issue をもっと見る

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

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