def getQrcode(uuid):
print('Please scan the QR code.')
url = 'https://login.weixin.qq.com/qrcode/' + uuid
req = request.Request(url)
res = request.urlopen(req)
f = open(QRImagePath, 'wb')
f.write(res.read())
f.close()
time.sleep(1)
if sys.platform.find('darwin') >= 0:
subprocess.call(['open', QRImagePath])
elif sys.platform.find('linux') >= 0:
subprocess.call(['xdg-open', QRImagePath])
else:
os.startfile(QRImagePath)
评论列表
文章目录