zas023 / jdbuyer Goto Github PK
View Code? Open in Web Editor NEW京东抢购自动下单助手,GUI 支持 Windows 和 macOS
京东抢购自动下单助手,GUI 支持 Windows 和 macOS
raise JDException('二维码信息校验失败')
exception.JDException: 二维码信息校验失败
很多商品到了才放货,时间到了开始抢购,不然一来容易封ip,二来抢不到。
输入某个商品的sku后,执行JdBuyer.py文件,只是把商品放入购物车,不能自动提交订单?另外如何设置微信提醒呢?
最近在抢iphone14,设置好定时抢购开始执行脚本,一直显示未满足抢购条件,到达抢购时间也是一样
PS D:\workplace\JdBuyer-main> python JdBuyer.py
2022-10-30 18:14:12,605 INFO: 登录成功
Traceback (most recent call last):
File "D:\javaDev\PythonDev\lib\site-packages\requests\models.py", line 972, in json
return complexjson.loads(self.text, **kwargs)
File "D:\javaDev\PythonDev\lib\json_init_.py", line 357, in loads
return _default_decoder.decode(s)
File "D:\javaDev\PythonDev\lib\json\decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "D:\javaDev\PythonDev\lib\json\decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "JdBuyer.py", line 115, in
buyer.buyItemInStock(skuId, areaId, skuNum, stockInterval,
File "JdBuyer.py", line 75, in buyItemInStock
self.session.fetchItemDetail(skuId)
File "D:\workplace\JdBuyer-main\JdSession.py", line 169, in fetchItemDetail
resp = self.getItemDetail(skuId).json()
File "D:\javaDev\PythonDev\lib\site-packages\requests\models.py", line 976, in json
raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
首先,伸手党非常感谢作者开源这个项目,也是一样准备抢台富士相机
关于登录状态的问题,以前玩过京东 web 端相关的API,很长时间,京东 web 的 session 可以维持很久,可以用于领取一些奖励或者保价。后来京东那边做了技术调整,京东 web 的 session 基本 24 小时不到就会失效,需要频繁登录的监听程序直接废了
我这边有一个想法,碍于对 Python 不熟悉,无法发起 PR,能否在 testSession false 的时候,重新获取登录二维码,并且通过某些推送渠道,将二维码图片通知给监听的人,然后实现手工再登录,完成变相的保活。
以上。
刚开始没问题,运行几次后报这个错。代码我也没动呀~~~
能用这个抢COVID-19抗原吗?
网页开发工具那里没有地区ID了,找不到,谢谢
F:\jd\JdBuyer-main>python JdBuyer.py
2022-12-15 22:35:39,021 INFO: 登录成功
Traceback (most recent call last):
File "F:\jd\JdBuyer-main\JdBuyer.py", line 115, in
buyer.buyItemInStock(skuId, areaId, skuNum, stockInterval,
File "F:\jd\JdBuyer-main\JdBuyer.py", line 75, in buyItemInStock
self.session.fetchItemDetail(skuId)
File "F:\jd\JdBuyer-main\JdSession.py", line 169, in fetchItemDetail
resp = self.getItemDetail(skuId).json()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\YanYonghang\AppData\Local\Programs\Python\Python311\Lib\site-packages\requests\models.py", line 898, in json
return complexjson.loads(self.text, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\YanYonghang\AppData\Local\Programs\Python\Python311\Lib\json_init_.py", line 346, in loads
return _default_decoder.decode(s)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\YanYonghang\AppData\Local\Programs\Python\Python311\Lib\json\decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\YanYonghang\AppData\Local\Programs\Python\Python311\Lib\json\decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
^^^^^^^^^^^^^^^^^^^^^^
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
目前有一些产品需要使用系统带的优惠卷,会便宜很多钱。
目前不会自动使用优惠卷,只是使用商品默认价格进行抢购。
地址一直显示的北京朝阳
2022-12-16 14:21:23,154 INFO: 100043960941 满足下单条件,开始执行
2022-12-16 14:21:23,202 ERROR: 购物车取消勾选失败
如题
扫码后仍显示“请使用京东扫码登录”,而不是库存刷新时间及结果
具体错误内容如下
Traceback (most recent call last):
File "D:\Python\lib\site-packages\urllib3\connectionpool.py", line 696, in urlopen
self._prepare_proxy(conn)
File "D:\Python\lib\site-packages\urllib3\connectionpool.py", line 964, in _prepare_proxy
conn.connect()
File "D:\Python\lib\site-packages\urllib3\connection.py", line 359, in connect
conn = self._connect_tls_proxy(hostname, conn)
File "D:\Python\lib\site-packages\urllib3\connection.py", line 496, in _connect_tls_proxy
return ssl_wrap_socket(
File "D:\Python\lib\site-packages\urllib3\util\ssl_.py", line 432, in ssl_wrap_socket
ssl_sock = _ssl_wrap_socket_impl(sock, context, tls_in_tls)
File "D:\Python\lib\site-packages\urllib3\util\ssl_.py", line 474, in _ssl_wrap_socket_impl
return ssl_context.wrap_socket(sock)
File "D:\Python\lib\ssl.py", line 500, in wrap_socket
return self.sslsocket_class._create(
File "D:\Python\lib\ssl.py", line 1040, in _create
self.do_handshake()
File "D:\Python\lib\ssl.py", line 1309, in do_handshake
self._sslobj.do_handshake()
ssl.SSLEOFError: EOF occurred in violation of protocol (_ssl.c:1123)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\Python\lib\site-packages\requests\adapters.py", line 489, in send
resp = conn.urlopen(
File "D:\Python\lib\site-packages\urllib3\connectionpool.py", line 755, in urlopen
retries = retries.increment(
File "D:\Python\lib\site-packages\urllib3\util\retry.py", line 573, in increment
raise MaxRetryError(_pool, url, error or ResponseError(cause))
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='qr.m.jd.com', port=443): Max retries exceeded with url: /show?appid=133&size=147&t=1671777008328 (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1123)')))
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "D:\下载\JdBuyer-main\JdBuyer.py", line 114, in <module>
buyer.loginByQrCode()
File "D:\下载\JdBuyer-main\JdBuyer.py", line 36, in loginByQrCode
qrCode = self.session.getQRcode()
File "D:\下载\JdBuyer-main\JdSession.py", line 100, in getQRcode
resp = self.sess.get(url=url, headers=headers, params=payload)
File "D:\Python\lib\site-packages\requests\sessions.py", line 600, in get
return self.request("GET", url, **kwargs)
File "D:\Python\lib\site-packages\requests\sessions.py", line 587, in request
resp = self.send(prep, **send_kwargs)
File "D:\Python\lib\site-packages\requests\sessions.py", line 701, in send
r = adapter.send(request, **kwargs)
File "D:\Python\lib\site-packages\requests\adapters.py", line 563, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='qr.m.jd.com', port=443): Max retries exceeded with url: /show?appid=133&size=147&t=1671777008328 (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:1123)')))
如题
ERROR: [Errno Expecting property name enclosed in double quotes] {'code':200,'limit':1}: 1
想抢购iPhone,但是不能选择规格颜色库存
对京东扫描登录分析了一下,正常登录后validateQRcodeTicket
返回的returnCode是0,但是我登录返回的returnCode是80,有没有人知道这个代表什么意思
ERROR: ('查询 %s 库存信息发生异常, resp: %s, exception: %s', '10033592167263', 'jQuery6485269({})', AttributeError("'NoneType' object has no attribute 'get'"))
谢谢大佬,最近华硕京东自营耍猴,想买个Z790主板,却买不到。哭了。
Linux上怎么运行呢?
如题
GUI无法显示登录界面
主要优化了扫码那个配置,默认的我二维码我扫了总登录不上,我改了一下格式从png改成了jpg,然后加了白色边框,就可以扫码了。
定时器那个用的第三方包,写的那个while循环定时器感觉不太好用。
然后加入了停止时间配置。
目前只有命令行版,没有弄界面,有需要的,可以说一声,等我有空了再弄。
https://github.com/Tlntin/JdBuyer
今天好像更新了,是不是要丢应修改什么东西
Traceback (most recent call last):
File "C:\Program Files\Python39\lib\site-packages\requests\models.py", line 972, in json
return complexjson.loads(self.text, **kwargs)
File "C:\Program Files\Python39\lib\json_init_.py", line 346, in loads
return _default_decoder.decode(s)
File "C:\Program Files\Python39\lib\json\decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Program Files\Python39\lib\json\decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "E:\Learn\JDBuyBuy\JdBuyer_KangYuan_JiuAn\JdBuyer.py", line 115, in
buyer.buyItemInStock(skuId, areaId, skuNum, stockInterval,
File "E:\Learn\JDBuyBuy\JdBuyer_KangYuan_JiuAn\JdBuyer.py", line 75, in buyItemInStock
self.session.fetchItemDetail(skuId)
File "E:\Learn\JDBuyBuy\JdBuyer_KangYuan_JiuAn\JdSession.py", line 169, in fetchItemDetail
resp = self.getItemDetail(skuId).json()
File "C:\Program Files\Python39\lib\site-packages\requests\models.py", line 976, in json
raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
使用的shell脚本时,由于服务器没有图形界面,无法完成扫码登录功能
购物车返回的信息里没有 skuid 了。不能正确获取到购物车状态
2022-12-15 09:03:16,482 INFO: 登录成功
Traceback (most recent call last):
File "C:\Users~\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\models.py", line 971, in json
return complexjson.loads(self.text, **kwargs)
File "C:\Users~\AppData\Local\Programs\Python\Python310\lib\json_init_.py", line 346, in loads
return _default_decoder.decode(s)
File "C:\Users~\AppData\Local\Programs\Python\Python310\lib\json\decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Users~\AppData\Local\Programs\Python\Python310\lib\json\decoder.py", line 353, in raw_decode
obj, end = self.scan_once(s, idx)
json.decoder.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\temp\JdBuyer-main\JdBuyer.py", line 115, in
buyer.buyItemInStock(skuId, areaId, skuNum, stockInterval,
File "C:\temp\JdBuyer-main\JdBuyer.py", line 76, in buyItemInStock
self.session.fetchItemDetail(skuId)
File "C:\temp\JdBuyer-main\JdSession.py", line 169, in fetchItemDetail
resp = self.getItemDetail(skuId).json()
File "C:\Users~\AppData\Local\Programs\Python\Python310\lib\site-packages\requests\models.py", line 975, in json
raise RequestsJSONDecodeError(e.msg, e.doc, e.pos)
requests.exceptions.JSONDecodeError: Expecting property name enclosed in double quotes: line 1 column 2 (char 1)
尝试打印getItemDetail方法中调用京东接口的返回值,发现是{'code': 200,'limit': 1}
库存设置 1 每次开始都会自动 +1 库存
清空购物车显示成功实际上并没有清空,会导致如果这次提交订单没有成功的话,下次再检测到有货的话,下次再加一次购物车就是两件商品一起下单了,麻烦您看一下
同时抢多个商品,请问是否支持
使用小程序扫码不能进行登陆
requests.exceptions.ProxyError: HTTPSConnectionPool(host='qr.m.jd.com', port=443): Max retries exceeded with url: /show?appid=133&size=147&t=1672369101367 (Caused by ProxyError('Cannot conn
ect to proxy.', OSError(0, 'Error')))
说是请求次数频繁?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.