fix(zhihu): 修复 Cookie 设置时机问题

- 将 context 创建移到 cookie 设置之前
- 使用 add_cookies 方法替代初始化时传入
- 添加 .gitignore 忽略 __pycache__ 等文件
This commit is contained in:
2026-03-08 23:25:14 +08:00
parent 727cfc183a
commit 070cd80342
2 changed files with 27 additions and 5 deletions
+21
View File
@@ -0,0 +1,21 @@
# Python
__pycache__/
*.py[cod]
*$py.class
*.so
.Python
*.egg-info/
.eggs/
dist/
build/
# IDE
.idea/
.vscode/
*.swp
*.swo
# Misc
.DS_Store
*.log
.env