Skip to content

feat: FT208 itertools — chain / islice / groupby / product / combinations#577

Merged
hideyukiMORI merged 1 commit into
mainfrom
feat/576-ft208-itertools
May 22, 2026
Merged

feat: FT208 itertools — chain / islice / groupby / product / combinations#577
hideyukiMORI merged 1 commit into
mainfrom
feat/576-ft208-itertools

Conversation

@hideyukiMORI
Copy link
Copy Markdown
Owner

Summary

  • chain: 複数リスト結合(合計アイテム数 500 上限)
  • islice: ページング処理(has_more フラグ付き)
  • groupby: ソート後グループ化(ソート必須を実証)
  • product: デカルト積(結果数 500 上限の事前チェック)
  • combinations / combinations_with_replacement: math.comb で結果数事前チェック
    • 修正 F-1: n=20, r=10 で 2000 万件生成される爆発 DoS を発見・修正
  • takewhile / dropwhile: 閾値による先頭連続分割
  • クラッカーペンテスト: 堅牢(12 攻撃ブロック)

Closes #576

Test plan

  • uv run pytest — 26 passed in sandbox
  • uv run mypy — no issues
  • uv run ruff check / ruff format --check — all passed
  • クラッカーペンテスト: 全 12 攻撃ブロック(F-1 爆発 DoS 修正済み)
  • メインプロジェクト: 456 tests passed, 93.98% coverage

🤖 Generated with Claude Code

…ions (Closes #576)

- chain: 複数リスト結合(合計アイテム数 500 上限)
- islice: ページング処理(has_more フラグ付き)
- groupby: ソート後にキー別グループ化(groupby はソート必須を実証)
- product: デカルト積(結果数 500 上限の事前チェック付き)
- combinations / with_replacement: math.comb による結果数事前チェックで爆発防御
- takewhile / dropwhile: 閾値による先頭連続分割
- クラッカーペンテスト: 堅牢(12 攻撃ブロック、爆発 DoS 修正 F-1 含む)
- 26 tests passed / mypy strict / ruff clean

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@hideyukiMORI hideyukiMORI merged commit af8a8c1 into main May 22, 2026
2 checks passed
@hideyukiMORI hideyukiMORI deleted the feat/576-ft208-itertools branch May 22, 2026 11:40
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.

FT208: itertools モジュール — chain / islice / groupby / product / combinations

1 participant