[Good first issue] 修复评测 CLI 在 --flag=value 后跳过参数

Open Beginner friendly
#60 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
84/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
bun, typescript
Domain
cli

Research direction

Start with parseFlags in scripts/eval/run.ts (around lines 135-170), where the index advances after consuming an inline --flag=value, and check the duplicate --case handling near lines 258-264. Run bun test scripts/eval/config-chain.test.ts to see the existing CLI argument tests. Done when --flag=value consumes only the current argument, --flag value still consumes two, and the two added regression tests pass.

Written by the indexing model from the issue text.

Description

area:evaluation bug good first issue help wanted

问题与复现

CLI 识别 --flag=value,但消费内联值后仍会前移参数下标。复验 parseFlags(['--case=fv1-market-001', '--case=fv1-market-002']),只留下第一条用例。parseFlags(['--dataset=trail-agent-v1-zh', '--smoke']) 的 smoke 仍为 false。使用分隔写法 --case <id> 时,两条用例都被保留。

在 Windows 和 Bun 1.4.2 上基于 main 的 579395e 验证。 直接调用参数解析函数即可复现。

验收标准

  • --flag=value 只消费当前参数,--flag value 消费两项,两种写法可混用。
  • 补两条无凭证回归。一条覆盖重复 --case,另一条覆盖带值选项后紧跟 --smoke。从 bun test scripts/eval/config-chain.test.ts 开始。

源码起点

认领前可先说明准备完成的范围,再评论 /claim。参与方式见 #7。

Dominant language
TypeScript
Stars
206
Forks
37
Avg merge
8h 8m
Merged PRs (30d)
7

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from ydflow/Trail

All issues in ydflow/Trail

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.