Skip to content

Commit 2e39526

Browse files
committed
fix ci
1 parent 55b0c05 commit 2e39526

3 files changed

Lines changed: 53 additions & 57 deletions

File tree

.github/workflows/ci.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,52 @@
1+
name: Simple CI
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
branches: [ main ]
8+
9+
jobs:
10+
quality-check:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- uses: actions/checkout@v4
14+
15+
- name: Set up Python 3.10
16+
uses: actions/setup-python@v4
17+
with:
18+
python-version: "3.10"
19+
20+
- name: Install package
21+
run: |
22+
python -m pip install --upgrade pip
23+
pip install -e .
24+
25+
- name: Test imports
26+
run: |
27+
python -c "
28+
from hello_agents import HelloAgentsLLM, SimpleAgent, ReActAgent, ReflectionAgent, PlanAndSolveAgent
29+
from hello_agents.tools import ToolRegistry
30+
print('✅ 所有核心组件导入成功')
31+
"
32+
33+
- name: Test basic functionality
34+
run: |
35+
python -c "
36+
from hello_agents.tools import ToolRegistry
37+
38+
# 测试工具注册功能
39+
registry = ToolRegistry()
40+
def test_func(x): return f'test: {x}'
41+
registry.register_function('test', 'test function', test_func)
42+
43+
# 测试工具调用
44+
result = registry.call_function('test', {'input': 'hello'})
45+
assert 'test: hello' in result
46+
print('✅ 基础功能测试通过')
47+
"
48+
49+
- name: Check Python syntax
50+
run: |
51+
python -m py_compile hello_agents/**/*.py
52+
echo "✅ Python语法检查通过"

.github/workflows/test.yml

Lines changed: 0 additions & 56 deletions
This file was deleted.

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -263,7 +263,7 @@ hello-agents/
263263
- **[Datawhale Hello-Agents 教程](https://github.com/datawhalechina/hello-agents)** - 原版教程
264264

265265
### 示例代码
266-
- **[基础示例](./examples/)** - 从入门到进阶的完整示例
266+
267267
- **[快速开始](./examples/chapter07_basic_setup.py)** - 立即体验
268268

269269
---

0 commit comments

Comments
 (0)