Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

when i try to run bot.Contact.find,get some error. #16

Open
fangjiyuan opened this issue Sep 28, 2021 · 3 comments
Open

when i try to run bot.Contact.find,get some error. #16

fangjiyuan opened this issue Sep 28, 2021 · 3 comments
Labels
bug Something isn't working

Comments

@fangjiyuan
Copy link
Member

2021-09-28 16:42:08,275 - RoomBot - ERROR - should ready() the ContactSelf payload before get it, please call the <ready()> method
Traceback (most recent call last):
File "d:\github\python-wechaty-puppet-itchat\examples\hotreload_bot.py", line 140, in send_report
contact = await bot.Contact.find(query=ContactQueryFilter(name=str3))
File "D:\ProgramData\Anaconda3\envs\py37\lib\site-packages\wechaty\user\contact.py", line 110, in find
contact_list = await cls.find_all(query)
File "D:\ProgramData\Anaconda3\envs\py37\lib\site-packages\wechaty\user\contact.py", line 158, in find_all
contacts
File "D:\ProgramData\Anaconda3\envs\py37\lib\site-packages\wechaty\user\contact.py", line 152, in
lambda x: x.payload and (
File "D:\ProgramData\Anaconda3\envs\py37\lib\site-packages\wechaty\accessory.py", line 80, in payload
type(self).name
ValueError: should ready() the ContactSelf payload before get it, please call the <ready()> method

@lyleshaw
Copy link
Member

Please update python-wechaty-puppet-itchat to the latest version to support the Contact.find function.

And note that due to the limitations of UOS-WeChat, python-wechaty-puppet-itchat cannot obtain the weixin_id of the contact, so you can only search for the contact by UOS-WeChat contact name (such as @46213ce0c1ad615c6fb330047c777e29cb19b5363047c777e29cb19b53305c)

@fangjiyuan
Copy link
Member Author

Please update python-wechaty-puppet-itchat to the latest version to support the Contact.find function.

And note that due to the limitations of UOS-WeChat, python-wechaty-puppet-itchat cannot obtain the weixin_id of the contact, so you can only search for the contact by UOS-WeChat contact name (such as @46213ce0c1ad615c6fb330047c777e29cb19b5363047c777e29cb19b53305c)

我已经更新了最新版本的python-wechaty-puppet-itchat,还是无法使用Contact.find,提示和一楼一样。

@wj-Mcat wj-Mcat added the bug Something isn't working label Sep 29, 2021
@fangjiyuan
Copy link
Member Author

fangjiyuan commented Oct 13, 2021

its like not work. once i run await bot.Contact.find , its take a lot of time to load contact and error at last.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

3 participants