JobData/.planning/phases/02-boss/02-01-SUMMARY.md

35 lines
1.4 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# Plan 02-01 Summary: 迁移 Boss 爬虫层至 crawler_core
**Status:** Complete
**Tasks:** 4/4
**Commit:** 46883ce
## What was built
`spiderJobs/platforms/boss/` 下 4 个文件从 `spiderJobs.core` 迁移至 `crawler_core`
- **client.py**HTTPClient 和 BossSign 导入改用 `crawler_core.http_client``crawler_core.boss.sign`
- **api.py**
- import 改为 `crawler_core.base.Result/BaseFetcher/BaseSearcher`
- `ApiResult` 全部替换为 `Result`(共 11 处,含函数签名和函数体)
- `self._http` 全部替换为 `self.http_client`(共 3 处)
- **main.py**BaseFetcher/BaseSearcher 和 BossSign 导入改用 crawler_core
- **sign.py**:改为向后兼容桩,重新导出 `crawler_core.boss.sign.BossSign`
## Key decisions
- `ApiResult``Result[T]` 字段完全兼容,仅需全量替换名称
- `self._http``self.http_client`crawler_core BaseFetcher 使用此属性名)
- `sign.py` 保留为向后兼容桩而非删除,防止可能的 `from spiderJobs.platforms.boss.sign import BossSign` 导入失败
- `company_main.py` 中的旧依赖未处理,属于 Phase 4 范畴(废弃 jobs_spider 时统一处理)
## Verification
```
✅ 所有 Boss 模块 import 成功
✅ BossSign.generate_traceid() 正常输出M-W0019d100d47adULEHVt1zf
✅ 4 个目标文件无 spiderJobs.core 旧依赖残留
```
## Self-Check: PASSED