Hacktoberfest 2026:维护者为十月标记出来的 issue,仍然开放、适合新手。 浏览 Hacktoberfest issue

Conversation editor never revokes blob URLs of removed attachments

已关闭
#3,185 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

维护者通常 2 天内回复

@ManoharPaturi 已经在做这个了。

开始于 2026年10月13日。

  • #3186 来自 @ManoharPaturi —— 未关闭

评估

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

调研方向

Start with ChatInputArea.changeAttachments, which already revokes dropped blob URLs, and compare it with useConversationDraft.changeAttachments, which the ConversationEditor piece editor calls without revoking anything. The attachment chip URLs are created in PromptEditor with URL.createObjectURL. Done means removing an attachment in the draft editor calls URL.revokeObjectURL right away. Pull request #3186 is already open against this issue, so review or build on that work rather than starting a parallel fix.

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

描述

Describe the bug

In the conversation editor, removing an attachment from a media piece never revokes the attachment's blob object URL. The blob: URL and its File payload stay alive until the whole draft is discarded or the editor unmounts.

ChatInputArea.changeAttachments handles the same removal correctly by revoking dropped blob URLs, but the draft editor path (ConversationEditor piece editor calling useConversationDraft.changeAttachments) forwards the new attachment list straight through with no revocation. Attaching and removing a large file repeatedly during one editing session pins every dropped File in memory.

Steps/Code to Reproduce
  1. Open a conversation in the editor and pick a media piece.
  2. Attach a file (the attachment chip gets a blob: URL from URL.createObjectURL in PromptEditor).
  3. Remove the attachment with the chip's dismiss button.
  4. URL.revokeObjectURL is never called for that URL until the draft is discarded or the editor unmounts.

Repeat 2-3 in one session and the dropped Files accumulate.

Expected Results

Removing an attachment in the editor revokes its blob object URL immediately, the same way the chat composer does.

Actual Results

The URL stays valid and the File payload stays pinned until the draft is discarded or unmounted.

Screenshots

N/A

Versions

OS: macOS
Browser: Chrome
Python version: 3.14
PyRIT version: installed from main (66c41fa)

主要语言
Python
星标
4.6k
派生
944
平均合并
2 天 17 小时
30 天内合并 PR
328

环境准备

在 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 摘要。