aliyun / aliyun/aliyun-log-python-sdk
文档 拉取(Pull)数据 里面有错误
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 176
- Forks
- 119
- Avg merge
- 3h 56m
- Merged PRs (30d)
- 2
Description
https://aliyun-log-python-sdk.readthedocs.io/README_CN.html#pull
# 或者大并发直接下载在本地
it = client.pull_log('project1', 'logstore1', from_time="2018-1-1 10:10:10", to_time="2018-1-1 10:20:10", file_path="/data/dump_{}.data")
for res in it:
res.log_print()
这里应该写错了,应该是 client.pull_log_dump 而不是 client.pull_log;
另外 pull_log_dump 中使用了进程池,例子中需要加 if __name__ == '__main__': ,不然会报错 concurrent.futures.process.BrokenProcessPool: A process in the process pool was terminated abruptly while the future was running or pending
而且似乎 pull_log_dump 的结果也是不可迭代的
Contributor guide
No contributing guide indexed for this repository
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.
Research direction
Start with the Pull example in README_CN.html and compare the documented client.pull_log call with pull_log_dump. Inspect pull_log_dump's process-pool behavior and verify whether its result is iterable; update the example with the correct entry point and required main guard, and clarify how results should be consumed.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100