Skip to content

build(ruff): enforce standard logging with extra - #27

Merged
furedea merged 1 commit into
mainfrom
build/enforce-standard-logging-with-ruff
Nov 15, 2026
Merged

furedea merged 1 commit into
mainfrom
build/enforce-standard-logging-with-ruff

Conversation

@furedea-agent

@furedea-agent furedea-agent Bot commented Nov 14, 2026

Copy link
Copy Markdown
Contributor

概要

ruff の設定で G004 の ignore を外し,LOG015 と TRY400 を select に追加しました.

ルール

ルール 内容 変更 preview
G004 logging 呼び出しでの f-string 禁止 ignore から削除 いいえ(stable)
LOG015 root logger の直接呼び出し禁止 select に追加(既存の LOG プレフィックスでも対象) いいえ(stable,0.10.0〜)
TRY400 例外処理内の logger.error は logger.exception を使う select に追加 いいえ(stable)

ピン留めの ruff 0.15.11 で確認した結果,preview ルールはありません.そのため explicit-preview-rules = true に必要なフルIDの扱いは不要です.

テンプレートに対して ruff check を実行し,違反は 0 件でした.コードの修正はありません.

理由

logging は標準モジュールを使い、変数は f-string ではなく extra で渡す方針にするためです.

Refs furedea/agent-config#74

🤖 Generated with Claude Code

Remove G004 from ignore and select LOG015 and TRY400.

Both rules are stable in ruff 0.15.11.

Refs furedea/agent-config#74

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@furedea

furedea commented Nov 14, 2026

Copy link
Copy Markdown
Owner

@codex review

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 14, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-14T20:03:55.663525Z 743b7e3 Manual request
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

Copy link
Copy Markdown

Review summary

No findings. The change is config-only (pyproject.toml):

  • G is already selected, so taking G004 out of ignore turns the f-string-in-logging check on as intended.
  • LOG015 was already covered by the LOG prefix, so listing it is redundant but harmless. It's stable, so explicit-preview-rules doesn't affect it.
  • TRY400 is a stable rule. Listing it alone, without the whole TRY prefix, enables only that rule, which matches the stated intent.

No source code changed, so no new tests are needed. I couldn't run ruff check in the review sandbox, so the PR's claim of zero violations is unverified here.

🤖 Generated with Claude Code

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review: Didn't find any major issues. More of your lovely PRs please.

Reviewed commit: 743b7e3d16

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

@furedea
furedea merged commit 2ca801e into main Nov 15, 2026
18 checks passed
@furedea
furedea deleted the build/enforce-standard-logging-with-ruff branch November 15, 2026 05:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant