二次扫描带参数二维码提示“无法服务”什么原因?已关注,二次参数,已关注粉丝再次扫描微信带
二次扫描带参数二维码提示“无法服务”什么原因?已关注,二次参数,已关注粉丝再次扫描微信带
已关注粉丝再次扫描微信带参数二维码报错。
未关注粉丝扫描二维码时,正常。
第二次扫描时,提示“无法服务”
查后台nginx日志 两种场景均返回的为空,CODE 为200
@app.route("/",methods=["POST","GET","PUT"])def index(): if(request.method=="GET"): #验证微信 signature=request.args.get('signature', None) timestamp=request.args.get('timestamp',None) nonce=request.args.get('nonce',None) echostr=request.args.get('echostr',"hello") # logging.info(echostr) return echostr if(request.method=="POST"): soup=BeautifulSoup(request.data,"xml") logging.info("POST请求\n"+str(soup)) MsgType=soup.MsgType.string if(MsgType=='event'): if(soup.Event.string=="SCAN" or soup.Event.string=="subscribe" ): key=soup.EventKey.string openid=soup.FromUserName.string logging.info("EventKey"+str(key)) # 商店管理员扫描 if(key.startswith("ownerid")): key=key.split("ownerid")[1] data={"openid":str(openid)} res=requests.put("http://www.example.com/owner/"+key+"/",json=data) return '' # 商店顾客扫描 if(key.startswith("qrscene_")): key=key.split("qrscene_")[1] data={"shopid":key} res=requests.put("http://www.example.com/customer/"+openid+"/",json=data) logging.info(str(res.json())) return "" # WX.notify(soup.FromUserName.string) return "" return ""
你好,请问这个问题你解决了吗?是怎么解决的呢?我现在也遇到了这个问题,不知道怎么办呢,求助
编橙之家文章,
相关内容
- 大牛看下想动态获取对象特定属性名称,python源码应该怎
- Django admin管理站点修改账户属性报 column 'change_messsage
- Python模块之间共享静态变量的实现原理是什么,python静
- Python元组对索引引用正确语法应该是什么,python索引
- Python判断rss是否更新过用什么方法,python判断rss更新
- Python udp监听线程不能正常启用,pythonudp监听线程,想实
- 想用python抓万达订票信息求个思路,python万达,想在万达
- Python引用非当前目录模块实现方法问题,python当前目录
- 请问python nginx与uwsgi部署Django项目显示两个相同进程是
- 求解斐波那契数列用for计算方法实现的原理,斐波那契
评论关闭