enwaiax / smzdm_bot

什么值得买自动签到 2023
Apache License 2.0
290 stars 229 forks source link

青龙面板运行脚本报错 #59

Open Theoshen opened 11 months ago

Theoshen commented 11 months ago

什么值得买签到

开始执行... 2023-12-04 17:58:12

WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv

[notice] A new release of pip is available: 23.0.1 -> 23.3.1 [notice] To update, run: pip install --upgrade pip 2023-12-04 17:58:18.820 | INFO | main:load_conf:25 - Get configration from env Traceback (most recent call last): File "/ql/data/repo/Chasing66_smzdm_bot/app/main.py", line 81, in main() File "/ql/data/repo/Chasing66_smzdm_bot/app/main.py", line 69, in main msg += tasks.checkin() File "/ql/data/repo/Chasing66_smzdm_bot/app/utils/smzdm_tasks.py", line 15, in checkin resp = self.bot.request("POST", url) File "/ql/data/repo/Chasing66_smzdm_bot/app/utils/smzdm_bot.py", line 92, in request data = self.data(extra_data) File "/ql/data/repo/Chasing66_smzdm_bot/app/utils/smzdm_bot.py", line 79, in data "f": self.cookies_dict["device_smzdm"], KeyError: 'device_smzdm'

执行结束... 2023-12-04 17:58:23 耗时 11 秒   

只设置了ANDROID_COOKIE这个环境变量,从web 端F12拿的 Cookie

neverno commented 11 months ago

我也是这个错误,希望 @Chasing66 修复下!

IanSmith123 commented 10 months ago

当前的 main 分支的代码需要的是通过安卓端抓取的 cookie。浏览器端抓 cookie 的代码在 old分支,不一定还能使用。

FYI: Android 抓包的这部分结果如下,你可以尝试把他追加到浏览器端抓的 cookie 里面,万一可以用呢(虽然我感觉希望不太大) :)

device_smzdm=android;device_smzdm_version=10.6.10;device_smzdm_version_code=930;
Theoshen commented 10 months ago

@IanSmith123 确实用不了

[notice] A new release of pip is available: 23.0.1 -> 23.3.1
[notice] To update, run: pip install --upgrade pip
2023-12-12 16:31:50.861 | INFO     | __main__:load_conf:25 - Get configration from env
Traceback (most recent call last):
  File "/ql/data/repo/Chasing66_smzdm_bot/app/main.py", line 81, in <module>
    main()
  File "/ql/data/repo/Chasing66_smzdm_bot/app/main.py", line 69, in main
    msg += tasks.checkin()
  File "/ql/data/repo/Chasing66_smzdm_bot/app/utils/smzdm_tasks.py", line 15, in checkin
    resp = self.bot.request("POST", url)
  File "/ql/data/repo/Chasing66_smzdm_bot/app/utils/smzdm_bot.py", line 92, in request
    data = self.data(extra_data)
  File "/ql/data/repo/Chasing66_smzdm_bot/app/utils/smzdm_bot.py", line 83, in data
    "token": self.cookies_dict["sess"],
KeyError: 'sess'

## 执行结束... 2023-12-12 16:31:57  耗时 8 秒  
enwaiax commented 10 months ago

统一回复一下:暂时没时间修复,有空了会尽快修复