Closed VoidImagination closed 1 year ago
程序bug,已经定位,不过今天7点前应该来不及修了
main.py 第320行
if Good.stoken.find("v2__") == 0 and "mid" not in Good.cookie:
改成
if Good.stoken and Good.stoken.find("v2__") == 0 and "mid" not in Good.cookie:
如果你还能在七点前看到说不定能挣扎一下
开始挣扎辣
程序bug,已经定位,不过今天7点前应该来不及修了 main.py 第320行 改成 如果你还能在七点前看到说不定能挣扎一下
if Good.stoken.find("v2__") == 0 and "mid" not in Good.cookie:`` if Good.stoken and Good.stoken.find("v2__") == 0 and "mid" not in Good.cookie:
已经结束辣
程序bug,已经定位,不过今天7点前应该来不及修了 main.py 第320行 改成 如果你还能在七点前看到说不定能挣扎一下
if Good.stoken.find("v2__") == 0 and "mid" not in Good.cookie:
if Good.stoken and Good.stoken.find("v2__") == 0 and "mid" not in Good.cookie: ``已经结束辣
我也没抢到(
解决了那个之后,我是一直
检查游戏账户:********* 失败,正在重试(1)
怀疑还有bug,服了
刚看到😂看来要找时间代码重构了。 检查游戏账户失败可能要看一下日志文件里更多的详细信息。 v1.4.4我用短信验证码的方式获取的Cookies是可以正常用(未到时间返回库存不足)。可以先尝试v1.4.3。
刚看到😂看来要找时间代码重构了。 检查游戏账户失败可能要看一下日志文件里更多的详细信息。 v1.4.4我用短信验证码的方式获取的Cookies是可以正常用(未到时间返回库存不足)。可以先尝试v1.4.3。
这个我刚看了,是我cookie的问题
第230行 的循环,需要ltuid
, account_id
, stuid
三个值,但我的cookie中只有两个,导致返回的bbs_uid
是空值,formatcheck_game_url
之后,链接变成https://******uid=
导致错误
刚看到😂看来要找时间代码重构了。 检查游戏账户失败可能要看一下日志文件里更多的详细信息。 v1.4.4我用短信验证码的方式获取的Cookies是可以正常用(未到时间返回库存不足)。可以先尝试v1.4.3。
这个我刚看了,是我cookie的问题 第230行 的循环,需要
ltuid
,account_id
,stuid
三个值,但我的cookie中只有两个,导致返回的bbs_uid
是空值,formatcheck_game_url
之后,链接变成https://******uid=
导致错误
看来也是Bug,按设想应该是要求Cookies里包含这三项其中一项即可,也就是获取米游社UID,这三项值都是一样的。挺早之前就有出现这个uid为空的Bug,不过一直没修成功,今天才知道出错在哪。
上面这两处改完了应该没问题了。 打包的可执行文件:https://github.com/Ljzd-PRO/Mys_Goods_Tool/actions/runs/4492955290
上面这两处改完了应该没问题了。 打包的可执行文件:https://github.com/Ljzd-PRO/Mys_Goods_Tool/actions/runs/4492955290 好耶
Good.stoken
为 None
的根本原因是 main.py 第 223 行这里多了个 not
。
# 若 Cookie 中存在stoken,获取其中的stoken信息
elif "stoken" not in cookie: # 此处存在逻辑错误
stoken = cookie["stoken"]
以及第 229 行这里获取米游社 UID 的循环改为如下这样是否更为合适?
# 从 Cookie 中获取米游社 UID
bbs_uid = ""
for target in ("ltuid", "account_id", "stuid"):
if target in cookie:
bbs_uid = cookie[target]
break
Good.stoken
为None
的根本原因是 main.py 第 223 行这里多了个not
。# 若 Cookie 中存在stoken,获取其中的stoken信息 elif "stoken" not in cookie: # 此处存在逻辑错误 stoken = cookie["stoken"]
以及第 229 行这里获取米游社 UID 的循环改为如下这样是否更为合适?
# 从 Cookie 中获取米游社 UID bbs_uid = "" for target in ("ltuid", "account_id", "stuid"): if target in cookie: bbs_uid = cookie[target] break
确实是这样的
Good.stoken
为None
的根本原因是 main.py 第 223 行这里多了个not
。# 若 Cookie 中存在stoken,获取其中的stoken信息 elif "stoken" not in cookie: # 此处存在逻辑错误 stoken = cookie["stoken"]
以及第 229 行这里获取米游社 UID 的循环改为如下这样是否更为合适?
# 从 Cookie 中获取米游社 UID bbs_uid = "" for target in ("ltuid", "account_id", "stuid"): if target in cookie: bbs_uid = cookie[target] break
已修复。不过没记错的话目前实际使用应该是没有影响的,这里后面用到的stoken都是从cookie Dict里获取的
023-03-22 16:23:18 程序当前版本: v1.4.4
2023-03-22 16:23:18 INFO 正在校对互联网时间 2023-03-22 16:23:19 INFO 正在检查商品:2023022412390 的详细信息 2023-03-22 16:23:19 ERROR 检查商品:2023022412390 失败,正在重试 2023-03-22 16:23:19 ERROR Traceback (most recent call last): File "main.py", line 319, in init AttributeError: 'NoneType' object has no attribute 'find'
2023-03-22 16:23:19 INFO 正在检查商品:2023022412390 的详细信息 2023-03-22 16:23:19 ERROR 检查商品:2023022412390 失败,正在重试 2023-03-22 16:23:19 ERROR Traceback (most recent call last): File "main.py", line 319, in init AttributeError: 'NoneType' object has no attribute 'find'