Giter VIP home page Giter VIP logo

bilibili_show_ticket_auto_order's Introduction

Bilibili_show_ticket_auto_order

截止到2023/8/9仍然可用

屏幕截图 2023-08-09 182035 屏幕截图 2023-08-09 182012

原介绍

本项目核心借鉴自https://github.com/Hobr

Bilibili会员购抢票助手, 通过B站接口抢购目标漫展/演出

本脚本仅供学习交流使用, 不得用于商业用途, 如有侵权请联系删除

image-20230708221711220

image-20230708221143842

致谢

以下排名不分先后,我也不想搞的攀比起来,因为很多都是学生,原则上我是不收赞助的,大家太热情了:

------------------------------------------------++++

晚安乃琳Queen
kankele
倔强
宵宫
yxw
星海云梦
穆桉
mizore
傩祓
CChhdCC
w2768
iiiiimilet
利维坦战斧
路人
Impact
骤雨初歇
明月夜
晓读
Simpson
Goognaloli
闹钟
LhiaS
洛天华
猪猪侠
awasl
房Z
浙江大学第一深情
superset245
ChinoHao
神秘的miku
Red_uncle
czpwpq

------------------------------------------------++++

功能截图

除了登录纯api请求

目前已经支持漫展演出等的 无证 / 单证 / 一人一证 的购买

image-20230708014050624

image-20230708014124395

使用

相关内容感谢@123485k的提交

执行exe

登录和抢票分开的,先运行登录.exe,登陆后再运行抢票.exe,运行了之后不要急着选,先把验证.exe启动起来

不需要依赖

如果运行失败的请安装依赖Edgewebdriver

执行脚本

python login.py
python main.py
python geetest.py

该装的东西自己装

新功能:微信公众号推送结果

需要关注pushplus微信公众号,关注后激活,然后点击个人中心-获取token,在config.txt中填入token即可在需要验证或者抢票成功后收到微信公众号通知

配置说明

config.txt为配置文件,不指定值为None

  • proxies 指定代理 如:127.0.0.1:8080 (IP:PORT 请不要加前缀)
  • specificID 多个用户登陆后指定某一个人uid(bilibili) (多用户还没做等后面有必要再写)
  • sleep设置每次抢票请求间隔时间
  • token设置pushplus的个人token

API文档

pass

问题报告

提issue即可

更新

加入token验证,手动拉滑块

加入微信公众号推送消息功能

bilibili_show_ticket_auto_order's People

Contributors

fengx1a0 avatar soranorinji avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

bilibili_show_ticket_auto_order's Issues

下单时"验证已过期"

B站对于过于频繁的请求可能会要求手动拉一次验证条, 例如这里的情况

验证链接是准备订单api的返回值里的[data][shield][naUrl]

过验证可能还得靠使用者自己了

geetest改进思路

其实可以每隔一段时间检测url文件是否存在,且验证成功后可以删除url文件以防多次弹验证(实际并没有弹),直接使用pause感觉有点草率了,真正需要验证的时候也在pause。

def mult_work(self):
    self.init_browser()
    self.load_cookies()
    while True:
        sleep(1)
        if not os.path.exists("url"):
            print("等待中")
            continue
        a = open("url", "r")
        u = a.read()
        a.close()
        if u and u.strip() != self.u:
            self.u = u
            # win32api.MessageBox(0,'需要滑块验证!','通知',win32con.MB_OK)
            self.WebDriver.get(u)
            os.remove("url")
            self.WebDriver.quit()
        # print("等待中")

412愈发频繁了

谢谢作者的持续更新,但是因为叔叔的出手,1.7安全间隔也不再安全了,有没有什么相对更加安全有效的设置方式,如果长期被BAN有解决办法吗

多项目抢票问题

佬,我想请教一下,我有两个账号,然后我创建两个项目,分别存储账号信息,一个执行exe抢票,一个执行.py抢票,同时抢票可行吗?或者说我只需要执行各自的exe。

滑块验证程序闪退

点击滑块验证.exe后,弹出ie浏览器,然后弹窗 需要滑块验证,请问这是正常现象吗

exe在哪里?

这源代码里没有exe?报错
Message: 'msedgedriver' executable needs to be in PATH. Please download from https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/
FileNotFoundError: [WinError 2] 系统找不到指定的文件。

During handling of the above exception, another exception occurred:

File "O:\Code\bilibili\Bilibili_show_ticket_auto_order-main\login.py", line 28, in get_login
WebDriver = webdriver.Edge(options=options)
File "O:\Code\bilibili\Bilibili_show_ticket_auto_order-main\login.py", line 50, in
get_login()
selenium.common.exceptions.WebDriverException: Message: 'msedgedriver' executable needs to be in PATH. Please download from https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/

这个,下了啥driver也没用,有小白用step by step教程吗?

help

作者你好,为什么总是显示抢到了但订单内没有啊555

新问题

脚本中显示已经抢到票之后在会员购中没有找到未付款的订单

关于显示已成功抢到票,但是订单界面没有的问题

Cache_-2ee26892121b100f
Cache_-6154e5f1036ed6ea

在使用这个脚本之后,已经连续几次出现了脚本显示“已成功抢到票”,但是第一时间去待付款界面查看却没有任何订单的情况,至今还没有成功的抢到票。我看另一个提问者也提出过相同的问题,请问是脚本出现bug了嘛?

滑块验证

DevTools listening on ws://
请在脚本目录打开此程序
请按任意键继续

抢到了感谢大佬!!

但是过程中有几次,终端里显示抢到票了但是第一时间进去发现没有订单,不知道是因为网的问题还是因为什么

总之感谢大佬的源码改进!

错误退出原因看这里

错误号:412
由于触发哔哩哔哩安全风控策略,该次访问请求被拒绝。
The request was rejected because of the bilibili security control policy.
image

假票检测出现检测失误

假票检测功能目前是检测订单第一条的 status 字段是否为 1 ,是则鉴定为真票,

但如果使用者的第一条订单信息为会员购中未补尾款的手办等商品,其 status 字段也为 1,而票没有真正抢到时,程序会误报为真票从而自动停止

目前没试出来其他会触发这个BUG的订单信息

感谢作者

感谢大佬,我们这边陆陆续续抢了十几个人共20多张普票和3张vip票,止住了不少人去购买黄牛的意图,剩下了不少钱财。非常感谢,大家想尽一份心意赞助一下。可能不是很多,但也希望作者能给个赞助渠道,将来大大小小睿站的活动说不准还得依靠大佬,多谢。

请问如何抢多张票票

一次抢票流程是登录,运行,滑块。那么可以多个运行窗口抢不同日期类型的票吗?还是说得登录,运行,滑块三步全部重新来。

最新release登录失败

之前登录过一次,下载了v1.6.1之后,此前的user_data.json被覆盖,重新登录,出现以下错误

Traceback (most recent call last):
File "C:\debug\bilibili-show-ticket-auto-order\login.py", line 50, in
get_login()
File "C:\debug\bilibili-show-ticket-auto-order\login.py", line 39, in get_login
username = WebDriver.find_element(By.CLASS_NAME, "home-top-msg-name").text
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Python311\Lib\site-packages\selenium\webdriver\remote\webdriver.py", line 740, in find_element
return self.execute(Command.FIND_ELEMENT, {"using": by, "value": value})["value"]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Python311\Lib\site-packages\selenium\webdriver\remote\webdriver.py", line 346, in execute
self.error_handler.check_response(response)
File "C:\Python311\Lib\site-packages\selenium\webdriver\remote\errorhandler.py", line 245, in check_response
raise exception_class(message, screen, stacktrace)
selenium.common.exceptions.NoSuchElementException: Message: no such element: Unable to locate element: {"method":"css selector","selector":".home-top-msg-name"}
(Session info: MicrosoftEdge=114.0.1823.79); For documentation on this error, please visit: https://www.selenium.dev/documentation/webdriver/troubleshooting/errors#no-such-element-exception
Stacktrace:
Backtrace:
GetHandleVerifier [0x00007FF63D98AEC2+64226]
Microsoft::Applications::Events::EventProperty::~EventProperty [0x00007FF63D91C082+765362]
(No symbol) [0x00007FF63D6DCC4C]
(No symbol) [0x00007FF63D720BDF]
(No symbol) [0x00007FF63D720D6A]
(No symbol) [0x00007FF63D75AC17]
(No symbol) [0x00007FF63D73F03F]
(No symbol) [0x00007FF63D714BB1]
(No symbol) [0x00007FF63D757FC1]
(No symbol) [0x00007FF63D73EDD3]
(No symbol) [0x00007FF63D713BEC]
(No symbol) [0x00007FF63D712DD6]
(No symbol) [0x00007FF63D714364]
Microsoft::Applications::Events::ILogManager::DispatchEventBroadcast [0x00007FF63DB687C9+1319033]
(No symbol) [0x00007FF63D78D2A8]
Microsoft::Applications::Events::EventProperty::~EventProperty [0x00007FF63D8695E1+33553]
Microsoft::Applications::Events::EventProperty::~EventProperty [0x00007FF63D861A1F+1871]
Microsoft::Applications::Events::ILogManager::DispatchEventBroadcast [0x00007FF63DB673E3+1313939]
Microsoft::Applications::Events::ILogConfiguration::operator* [0x00007FF63D9246B8+20232]
Microsoft::Applications::Events::ILogConfiguration::operator* [0x00007FF63D920CD4+5412]
Microsoft::Applications::Events::ILogConfiguration::operator* [0x00007FF63D920DCC+5660]
Microsoft::Applications::Events::EventProperty::~EventProperty [0x00007FF63D914A81+735153]
BaseThreadInitThunk [0x00007FFDBF0826AD+29]
RtlUserThreadStart [0x00007FFDC0AEAA68+40]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.