Description-only preset edits split comma-containing exact goals into separate goals

未关闭 适合新手
#3,754 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 2 天内回复

@MRX-72 已经在做这个了。

开始于 2026年11月1日。

  • #3781 来自 @MRX-72 —— 未关闭

评估

难度
2/5
预计耗时
1-3 小时
新手友好度
78/100
Issue 类型
缺陷
描述清晰度
描述清楚
活跃度
活跃
技术栈
react, typescript
领域
frontend

调研方向

从 frontend/src/components/Scenarios/parameterForm.ts 开始,尤其关注第 103–107 行的列表序列化,并追踪 ScenarioPresetEditor 如何提交未更改的目标值。无损保留列表值,使得仅编辑描述时仍能保留目标内容、顺序、重复项和空列表;验证已报告的目标包含逗号的情况以及列出的其他边缘情况。

由索引模型根据 Issue 内容生成。

描述

help wanted
Describe the bug

Editing only a scenario preset description serializes an unconstrained list of exact goals as comma-joined text, then splits commas inside individual goal strings into new goals.

Steps/Code to Reproduce

Open a preset with goals ['Hello, world!', 'Second goal'], edit only Description, and save through the ScenarioPresetEditor form.

Expected Results

Unrelated edits preserve the original list elements and order exactly: ['Hello, world!', 'Second goal'].

Actual Results

Editor submitted ['Hello', 'world!', 'Second goal']; goal count changed from two to three and behavioral preset identity changed. Both old and new payloads pass the actual scenario preset/configuration validators, so validation does not detect the data loss.

Verified source reference: parameter form list serialization.

Proposed fix/regression: keep list values structured or use a lossless representation; preserve untouched stored values. Cover commas, significant whitespace, empty lists, duplicates, and order. This differs from empty SearchReplace scalar strings (finding 48).

Screenshots

Not applicable; submitted payload is inline.

Versions

Tested commit d3446e045960b5ebee4641aa70fdeb03af186587, PyRIT 1.2.0.dev0, offline actual React component/router with deterministic service mocks; backend model/config validators accepted both payloads. Evidence: files/evidence/round12/comma-goal-payload.json and regressions.txt; local paths are not attachments.

主要语言
Python
星标
4.7k
派生
1k
平均合并
2 天 2 小时
30 天内合并 PR
439

环境准备

在 Codespaces 中打开

在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。

  • 没有 Dockerfile 或 Docker Compose 文件
  • 有 Pull Request 模板
  • 没有贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

microsoft/PyRIT 的其他 Issue

查看 microsoft/PyRIT 的全部 Issue

相似的 Issue

更多 Python Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。