Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
416 commits
Select commit Hold shift + click to select a range
48bbc0c
Update README.md
dataabc May 31, 2020
2f054e4
Update README.md
dataabc May 31, 2020
48a10b0
perf: 优化config.json文件读取
dataabc Jun 1, 2020
11ddfaf
Update README.md
dataabc Jun 1, 2020
9f8d277
feat: 为pypi版user_id_list参数添加相对路径支持
dataabc Jun 2, 2020
9da8f68
fix: 修复只能将结果文件写入程序所在目录的bug
dataabc Jun 2, 2020
4c276c3
fix: 修复log.txt只能写入程序目录的bug
dataabc Jun 2, 2020
93b48ee
Code refactor. related #160
songzy12 Jun 2, 2020
ab4559c
perf: 优化用户提示
dataabc Jun 2, 2020
b9bf4f0
Merge branch 'master' of github.com:dataabc/weiboSpider into multi-file
songzy12 Jun 2, 2020
592496b
serveral bug fix
songzy12 Jun 2, 2020
7f0a82c
Update README.md
dataabc Jun 6, 2020
837e616
fix: 修复模块路径问题
dataabc Jun 6, 2020
842ae75
git rollback
dataabc Jun 6, 2020
33376d1
Update README.md
dataabc Jun 6, 2020
03103a7
fix: 修复pypi版无法添加配置文件的问题
dataabc Jun 7, 2020
fdf32bf
fix: 修复运行程序必须安装pymysql的问题
dataabc Jun 7, 2020
57a541d
perf: 删除python2相关代码
dataabc Jun 7, 2020
c6ffb68
fix: 修复爬取数目统计不准确的bug
dataabc Jun 7, 2020
d0d9123
Create CONTRIBUTING.md
dataabc Jun 7, 2020
14e3b38
Update CONTRIBUTING.md
dataabc Jun 7, 2020
7fc570c
Update CONTRIBUTING.md
dataabc Jun 8, 2020
6caab55
Update CONTRIBUTING.md
dataabc Jun 8, 2020
0688fcf
Update CONTRIBUTING.md
dataabc Jun 8, 2020
9541088
docs: 优化说明文档结构
dataabc Jun 9, 2020
6b54b93
Merge branch 'master' of https://github.com/dataabc/weiboSpider
dataabc Jun 9, 2020
c443934
Create settings.md
dataabc Jun 9, 2020
d408d8a
Create automation.md
dataabc Jun 9, 2020
3802319
Update README.md
dataabc Jun 9, 2020
661158b
Update example.md
dataabc Jun 9, 2020
bdf130e
Update automation.md
dataabc Jun 9, 2020
993ffdf
Update settings.md
dataabc Jun 9, 2020
42f4daf
Update README.md
dataabc Jun 9, 2020
4bcf0cd
Update CONTRIBUTING.md
dataabc Jun 9, 2020
c4ff63d
perf: 优化文件名
dataabc Jun 10, 2020
a95f421
Update requirements.txt
songzy12 Jun 9, 2020
86efdea
Code factor for writer module. Related: #160
songzy12 Jun 10, 2020
78abbe9
Code refactor for downloader module. Related: #160
songzy12 Jun 10, 2020
08dee30
[#160] Code refactor for module parser.
songzy12 Jun 10, 2020
23a33c7
Update issue templates
dataabc Jun 10, 2020
ba97352
Rename bug--.md to bug-report.md
dataabc Jun 10, 2020
a0143bc
Update and rename --.md to other.md
dataabc Jun 10, 2020
57a8bd3
Rename other.md to others.md
dataabc Jun 10, 2020
478fe1b
Rename others.md to other-question.md
dataabc Jun 10, 2020
9fd78c4
Update and rename ----.md to feature-request.md
dataabc Jun 10, 2020
66eaa57
Rename other-question.md to other.md
dataabc Jun 10, 2020
a60216c
Rename ------.md to failed.md
dataabc Jun 10, 2020
0f51c22
Update README.md
dataabc Jun 11, 2020
6dd7cfb
Update README.md
dataabc Jun 11, 2020
01382bc
[#160] minor refactor: remove some code in get_user_info.
songzy12 Jun 11, 2020
e3b8d7a
Create stale.yml
dataabc Jun 14, 2020
1dc3e3a
refactor [#160]: make class User to group user related info.
songzy12 Jun 14, 2020
0775d33
refactor[fix #160]: group info about one weibo to class Weibo.
songzy12 Jun 14, 2020
0492015
doc: update README.md.
songzy12 Jun 14, 2020
a99fd13
Create FAQ.md
dataabc Jun 14, 2020
3c4d3a5
Update FAQ.md
dataabc Jun 15, 2020
c6d2d8e
fix: minor fix of weibo printer to only include necessary info.
songzy12 Jun 18, 2020
86d18ca
feat: add a mechanism to generate mock test data for url requests.
songzy12 Jun 18, 2020
9810d42
tests: add a test and related test data for page_parser.
songzy12 Jun 18, 2020
4281c27
tests[#168]: add a test and related test data for page_parser.
songzy12 Jun 18, 2020
c2719e3
fix: bug fix for comment_parser.
songzy12 Jun 18, 2020
666e7b7
tests: update test data and add test for comment_parser.
songzy12 Jun 18, 2020
f262775
Merge branch 'auto-test'
songzy12 Jun 18, 2020
8d73788
tests[#168]: add test for index_parser.
songzy12 Jun 18, 2020
b617483
tests[#168]: add test for info_parser
songzy12 Jun 18, 2020
4a042ec
tests[#168]: add test for mblog_picAll_parser
songzy12 Jun 18, 2020
bb32883
tests[#168]: move the parser tests to folder tests/test_parser/
songzy12 Jun 18, 2020
1b219a9
Create python-app.yml
songzy12 Jun 18, 2020
45ad203
Update README.md
songzy12 Jun 18, 2020
87b3189
fix the test function names
songzy12 Jun 18, 2020
ee981db
fix: 修复因user_id_list.txt文件不正确出错的bug
dataabc Jun 20, 2020
0258250
Update README.md
dataabc Jun 21, 2020
349a399
Update failed.md
dataabc Jun 21, 2020
d4584d6
Update bug-report.md
dataabc Jun 21, 2020
5eb8dc0
fix: 修复无法按照user_id_list.txt为多个id单独设置since_date的问题
dataabc Jun 25, 2020
5b9278f
feat: 添加按时间段获取微博的功能
dataabc Jun 25, 2020
01eced1
fix: 修复yyyy-mm-dd H:M格式的时间无法准确识别的bug
dataabc Jun 25, 2020
3ac424d
refactor: change filename of weibo_spider.py to spider.py
songzy12 Jun 26, 2020
b4e8b27
perf: 优化日期格式处理
dataabc Jun 26, 2020
4b1e783
Update FAQ.md
dataabc Jun 26, 2020
000f478
Update example.md
dataabc Jun 26, 2020
80f4319
Update settings.md
dataabc Jun 26, 2020
a4a65a2
新增运行方式
codermino Jun 27, 2020
7c7a6a1
Merge pull request #175 from codermino/develop
dataabc Jun 27, 2020
08ce0c0
fix: 修复user_id_list.txt路径问题
dataabc Jun 27, 2020
2066ddb
perf: 优化时间格式处理
dataabc Jul 4, 2020
c60d9d9
fix: 修复自动更新since_date时新值不正确的bug
dataabc Jul 4, 2020
2a43116
feat: 添加以命令行参数的形式输入user_id的功能
dataabc Jul 4, 2020
182565c
fix: 修复当end_date值非now时无法获取图片的问题
dataabc Jul 5, 2020
2b34e32
Update README.md
dataabc Jul 5, 2020
347d0a5
per: 优化文件写入路径
dataabc Jul 5, 2020
54e9fd2
Update settings.md
dataabc Jul 5, 2020
141d23d
feat: 添加日志功能
dataabc Jul 11, 2020
0563200
Create contributors.md
dataabc Jul 19, 2020
1cfc526
Update contributors.md
dataabc Jul 21, 2020
cb1abe7
perf: 优化not_downloaded.txt内容写入
dataabc Jul 22, 2020
3f623d8
Update contributors.md
dataabc Jul 23, 2020
16191db
Update README.md
dataabc Jul 23, 2020
79f5bd0
fix: 修复当since_date为未来时,user_id_list.txt生成的新since_date为空的bug
dataabc Jul 24, 2020
6943914
perf: 优化微博间的时间等待
dataabc Jul 24, 2020
8bc5b92
feat: 添加通过config.json控制随机等待的功能
dataabc Jul 25, 2020
0b46258
feat: 添加对random_wait_pages和random_wait_seconds参数是否正确的检测
dataabc Jul 25, 2020
71a558d
Update settings.md
dataabc Jul 26, 2020
007cc39
Update FAQ.md
dataabc Jul 26, 2020
01e8232
perf: 优化参数random_wait_pages、random_wait_seconds检测
dataabc Jul 26, 2020
9ceb9f6
feat: 添加全局等待功能
dataabc Jul 28, 2020
500f344
feat: 添加对global_wait参数正确性的检测
dataabc Jul 28, 2020
e2199f1
perf: 优化全局等待提示
dataabc Jul 28, 2020
1b14ec7
perf: 优化多微博用户全局等待提示
dataabc Jul 28, 2020
4723423
Update settings.md
dataabc Jul 28, 2020
f8b8c4d
Update FAQ.md
dataabc Jul 29, 2020
ef3e4e7
Update FAQ.md
dataabc Jul 29, 2020
bca8b4f
Update settings.md
dataabc Jul 29, 2020
bb8db00
Update config_sample.json
dataabc Jul 30, 2020
332dd25
Update README.md
dataabc Aug 1, 2020
d92e585
perf: 优化since_date参数处理
dataabc Aug 6, 2020
d16adba
Let git ignore log files.
songzy12 Aug 13, 2020
3c4cf55
添加sqlite支持,只需要在config.json中简单配置。
MKSP2015 Sep 3, 2020
747980f
Update spider.py
MKSP2015 Sep 4, 2020
e372eca
Delete weibo.db
MKSP2015 Sep 4, 2020
0e17155
Merge pull request #216 from MKSP2015/master
dataabc Sep 4, 2020
9ed19ef
Update contributors.md
dataabc Sep 4, 2020
65380cc
fix: 修复获取长微博失败时正文变成网络出错的bug
dataabc Sep 12, 2020
3dd09df
Merge branch 'master' of https://github.com/dataabc/weiboSpider
dataabc Sep 12, 2020
828f507
Update README.md
dataabc Sep 15, 2020
026662a
Update settings.md
dataabc Sep 15, 2020
ec4e7a1
fix: 修复sqlite默认路径问题
dataabc Sep 15, 2020
b8399df
Update settings.md
dataabc Sep 15, 2020
5714fe7
fix: 修复信息过长时无法写入数据库的问题
dataabc Sep 27, 2020
d1973b0
Update page_parser.py
bluerthanever Oct 9, 2020
3b57d8e
Update spider.py
bluerthanever Oct 9, 2020
89e15fa
Update test_page_parser.py
bluerthanever Oct 9, 2020
68872a6
Merge pull request #233 from bluerthanever/master
dataabc Oct 9, 2020
c7881f8
add function: bid2mid
Oct 10, 2020
8d9382b
Merge pull request #238 from codingcindy/master
dataabc Oct 12, 2020
cf3cb79
fix: 修改无法保存最后一页微博的问题
dataabc Oct 14, 2020
190f461
fix: 修复因没有某些视频浏览权限而出错的问题
dataabc Oct 17, 2020
d224940
git ignore .idea
moqimoqidea Oct 18, 2020
406c810
将 MySQL 库建表语句的正文长度上限提高到 5000
moqimoqidea Oct 19, 2020
366d322
Merge pull request #247 from ToolCollection01/master
dataabc Oct 19, 2020
3d04289
perf: 优化微博访问
dataabc Nov 9, 2020
5e29c28
fix: 修复test错误
dataabc Nov 9, 2020
27eb176
Minor typo fix.
songzy12 Nov 21, 2020
267197f
Merge pull request #257 from songzy12/log-typo
dataabc Nov 21, 2020
5d29f10
feat: 添加配置结果目录文件名的功能
dataabc Dec 1, 2020
ad0e11d
Merge branch 'master' of https://github.com/dataabc/weiboSpider
dataabc Dec 1, 2020
bb79fef
Update settings.md
dataabc Dec 1, 2020
ce3f312
feature: 增加kafka writer,支持向kafka实时推送爬取的数据
windlively Dec 4, 2020
03c8c89
Update weibo_spider/writer/kafka_writer.py
windlively Dec 4, 2020
6000b2d
Merge pull request #265 from baijunhan/master
dataabc Dec 4, 2020
669bf2c
fix: 修复没有安装kafka而出错的bug
dataabc Dec 5, 2020
e8cacd3
feat: user_id_list在config.json支持混合的模式
eggachecat Dec 9, 2020
d77a695
Merge pull request #270 from eggachecat/master
dataabc Dec 9, 2020
50034ce
Update example.md
dataabc Dec 10, 2020
3b21f76
feat: 添加文件下载超时控制
dataabc Dec 16, 2020
95613a4
Update settings.md
dataabc Dec 22, 2020
617a910
perf: 优化user_id_list.txt更新
dataabc Dec 29, 2020
1d0ab7c
Merge branch 'master' of https://github.com/dataabc/weiboSpider
dataabc Dec 29, 2020
819c83a
build(deps): bump lxml from 4.5.1 to 4.6.2
dependabot[bot] Jan 7, 2021
5034599
Merge pull request #288 from dataabc/dependabot/pip/lxml-4.6.2
dataabc Jan 8, 2021
a00d469
perf: 优化test
dataabc Jan 8, 2021
89b30e9
Update README.md
dataabc Jan 20, 2021
ab2b02b
Update README.md
dataabc Jan 20, 2021
ce65ca5
fix: 修复遇到无限id终止的问题
dataabc Feb 19, 2021
1482571
fix: 修复因访问mysql出错而终止的问题
dataabc Feb 19, 2021
350c96b
Create academic.md
dataabc Mar 8, 2021
84411d1
Update README.md
dataabc Mar 8, 2021
4ee0332
Update academic.md
dataabc Mar 13, 2021
135d698
fix: 修复连续获取空页面的问题
dataabc Mar 17, 2021
885069e
fix: 修复部分微博无法写入mysql的bug
dataabc Mar 19, 2021
448e408
fix: 修复使用kafka时部分内容为空的bug
dataabc Mar 26, 2021
325abbc
build(deps): bump lxml from 4.6.2 to 4.6.3
dependabot[bot] Mar 26, 2021
ee1048f
Merge pull request #319 from dataabc/dependabot/pip/lxml-4.6.3
dataabc Mar 26, 2021
c12830d
fix(test data): 修复 Windows 系统下写入 Test Data 文件报错的问题
schaepher Mar 28, 2021
b257331
docs(faq): 获取自己的微博不需要修改 info_parser.py
schaepher Mar 28, 2021
ffcb452
chore(gitignore): 忽略使用 SQLite 时生成的 weibo.db
schaepher Mar 28, 2021
3d7eca5
feat(downloader): 添加下载原微博图片的功能
schaepher Mar 28, 2021
7ea2882
Merge pull request #320 from schaepher/fix_windows_write_testdata
dataabc Mar 28, 2021
e6e2ac8
Merge pull request #322 from schaepher/ignore_weibo_sqlite_db
dataabc Mar 28, 2021
2d3a1fa
Merge pull request #323 from schaepher/download_retweet_picture
dataabc Mar 28, 2021
5b37b29
Merge pull request #321 from schaepher/faq_fetch_self_weibo
dataabc Mar 28, 2021
358da5a
fix(page_parser): 修复在爬取全部微博的时候忽略视频的问题
schaepher Mar 28, 2021
c8047f8
fix(downloader): 删除下载文件名中多余的空格
schaepher Mar 28, 2021
5a52e5f
Merge pull request #325 from schaepher/delete_filename_space
dataabc Mar 29, 2021
939985a
Merge pull request #324 from schaepher/download_video_if_filter_0
dataabc Mar 30, 2021
7cb0b2f
feat(page_parser): 添加获取长微博视频链接的功能
schaepher Mar 28, 2021
85333bd
fix(video url): 修复丢失视频号微博视频的问题
schaepher Mar 30, 2021
b046cb2
Merge pull request #327 from schaepher/get_long_weibo_video_url
dataabc Mar 31, 2021
d90e35a
Update README.md
dataabc Apr 1, 2021
4e195f5
perf: 优化图片存储目录
dataabc Apr 1, 2021
9db54e1
perf: 优化图片下载
dataabc Apr 1, 2021
2853c42
perf: 优化爬取停止流程
dataabc Apr 15, 2021
942ce80
Fix markdown style.
songzy12 Jun 5, 2021
24e4915
Merge pull request #347 from songzy12/markdown-style-fix
dataabc Jun 6, 2021
7f35979
Update README.md
mtuwei Aug 1, 2021
5a63f74
Merge pull request #366 from mtuwei/master
dataabc Aug 13, 2021
7698890
Add photo parser and unit test.
songzy12 Aug 18, 2021
1884a8d
Add album parser and unit test.
songzy12 Aug 18, 2021
52cbbaf
Feature: download avatar pictures.
songzy12 Aug 19, 2021
7bacd0d
Merge pull request #371 from songzy12/album_parser
dataabc Aug 20, 2021
5d6fc80
fix: 修复部分微博缺失的问题
dataabc Sep 1, 2021
fc4cdf9
fix: 修复部分数字转换错误
dataabc Oct 13, 2021
d1080ce
fix: 修复部分微博无法获取的问题
dataabc Nov 1, 2021
c106ffa
fix: uid=1,crash
9monster Dec 13, 2021
d2589dd
add: warning when stringtoint get a empty string
9monster Dec 13, 2021
6db1a2c
add: use logger replace print in function string_to_int
9monster Dec 13, 2021
1061de0
build(deps): bump lxml from 4.6.3 to 4.6.5
dependabot[bot] Dec 13, 2021
5e9a068
Merge pull request #401 from minami9/master
dataabc Dec 14, 2021
577dea5
Merge pull request #402 from dataabc/dependabot/pip/lxml-4.6.5
dataabc Dec 14, 2021
77977c2
Add a bibtex item for the weiboSpider repo.
songzy12 Mar 19, 2022
240cdef
Minor fixes of README based on review comments.
songzy12 Mar 19, 2022
b34286f
Merge pull request #426 from songzy12/bibtex
dataabc Mar 20, 2022
1f560db
fix: info maybe cause list index out of range
caixiangyue May 13, 2022
df64ccc
Merge pull request #441 from caixiangyue/master
dataabc May 13, 2022
cda3ae4
add mongo_config
KimiDing May 19, 2022
209fb75
Merge pull request #444 from KimiDing/master
dataabc May 19, 2022
b224338
修复:FAQ中获取自己微博描述
Jun 20, 2022
9679cd9
Merge pull request #455 from qianxin41/master
dataabc Jun 20, 2022
62a0029
build(deps): bump lxml from 4.6.5 to 4.9.1
dependabot[bot] Jul 6, 2022
473c80d
Merge pull request #458 from dataabc/dependabot/pip/lxml-4.9.1
dataabc Jul 7, 2022
95ab514
加入MongoDB设置的说明和例子
jerrylaikr Jul 29, 2022
999b66d
更新MongoDB设置对空字符串的识别
jerrylaikr Jul 29, 2022
1e879cf
update mongo_config
jerrylaikr Jul 29, 2022
3c8b5e5
Merge pull request #462 from jerrylaikr/fix-mongo-no-format
dataabc Jul 30, 2022
a51e4a8
correct user's profile url when fetching weibo
huaiwens Oct 16, 2022
e144dcb
Merge pull request #483 from huaiwens/profile_url
dataabc Oct 17, 2022
2a1400b
perf: update absl-py lock version
linbuxiao Nov 16, 2022
6b68775
Merge pull request #492 from linbuxiao/update-deps
dataabc Nov 16, 2022
6d4f5f9
Fix #484: run correctly when there are 2 pinned weibo.
songzy12 May 19, 2023
55ddb32
Fix: fix pytest by fixing the url map of testdata.
songzy12 May 19, 2023
5e1d06d
Merge pull request #525 from songzy12/master
dataabc May 19, 2023
3fc6440
build(deps): bump requests from 2.23.0 to 2.31.0
dependabot[bot] May 22, 2023
678154f
Merge pull request #526 from dataabc/dependabot/pip/requests-2.31.0
dataabc May 23, 2023
6ec6882
Update the stale action rule to not mark issues with assignees as stale.
songzy12 Jul 27, 2023
ae750bd
Merge pull request #530 from songzy12/master
dataabc Jul 27, 2023
829a891
Fix the crawling of toutiao article urls.
songzy12 Aug 27, 2023
22d8d03
Merge pull request #536 from songzy12/ttarticle
dataabc Aug 27, 2023
ac550e0
issues_bug_574 无法匹配获取微博长文,尝试修复
Apr 27, 2024
8c4eb7f
issues_bug_574 无法匹配获取微博长文,尝试修复
Apr 27, 2024
3098e61
Merge pull request #575 from myshero/issues_bug_574
dataabc Apr 27, 2024
2c7f723
issues_feature_post_api_576 实现通过POST方式将数据推送到自定义接口
Apr 28, 2024
c9cf218
issues_feature_post_api_576 实现通过POST方式将数据推送到自定义接口
Apr 28, 2024
8ce5f32
Merge pull request #577 from myshero/feature-post-to-custom-api
dataabc Apr 28, 2024
7159638
build(deps): bump tqdm from 4.46.1 to 4.66.3
dependabot[bot] May 3, 2024
4cbe86a
Merge pull request #580 from dataabc/dependabot/pip/tqdm-4.66.3
dataabc May 4, 2024
ae9224e
解决 'NoneType' object has no attribute 'xpath'
zangwill May 17, 2024
bf90933
Merge pull request #583 from zangwill/patch-1
dataabc May 17, 2024
496c09c
dependabot[bot] May 21, 2024
c1d43e8
Merge pull request #585 from dataabc/dependabot/pip/requests-2.32.0
dataabc May 21, 2024
8c49c81
fix: 改进被封禁账号爬取及添加代理支持
ydotdog Mar 24, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/bug-report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
name: Bug报修
about: 向程序开发者申报bug
title: ''
labels: bug
assignees: ''

---

感谢您申报bug,为了表示感谢,如果bug确实存在,您将出现在本项目的贡献者列表里;如果您不但发现了bug,还提供了很好的解决方案,我们会邀请您以pull request的方式成为本项目的代码贡献者(Contributor);如果您多次提供很好的pull request,我们将邀请您成为本项目的协助者(Collaborator)。当然,是否提供解决方按都是自愿的。不管是否是真正的bug、是否提供解决方案,我们都感谢您对本项目的帮助。

- 问:请您指明哪个版本出了bug(github版/PyPi版/全部)?

答:

- 问:您使用的是否是最新的程序(是/否)?

答:

- 问:爬取任意用户都会复现此bug吗(是/否)?

答:

- 问:若只有爬特定微博时才出bug,能否提供出错微博的weibo_id或url(非必填)?

答:

- 问:若您已提供出错微博的weibo_id或url,可忽略此内容,否则能否提供出错账号的**user_id**及您配置的**since_date**,方便我们定位出错微博(非必填)?

答:

- 问:如果方便,请您描述bug详情,如果代码报错,最好附上错误提示。

答:
34 changes: 34 additions & 0 deletions .github/ISSUE_TEMPLATE/failed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
---
name: 程序运行出错
about: 运行出错,需要帮助
title: ''
labels: failed
assignees: ''

---

为了更好的解决问题,请认真回答下面的问题。等到问题解决,请及时关闭本issue。

- 问:请您指明哪个版本运行出错(github版/PyPi版/全部)?

答:

- 问:您使用的是否是最新的程序(是/否)?

答:

- 问:爬取任意用户都会运行出错吗(是/否)?

答:

- 问:若只有爬特定微博时才出错,能否提供出错微博的weibo_id或url(非必填)?

答:

- 问:若您已提供出错微博的weibo_id或url,可忽略此内容,否则能否提供出错账号的**user_id**及您配置的**since_date**,方便我们定位出错微博(非必填)?

答:

- 问:如果方便,请您描述出错详情,最好附上错误提示。

答:
16 changes: 16 additions & 0 deletions .github/ISSUE_TEMPLATE/feature-request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
name: 新需求或建议
about: 建议开发新功能,或虽然没有新需求但对本项目有其它建议
title: ''
labels: 'feature'
assignees: ''

---

- 问:请说明需要什么新功能。

答:

- 问:请说明添加该功能的意义。(非必填)

答:
10 changes: 10 additions & 0 deletions .github/ISSUE_TEMPLATE/other.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: 其它问题
about: 其它想讨论的问题
title: ''
labels: ''
assignees: ''

---


30 changes: 30 additions & 0 deletions .github/stale.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Number of days of inactivity before an issue becomes stale
daysUntilStale: 60

# Number of days of inactivity before a stale issue is closed
daysUntilClose: 7

# Issues with these labels will never be considered stale
exemptLabels:
- pinned
- security
- to do

# Set to true to ignore issues with an assignee
exemptAssignees: true

# Label to use when marking an issue as stale
staleLabel: wontfix

# Comment to post when marking an issue as stale. Set to `false` to disable
markComment: >
This issue has been automatically marked as stale because it has not had
recent activity. It will be closed if no further activity occurs. Thank you
for your contributions.

# Comment to post when closing a stale issue. Set to `false` to disable
closeComment: >
Closing as stale, please reopen if you'd like to work on this further.

# Limit to only `issues` or `pulls`
only: issues
36 changes: 36 additions & 0 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions

name: Python application

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Set up Python 3.8
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Test with pytest
run: |
pytest
16 changes: 16 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
.vscode

*.pyc
__pycache__

build/
dist/
*.egg-info

config.json

weibo/
weibo.db
*.log

.idea
38 changes: 38 additions & 0 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
# 为本项目做贡献

本项目使用**Python3**编写,感谢大家对项目的支持,也欢迎大家为开源项目做贡献。鉴于大家拥有不同的技能、经验、认知、时间等,每个人可以根据自身的情况为本项目贡献力量。我们不会因为贡献者写的代码少或者提的建议不好而失去感恩之心,每一个乐于奉献的人都值得并且应该被尊重。所以,如果您觉得自己的代码或建议不好,而不好意思去贡献,这样可能就让本项目失去了一次变得更好的机会。所以,如果您有好的想法、建议,或者发现了bug,欢迎通过issue提出来,这也是一种贡献方式。如果您想要为本项目贡献代码,我们也非常欢迎。最开始您可以通过pull request方式提交代码,如果我们发现您的代码质量非常高,或者非常有想法等,我们会邀请您请成为本项目的协作者([Collaborator](https://help.github.com/cn/github/setting-up-and-managing-your-github-user-account/permission-levels-for-a-user-account-repository#collaborator-access-on-a-repository-owned-by-a-user-account)),这样您就可以直接向本项目提交代码了。在您贡献代码之前,请先阅读下面的说明,这会让您更好的贡献代码。

## 贡献代码之前

如果要开发新功能或者其它需要大量编写代码的修改,在开发之前最好发Issue说明一下。比如,“我准备开发xx新功能”或者“我想修改xx功能”之类的。因为要开发的功能不一定适合本项目,所以提前说明讨论,判断新功能或修改是否有必要。否则,费时费力写了很多代码,结果最后没有被采纳,可能会做一些无用功。

## Python风格规范(建议Python新手阅读)

参考[Python风格规范](https://zh-google-styleguide.readthedocs.io/en/latest/google-python-styleguide/python_style_rules/)
或者[Python风格规范](https://github.com/zh-google-styleguide/zh-google-styleguide/blob/master/google-python-styleguide/python_style_rules.rst),
二者内容是一样的。

## git提交规范

参考[Conventional Commits](https://www.conventionalcommits.org/en/v1.0.0/)
或者[Git提交规范](https://zhuanlan.zhihu.com/p/67804026),commit描述中文英文皆可,只要符合规范就好。

## git提交建议(可选)

本建议是可选的,如果你觉得不合理,可以按自己的方式编写代码。建议每次提交都是代码改动较少的提交,如果新功能需要大量修改代码,建议将新功能分成几个小模块,每个模块提交一次。原因是这样更容易管理代码。比如,一个新功能包含几个模块。其中大部分模块都写的很好,但是有一个模块有bug。分模块提交只需要单独处理出问题的模块,其他模块不受影响。

## Python之linter

本项目使用flake8。

## Python之formatter

本项目使用yapf。

## 引号的使用

代码中**建议使用单引号**,只有在特殊情况下使用双引号,如类、方法、函数等开头的注释使用6个双引号包裹(注释左边三个双引号,右边三个双引号),或者字符串中中已经包含单引号了,则要用双引号包裹。

## 避免过多的模块依赖

除非有必要,尽量少使用非内置的模块,因为会增加用户的安装成本,当然如果该模块能够为本项目或用户带来很多便利,则可以使用。
Loading