[Bug]:托管会话自动生成的 agentId 包含冒号,正则校验失败导致会话无法执行
Maintainers usually reply within 1 day
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 68/100
- Issue type
- Bug
- Clarity
- Mostly clear
- Activity status
- Active
- Tech stack
- docker-compose, java
- Domain
- authentication, backend
Research direction
Start by locating the agentId validation and the managed session code that assembles IDs with the namespace prefix; the issue does not name files or tests. Reproduce with the managed runtime and trace the reported validation failure. Done means the generated ID passes validation and the managed session can execute successfully.
Written by the indexing model from the issue text.
Description
描述 Bug
在 AgentScope-Java Service 2.1.0-BETA1 版本中,使用平台托管会话(managed session)运行智能体时,系统自动拼接生成的 agentId 带有冒号 :,和校验正则规则冲突,会话执行直接失败。
托管运行时组装的 agentId 会带上命名空间前缀,格式类似 dpa-namespace:default:xxx,但是校验正则仅允许 [A-Za-z0-9._-]+,不支持冒号。
复现步骤
- 使用 docker compose 部署 agentscope-service 2.1.0-BETA1
- 在网页控制台创建智能体(当前界面仅有 managed runtime 这一种选项)
- 新建会话并发送消息,触发智能体执行
- 查看 service-dataplane 容器日志,出现报错,会话无法继续运行
预期行为
二选一修复即可:
- 组装用于校验的 agentId 时,去掉带冒号的命名空间前缀;
- 修改校验正则,支持冒号字符,正则调整为
[A-Za-z0-9._:-]+。
错误信息
Managed session turn failed: sessionId=sess_62a374ad4da7, error=Invalid agentId 'dpa-namespace:default:default-92145f4c-2392-448d-b506-2ac9a13e13f0-sess_62a374ad4da7': must match [A-Za-z0-9._-]+, not be all dots, and be at most 255 characters
环境信息
- AgentScope-Java 版本:2.1.0-BETA1
- Java 版本:21
- 操作系统:macOS
- 部署方式:Docker Compose,自行编译打包 service-dataplane 镜像
- 模型后端:Ollama(OpenAI 兼容接口)
- Dominant language
- Java
- Stars
- 6.1k
- Forks
- 1.5k
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 139
Getting set up
- No Dockerfile or Docker Compose file
- Has a pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from agentscope-ai/agentscope-java
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
agentscope-ai/agentscope-java#3807 ·
Maintainers usually reply within 1 day
-
[Bug]: QdrantStore treats a scheme-less IP location like 127.0.0.1:6334 as a hostnamePossibly taken @littlebird69 claimed this 1 day ago. Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
agentscope-ai/agentscope-java#3800 · 1 comment ·
Maintainers usually reply within 1 day
-
[Bug]: SubagentRunIdChainTest times out intermittently on windows-latest (the 10s .block() deadline has only a ~1.5x margin)Possibly taken A pull request linked to this issue is open or already merged. Open
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
agentscope-ai/agentscope-java#3505 ·
Maintainers usually reply within 1 day
-
[Bug]: ActionObservations.emitSafely swallows event-delivery exception (no message, no stack trace)Possibly taken @amyaxy claimed this 17 days ago. Openbug
Difficulty 1/5 Under an hour Newbie friendliness 88/100
agentscope-ai/agentscope-java#3475 ·
Maintainers usually reply within 1 day
-
[Bug]:Redis 模式下 glob 和 ls 操作被本地索引误导,无法正确发现 Redis 中实际存储的记忆文件。May be free again A pull request for this issue was closed without being merged. Openarea/harness bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
agentscope-ai/agentscope-java#3197 · 4 comments ·
Maintainers usually reply within 1 day
All issues in agentscope-ai/agentscope-java
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 80/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
federicoiosue/Omni-Notes#1039 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Dans-Plugins/Medieval-Roleplay-Engine#384 ·
Maintainers usually reply within 1 day
-
bug P2
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
ucsb-cs156/proj-frontiers#836 · 2 comments ·
Maintainers usually reply within 1 day