CSV export leaves trailing commas in tags and assigned-user fields
维护者通常 1 天内回复
评估
- 难度
- 2/5
- 预计耗时
- 1-3 小时
- 新手友好度
- 88/100
- Issue 类型
- 缺陷
- 描述清晰度
- 描述清楚
- 活跃度
- 活跃
- 技术栈
- javascript
- 领域
- frontend
调研方向
从 src/services/BoardApi.js 的第 203-220 行附近开始,这里会序列化 CSV 标签和已分配用户的值。使用包含多个标签或已分配用户的卡片重现导出,然后验证每个非空字段是否使用 ", " 分隔各个条目,且末尾没有逗号。如果 repository 中有相关的 CSV 导出测试,请为这两个字段添加或更新覆盖。
由索引模型根据 Issue 内容生成。
描述
How to use GitHub
- Please use the 👍 reaction to show that you are affected by the same issue.
- Please don't comment if you have no relevant information to add. It's just extra noise for everyone subscribed to this issue.
- Subscribe to receive notifications on status change and new comments.
Describe the bug
CSV export builds tag and assigned-user values by appending ", " after every entry. It then calls slice(0, -1), which removes only the final space and leaves the final comma:
https://github.com/nextcloud/deck/blob/main/src/services/BoardApi.js#L203-L220
For example, labels Backend and Urgent are serialized as:
Backend, Urgent,
instead of:
Backend, Urgent
The same logic is used for assigned users.
This was found by reviewing the CSV serialization code on the current main branch.
To Reproduce
- Create a card with one or more tags or assigned users.
- Export the board as CSV.
- Open the exported file.
- Inspect the Tags and Assigned users columns for that card.
- Observe the trailing comma in each non-empty multi-value field.
Expected behavior
Tags and assigned users should be separated with , without a trailing separator.
Screenshots
Not applicable. Example output:
Actual: Backend, Urgent,
Expected: Backend, Urgent
Client details:
- OS: Not environment-specific
- Browser: Not environment-specific
- Version: Current
mainbranch - Device: Desktop
Server details
Not environment-specific; the defect is in client-side CSV serialization.
Logs
No error is logged. The generated CSV contains the incorrectly formatted values.
Suggested fix
Build the values using map(...).join(', ') rather than manually appending and trimming separators. This would also make the intended formatting explicit.
Related issue
#8041 discusses missing cards and metadata in board exports. This report is limited to incorrect formatting of tag and assigned-user values that are already included in CSV export.
- 主要语言
- JavaScript
- 星标
- 1.4k
- 派生
- 358
- 平均合并
- 2 天 18 小时
- 30 天内合并 PR
- 83
环境准备
在浏览器里用你自己的 GitHub 账号启动这个项目的开发容器。
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
nextcloud/deck 的其他 Issue
-
难度 2/5 1-3 小时 新手友好度 68/100
维护者通常 1 天内回复
-
Board clone API failure is treated as a successful board response可能已有人在做 @Kumar-s75 于 39 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 88/100
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 78/100
维护者通常 1 天内回复
-
1. to develop bug
难度 2/5 1-3 小时 新手友好度 78/100
nextcloud/deck#8146 · 2 条评论 · 2 个 reaction ·
维护者通常 1 天内回复
-
Date picker should automatically open popup可能已有人在做 @theoholl 于 47 天前认领。 未关闭1. to develop enhancement
难度 2/5 1-3 小时 新手友好度 68/100
nextcloud/deck#8110 · 1 个 reaction ·
维护者通常 1 天内回复
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 76/100
维护者通常 1 天内回复
-
maintenance
难度 1/5 1 小时以内 新手友好度 75/100
alphagov/accessible-autocomplete#826 ·
维护者通常 4 天内回复
-
难度 2/5 1-3 小时 新手友好度 77/100
olahol/react-tagsinput#229 ·
-
[BUG] npm pkg delete removes the first array item for a nonexistent property可能已有人在做 关联的 PR 仍在进行中或已合并。 未关闭
难度 2/5 1-3 小时 新手友好度 83/100
维护者通常 2 天内回复
-
难度 2/5 1-3 小时 新手友好度 74/100
jonathanong/no-mistakes#2260 · 1 条评论 ·
维护者通常 1 天内回复