Ljzd-PRO / Mys_Goods_Tool

米游社商品兑换工具 | 短信验证登录 | 终端图形界面
https://pypi.org/project/mys-goods-tool
MIT License
458 stars 70 forks source link

网络请求返回: {"data":null,"message":"","retcode":1028} #116

Closed ytgo closed 1 year ago

ytgo commented 1 year ago

这个是什么问题啊

Aellyt commented 1 year ago

我也是,原神分类的都这样了,米哈游可能改参数了

wsmbsbbz commented 1 year ago

我也是同样的问题和retcode,应该是和 #114 是一样的。

我开了5个线程:

日志输出:

06-07 19:00:00 [ERROR] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 3*******3 商品 2023051912299 请求失败
Traceback (most recent call last):

  File "threading.py", line 995, in _bootstrap

  File "threading.py", line 1038, in _bootstrap_inner

  File "threading.py", line 975, in run

  File "concurrent/futures/thread.py", line 83, in _worker

  File "concurrent/futures/thread.py", line 58, in run

  File "apscheduler/executors/base.py", line 125, in run_job

  File "mys_goods_tool/exchange_mode.py", line 101, in exchange_begin

> File "mys_goods_tool/api.py", line 1266, in good_exchange_sync

  File "httpx/_models.py", line 756, in json

  File "json/__init__.py", line 346, in loads

  File "json/decoder.py", line 337, in decode

  File "json/decoder.py", line 355, in raw_decode

json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
06-07 19:00:00 [ERROR] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 3*******3 商品 2023051912299 请求失败
Traceback (most recent call last):

  File "threading.py", line 995, in _bootstrap

  File "threading.py", line 1038, in _bootstrap_inner

  File "threading.py", line 975, in run

  File "concurrent/futures/thread.py", line 83, in _worker

  File "concurrent/futures/thread.py", line 58, in run

  File "apscheduler/executors/base.py", line 125, in run_job

  File "mys_goods_tool/exchange_mode.py", line 101, in exchange_begin

> File "mys_goods_tool/api.py", line 1266, in good_exchange_sync

  File "httpx/_models.py", line 756, in json

  File "json/__init__.py", line 346, in loads

  File "json/decoder.py", line 337, in decode

  File "json/decoder.py", line 355, in raw_decode

json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
06-07 19:00:00 [ERROR] mys_goods_tool.exchange_mode | 接收兑换结果失败
Traceback (most recent call last):

  File "threading.py", line 995, in _bootstrap

  File "threading.py", line 1038, in _bootstrap_inner

  File "threading.py", line 975, in run

  File "concurrent/futures/thread.py", line 83, in _worker

  File "concurrent/futures/thread.py", line 64, in run

  File "concurrent/futures/_base.py", line 550, in set_result

  File "concurrent/futures/_base.py", line 340, in _invoke_callbacks

  File "apscheduler/executors/pool.py", line 25, in callback

  File "apscheduler/executors/base.py", line 90, in _run_job_success

  File "apscheduler/schedulers/base.py", line 835, in _dispatch_event

> File "mys_goods_tool/exchange_mode.py", line 304, in on_executed

StopIteration
06-07 19:00:00 [ERROR] mys_goods_tool.exchange_mode | 接收兑换结果失败
Traceback (most recent call last):

  File "threading.py", line 995, in _bootstrap

  File "threading.py", line 1038, in _bootstrap_inner

  File "threading.py", line 975, in run

  File "concurrent/futures/thread.py", line 83, in _worker

  File "concurrent/futures/thread.py", line 64, in run

  File "concurrent/futures/_base.py", line 550, in set_result

  File "concurrent/futures/_base.py", line 340, in _invoke_callbacks

  File "apscheduler/executors/pool.py", line 25, in callback

  File "apscheduler/executors/base.py", line 90, in _run_job_success

  File "apscheduler/schedulers/base.py", line 835, in _dispatch_event

> File "mys_goods_tool/exchange_mode.py", line 304, in on_executed

StopIteration
06-07 19:00:00 [INFO] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 3*******3 商品 2023051912299 兑换失败,可以自行确认。
06-07 19:00:00 [DEBUG] mys_goods_tool.api | 网络请求返回: {"data":null,"message":"","retcode":1028}
06-07 19:00:00 [ERROR] mys_goods_tool.exchange_mode | 用户 3*******3 - 【原神】原石*150 - 线程 2 - 兑换失败
06-07 19:00:00 [ERROR] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 3*******3 商品 2023051912299 请求失败
Traceback (most recent call last):

  File "threading.py", line 995, in _bootstrap

  File "threading.py", line 1038, in _bootstrap_inner

  File "threading.py", line 975, in run

  File "concurrent/futures/thread.py", line 83, in _worker

  File "concurrent/futures/thread.py", line 58, in run

  File "apscheduler/executors/base.py", line 125, in run_job

  File "mys_goods_tool/exchange_mode.py", line 101, in exchange_begin

> File "mys_goods_tool/api.py", line 1266, in good_exchange_sync

  File "httpx/_models.py", line 756, in json

  File "json/__init__.py", line 346, in loads

  File "json/decoder.py", line 337, in decode

  File "json/decoder.py", line 355, in raw_decode

json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
06-07 19:00:00 [ERROR] mys_goods_tool.exchange_mode | 接收兑换结果失败
Traceback (most recent call last):

  File "threading.py", line 995, in _bootstrap

  File "threading.py", line 1038, in _bootstrap_inner

  File "threading.py", line 975, in run

  File "concurrent/futures/thread.py", line 83, in _worker

  File "concurrent/futures/thread.py", line 64, in run

  File "concurrent/futures/_base.py", line 550, in set_result

  File "concurrent/futures/_base.py", line 340, in _invoke_callbacks

  File "apscheduler/executors/pool.py", line 25, in callback

  File "apscheduler/executors/base.py", line 90, in _run_job_success

  File "apscheduler/schedulers/base.py", line 835, in _dispatch_event

> File "mys_goods_tool/exchange_mode.py", line 304, in on_executed

StopIteration
06-07 19:00:00 [INFO] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 3*******3 商品 2023051912299 兑换失败,可以自行确认。
06-07 19:00:00 [DEBUG] mys_goods_tool.api | 网络请求返回: {"data":null,"message":"","retcode":1028}
06-07 19:00:00 [ERROR] mys_goods_tool.exchange_mode | 用户 3*******3 - 【原神】原石*150 - 线程 4 - 兑换失败

环境如下:

"preference": {
    "github_proxy": "https://ghproxy.com/",
    "enable_connection_test": true,
    "connection_test_interval": 30.0,
    "timeout": 10.0,
    "max_retry_times": 5,
    "retry_interval": 2.0,
    "enable_ntp_sync": true,
    "ntp_server": "ntp.aliyun.com",
    "timezone": "Asia/Shanghai",
    "geetest_statics_path": null,
    "geetest_listen_address": [
        "localhost",
        0
    ],
    "exchange_thread_count": 5,
    "exchange_latency": [
        0.0,
        0.02
    ],
    "enable_log_output": true,
    "log_path": "logs/mys_goods_tool.log"
},
Yoimiya-993 commented 1 year ago

一样的返回结果,自从用了图形化版本就没换成功过

Ljzd-PRO commented 1 year ago

https://github.com/Ljzd-PRO/nonebot-plugin-mystool/issues/110

也是一样

Ljzd-PRO commented 1 year ago

等下次兑换我手动抓包检查一下

TianXiaSky commented 1 year ago

还真是原神兑换才有问题,我连续两个星期抢原神的东西都是 网络请求返回: {"data":null,"message":"","retcode":1028} 这个代码,抢不到,今天换成崩铁的商品一下就成功了

pbxs666 commented 1 year ago

还真是原神兑换才有问题,我连续两个星期抢原神的东西都是 网络请求返回: {"data":null,"message":"","retcode":1028} 这个代码,抢不到,今天换成崩铁的商品一下就成功了

今天试崩铁的东西,也失败了😣 06-16 18:00:00 [INFO] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 136508784 商品 2023052611696 兑换失败,可以自行确认。 06-16 18:00:00 [DEBUG] mys_goods_tool.api | 网络请求返回: {"data":null,"message":"","retcode":1028} 06-16 18:00:00 [ERROR] mys_goods_tool.exchange_mode | 用户 136508784 - 【崩坏:星穹铁道】鼠标垫-星旅一瞬 - 线程 1 - 兑换失败 06-16 18:00:00 [INFO] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 136508784 商品 2023052611696 兑换失败,可以自行确认。 06-16 18:00:00 [DEBUG] mys_goods_tool.api | 网络请求返回: {"data":null,"message":"","retcode":1028} 06-16 18:00:00 [ERROR] mys_goods_tool.exchange_mode | 用户 136508784 - 【崩坏:星穹铁道】鼠标垫-星旅一瞬 - 线程 2 - 兑换失败 06-16 18:00:00 [INFO] mys_goods_tool.api | 米游币商品兑换 - 执行兑换: 用户 136508784 商品 2023052611696 兑换失败,可以自行确认。 06-16 18:00:00 [DEBUG] mys_goods_tool.api | 网络请求返回: {"data":null,"message":"","retcode":1028} 06-16 18:00:00 [ERROR] mys_goods_tool.exchange_mode | 用户 136508784 - 【崩坏:星穹铁道】鼠标垫-星旅一瞬 - 线程 3 - 兑换失败

fanlu commented 1 year ago

用了最新的代码,抢原神的依然是返回1028

2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:00  INFO  商品 2023051912299 兑换失败,可以自行确认。
2023-06-21 19:00:00  INFO  商品 2023051912299 兑换失败,可以自行确认。
2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:01  INFO  商品 2023051912299 兑换失败,可以自行确认。
Ljzd-PRO commented 1 year ago

用了最新的代码,抢原神的依然是返回1028

2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:00  INFO  商品 2023051912299 兑换失败,可以自行确认。
2023-06-21 19:00:00  INFO  商品 2023051912299 兑换失败,可以自行确认。
2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:01  INFO  商品 2023051912299 兑换失败,可以自行确认。

是release的v2.0.4还是这两天改后的

fanlu commented 1 year ago

用了最新的代码,抢原神的依然是返回1028

2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  开始发送商品 2023051912299 的兑换请求...
2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:00  INFO  商品 2023051912299 兑换失败,可以自行确认。
2023-06-21 19:00:00  INFO  商品 2023051912299 兑换失败,可以自行确认。
2023-06-21 19:00:00  INFO  兑换商品:2023051912299 返回结果:
{"data":null,"message":"","retcode":1028}

2023-06-21 19:00:01  INFO  商品 2023051912299 兑换失败,可以自行确认。

是release的v2.0.4还是这两天改后的

用的1.4.5加上了这两天改的代码

Ljzd-PRO commented 1 year ago

又尝试修复了一下,可以试一下:https://github.com/Ljzd-PRO/Mys_Goods_Tool/actions/runs/5479310149

解决了几个可能的问题:

除了Headers里没有x-rpc-verify_key, x-rpc-device_fp,其他应该都和米游社App里实际发出的请求一致了。