Skip to content

fix: 补全 CLI 提交题配置 - #8

Merged
Shimada666 merged 1 commit into
mainfrom
fix/submission-config-contract
Aug 10, 2026
Merged

fix: 补全 CLI 提交题配置#8
Shimada666 merged 1 commit into
mainfrom
fix/submission-config-contract

Conversation

@Shimada666

Copy link
Copy Markdown
Collaborator

问题\n\nCLI 创建 submission 题时只写入部分 submissionConfig。Study Check 按前端 canonical 契约读取 requireText 等字段时会触发 KeyError,Open API 对外表现为 502。\n\n## 修改\n\n- CLI 创建 submission 题时写入与前端一致的完整配置\n- 禁用文字输入时同步关闭 requireText\n- 增加最小契约测试\n\n## 验证\n\n- bun test(11 passed)\n- bun run typecheck\n- bun run bundle\n- Preview main 真实创建 submission 题后执行 interview check,不再返回 502;测试题已删除

@Shimada666
Shimada666 requested a review from mizzenbot August 10, 2026 13:15

@github-actions github-actions Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Taste Rating:好品味

Linus-Style Analysis: 改动以单一构造函数集中 submission 配置,补齐 canonical 契约字段,并使禁用文字输入与 requireText 保持一致;实现直接且不改变既有 CLI 参数语义。新增测试覆盖默认完整配置和关键联动分支。

[RISK ASSESSMENT]

  • [Overall PR] ⚠️ 风险评估:🟢 低。仅新增固定的 API 配置字段和纯函数测试;无依赖、凭证或协议路径变更。

VERDICT:
值得合并:核心逻辑正确,且 PR 描述提供了 Preview 真实创建与检查的端到端验证。

KEY INSIGHT:
将完整 submission 配置收敛到一个构造函数,可避免 CLI 与前端契约再次因字段遗漏而漂移。

此审查由 AI 代理(OpenHands)代表用户生成。


Was this automated review useful? React with 👍 or 👎 to this review to help us measure review quality.
Workflow run: https://github.com/MizzenAI/mizzen-cli/actions/runs/31392012526

@Shimada666
Shimada666 merged commit 16f6d4a into main Aug 10, 2026
1 check passed
@Shimada666
Shimada666 deleted the fix/submission-config-contract branch August 10, 2026 13: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.

1 participant