Commit 9ffb0bd
fix: register_agent decorator NameError (AstrBotDevs#5765)
* fix: 修改 register_agent 以避免运行时导入 AstrAgentContext
* test: improve register_agent test robustness
- Add fixture for llm_tools cleanup to avoid test interference
- Use multiple import patterns to make guard more robust to refactors
- Add assertion to verify decorated coroutine is wired as handoff handler
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* 删除测试文件: 移除 register_agent 装饰器的运行时行为测试
---------
Co-authored-by: whatevertogo <whatevertogo@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Soulter <905617992@qq.com>1 parent ef83ceb commit 9ffb0bd
1 file changed
Lines changed: 5 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
5 | | - | |
| 5 | + | |
6 | 6 | | |
7 | 7 | | |
8 | 8 | | |
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | 18 | | |
22 | 19 | | |
23 | 20 | | |
| |||
649 | 646 | | |
650 | 647 | | |
651 | 648 | | |
652 | | - | |
| 649 | + | |
653 | 650 | | |
654 | 651 | | |
655 | 652 | | |
656 | 653 | | |
657 | 654 | | |
658 | 655 | | |
659 | 656 | | |
660 | | - | |
| 657 | + | |
661 | 658 | | |
662 | 659 | | |
663 | 660 | | |
| |||
671 | 668 | | |
672 | 669 | | |
673 | 670 | | |
674 | | - | |
| 671 | + | |
675 | 672 | | |
676 | 673 | | |
677 | 674 | | |
678 | 675 | | |
679 | | - | |
| 676 | + | |
680 | 677 | | |
681 | 678 | | |
682 | 679 | | |
| |||
0 commit comments