Comments (23)
Thanks again. The post you pointed me to is not a good starting point for newbie, because it's full of terms without explanations and it points to external content that point to external content that point to ... [etc... ]
Please, what follows is not a polemic, I'd like just to illustrate what panic I feel when trying to get right info.
TL;DR : we need a page (not a blog post that will disappear down into a page after new contents posted), but a PAGE, with:
- what the project do
- HOW the project is using chrome headless via the puppeteer and why it's no more working for new accounts
- What the project is trying to fix the problem, explain WHAT are all of the strange terms we see uses regularry
- What to do now to really getting started, WITHOUT deviating user too much to different pages
The long version.
I try to open the blog talking to migrations v.14 o v.16.
Why must I read this? I never write a line of code using your framework?
But I open, and read
Puppet System means to connect Wechaty API to any kinds of Puppets
What are these? ?!?! I want to use the api, but must I to connect to something before use it? If yes, why? If no, really, why to tell advanced features to a newbie?
when I run into
2. How to run puppet-padchat
Wechaty will start with puppeteer(web solution) by default, if you want to change to padchat, you need to set the environmental variable.
I must leave page
See more in wechaty wiki: How to run a new wecahty-puppet-padchat"
In the target page (https://github.com/Chatie/wechaty/wiki/Puppet#2-run) I can see thhis
Using puppet-padchat to run ding-dong-bot
WECHATY_PUPPET=padchat npm run demo
So, if it is just question of a row, why don't include in the tutorial?
But as newbie I am being distracted from subsequent text
2.1 How to run a new wecahty-puppet-padchat
NPM
1. Install
npm install wechaty@next
2. Run
Get WECHATY_PUPPET_PADCHAT_TOKEN from #1296
Set WECHATY_PUPPET_PADCHAT_TOKEN and Set WECHATY_PUPPET=padchat
3. Start Command
WECHATY_PUPPET_PADCHAT_TOKEN=your padchat token WECHATY_PUPPET=padchat node examples/ding-dong-bot.js
So think that the section 2 is useless because instead I must follow the section 2.1 ... and then I must read the issue wechaty/wechaty#1296 , so I am two page away for the starting point of reading
So I make me courage and scan the QR, fill the form ( wechaty/wechaty#1296 (comment)) and see in my wechat that our chat bot acepted me into , but it writes in chinese (except where you ask me the secret code but i've no idea of what is and where to get it ...
Ok, long press and wechat translate me the message into a not-readable english, but I understand that the bot needs a secret code ... I'll wait to receive into my mail.
The first point is to remove the text
- How to run puppet-padchat
Wechaty will start with puppeteer(web solution) by default, if you want to change to padchat, you need to set the environmental variable
Warn the user that actually the web solution is not working so it's mandatory to wait for a new release or join to an alpha program . And again, what damn is a puppet!? and what is padchat ? and what is
Going on reading, I read about
Using TSLint
Is it needed? Or is it pre-included when installing wechat?
Why there are 3 versions around ? 0.14, 0.16 and 0.17 ('next', I suppose) .
Sorry, again for long post and please trust me: It's not polemic, it to warn the team that actually the is not a starting point to start from.
I tried with the wiki on the main repo (i think it's the main repo): https://github.com/Chatie/wechaty/wiki
but the getting start page ( https://github.com/Chatie/wechaty/wiki/GettingStarted ) has a broken link to the intro video and just above there is no the good old step by step text .. no , the instr ctuions starts from docker, before examples and api..
I know docker, but it's not the starting point, it's the best practice. If we are not able to run locally using node, we cannot even think of start using it inside a docker
So I skipped docker to see Example page, but this page doesn't exists at all.
So I say me "look at the code", and jump to : https://github.com/Chatie/wechaty/tree/master/examples
Ok., there is a readme without instructions on how to run the examples...
And the readme points to https://github.com/Chatie/wechaty/wiki/API that is declared as a deprecated page
... sorry again, please, forgive me for my approach if it hurts ... I'm very happy to have found this project, and thank you a lot for all the hard, and long, work and for open sourced it.
But it need a really clear step-by-step entry point with:
- what is
- how to run the first project using javascript or using typescript, warning that for new accounts it will not works
- what to do for new accounts
and a bridge from 'entry' a 'api docs' with concepts and term explanations, and background...
from getting-started.
from getting-started.
Hi @realtebo,
Thank you so much for posting this long comments/reviews for our project documentation, and I have to agree with you that we need ONE PAGE to help a newbie for Wechaty to get started easily!
As you said, it should straightforward and focus on getting started, without any advanced information. It should introduce the background, concepts, APIs, and keep short and easy to read.
I'm planning to write this kind of page for a long time, but because I'm too familiar with Wechaty, so your comments about the document are really helpful.
I'll write an outline later, and I'd like to show you the outline before continue to fill out the details, because this page is exactly what you need, and I need to make sure you are satisfied with it.
Thank you again for your feedback, looking forward to talking with you soon!
from getting-started.
@lijiarui Could you please fix this repository so that it will be ok with the latest version of Wechaty?
Because if it's keeping outdated, there will be lots of unnessary confusing for new developers who want to use Wechaty, which will make them waste time, and also no good for adaptering Wechaty to the community.
from getting-started.
Hello @realtebo,
I had rewritten the README of this repository, with the points we had discussed in this thread, and also try to keep it as simple as possible.
Could you please have a look at it, and tell me what you think about the new version?
https://github.com/lijiarui/wechaty-getting-started
Please feel free to let me know if you think there's any part should be add/del/modify-ed.
Thank you very much!
from getting-started.
Yes, you are right.
Some of the puppet(Wechaty Puppet, specifically) has the ability to login via username and password, as you see in the code. However, I have no plan to add an API to enable login via username and password yet, because of the following three reasons:
- some of the puppets do not have the ability to do that, for example, PuppetWechat4u, which is using the Web API;
- when you log in by scan QR Code, you can keep your session on your phone, which means you can use WeChat at the same time when your Bot is online; If you login in by username/password, then all other login sessions will be terminated, only your Bot can use WeChat.
- as you have already seen, we are using a Protocol Server to control the iPad WeChat. If you want to use username/password to log in, then you will have to send that sensitive information to a 3rd party server, which will not be comfortable for most people.
As your suggestion about the addition to the README: could you please send a PR to modify it so that you can feel comfortable? Because it will be very helpful if you could help me to fix some part of it.
from getting-started.
After QR scan and login, I got
14:46:43 ERR PuppetWebBridge init() initPage() onLoad() exception: Error: Per salvaguardare la sicurezza del tuo account, l'
accesso a WeChat via Web è stato sospeso. Puoi accedere a WeChat per Windows o a WeChat per Mac su un computer. Scarica WeCh
at per Windows o Mac all'indirizzo http://wechat.com.
14:47:09 WARN PuppetWeb initWatchdogForPuppet() dog.on(reset) last food:[object Object], timeout:60000
(node:8072) UnhandledPromiseRejectionWarning: Error: Per salvaguardare la sicurezza del tuo account, l'accesso a WeChat via
Web è stato sospeso. Puoi accedere a WeChat per Windows o a WeChat per Mac su un computer. Scarica WeChat per Windows o Mac
all'indirizzo http://wechat.com.
at Bridge.<anonymous> (D:\wechaty-getting-started\node_modules\wechaty\dist\src\puppet-web\bridge.js:175:27)
at Generator.next (<anonymous>)
at fulfilled (D:\wechaty-getting-started\node_modules\wechaty\dist\src\puppet-web\bridge.js:4:58)
at process._tickCallback (internal/process/next_tick.js:68:7)
(node:8072) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside o
f an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
14:47:09 WARN PuppetWebBridge quit() page.close() exception: Error: Protocol error: Connection closed. Most likely the page
has been closed.
The point here is at:
"Per salvaguardare la sicurezza del tuo account, l'
accesso a WeChat via Web è stato sospeso. Puoi accedere a WeChat per Windows o a WeChat per Mac su un computer. Scarica WeCh
at per Windows o Mac all'indirizzo http://wechat.com."
saying that wechat is no more awailable via web....
Is this project still working?
from getting-started.
Hello @realtebo,
Thanks for using Wechaty.
This repository is for Wechaty v0.14 or before, and it works well when your Wechat account is old enough(new Wechat account will not be permitted to login via web anymore).
If you want to use Wechaty with your new account, please have a look at wechaty/wechaty#1296, we can support Pad Protocol after Wechaty v0.15.
Good luck!
from getting-started.
@zixia : thanks, the first problem is gone away.
I refer to:
4:44:07 INFO Wechaty v0.13.93 starting...
(node:8072) UnhandledPromiseRejectionWarning: TypeError: rxjs.interval is not a function
I fixed using npm install [email protected] --save
.
About "Pad Protocol" , what it this? Can you point me to more info?
And, can i install [email protected] ?
from getting-started.
- I appliead for developer program at Chatie/wechaty#1296
- We are already at 0.17 ?!!
I now understand that this getting started is too old to be a good starting point and I will move to the other repo. So I close issue here and retry from scratch using info at the main repo.
from getting-started.
@realtebo Welcome to v0.17! ;-)
@lijiarui had just published a great article on https://blog.chatie.io, talking about how to migrate Wechaty v0.14 to v0.16, I'd like to recommend you to read it, and hope that could help you more.
See: Porting Code From Puppeteer To Padchat
from getting-started.
Very good work ! Thanks.
There is only a little addition I suggest: this system is different from telegram bot api, when you create a new entity from scratch.
Your framework allow to create a software that impersonate an already existing real account.
But I do not know if this Is right. I see in the code the ability to log in via username and password, so probably I can create an account from scratch and do not need to scan the qr .... but I've not tried yet, because I'm here exactly to find a bot that act like an avatar of me
from getting-started.
@zixia, please copy what you've written, why not to log in via username and password, into the wiki/faq.
This info is too valuable to be burried & lost in a issue later on.
from getting-started.
@suntong I agree with you that this should put into the FAQ.
Would you like to add it by yourself? Because the wechaty/wiki is open to the community, and any valuable addition is welcome.
from getting-started.
I cannot access the .md source that you put up there, but for this simple task, sure I'll do it.
(I know the wechaty/wiki is open to the community, and have already made some changes I deem necessary...)
from getting-started.
Thank you very much, appreciate it.
from getting-started.
Great work, thanks!
from getting-started.
really, good works @suntong 👍
Can you explain what do you mean by .
we are using a Protocol Server to control the iPad WeChat
I know (now) that this project offers code to interface with a server (your and closed) to act like a bridge ... but what is "iPad WeChat" and how do you control what ? ...
from getting-started.
Telling from https://github.com/Chatie/wechaty/wiki/Puppet#11-core-directory, my understanding is
- "iPad WeChat" A iPad solution to connect WeChat through WeChat-iPad Protocol Server, see padchat-sdk link there.
- About "control what", your wechaty is still controlling the WeChat session automatically, just like any wechaty based code/projects do, but it does the control via WeChat-iPad Protocol Server, just one of many different ways to control the WeChat session.
See https://github.com/Chatie/wechaty/wiki/Puppet#11-core-directory for details.
And also, https://blog.chatie.io/wechaty-new-release-version-0.16/, especially the link in
Learn more about how to use the PuppetPadchat from Wechaty v0.15 Alpha Testing: Win32/iPad/Android/iOS/API Puppets Support are comming! #1296
from getting-started.
@suntong : thanks
From my newbie point of view this first phrase is useless, give me no info,
A iPad solution to connect WeChat through WeChat-iPad Protocol Server, see padchat-sdk link there.
"iPad solution" is .. what? an app on a phisical iPad? or it's just smoke ... I understand just this:
"iPad WeChat" is something we do in someway that we don't explain, and this server is related to iPad world in a way I don't tell you, to bridge your connection to wechat servers in a way we don't tell you .
Thanks again for all the works, but I'm only looking for infos and this pieces of text doesn't help me.
it does the control via WeChat-iPad Protocol Server, just one of many different ways to control the WeChat session.
What is a WeChat-iPad Protocl Server? Is the RPC server we use in the alpha ? or what?
Anyway, I love this project, and I'm so curios ! Please, forgive me for my impatience, but I need, or .. I'd like, clarifications that I've not found yet.
For what I understand, the code of https://github.com/lijiarui/wechaty-puppet-padchat/ is what wechaty uses to connect to their "middleware" server... So stilll I don't know how to connect TO wechat.
About padchat-sdk, thanks 👍 , I'll give it another chance.
But
Description
Padchat development kit. Log in and operate WeChat through the websocket protocol and the WeChat ipad protocol service program running on the Windows platform.
What is the WeChat ipad protocol service program running on the Windows platform ?
Their demo start with
const url = ' ws://host:7777 '
Of course, I already dissected Wechat app for Windows enough to be sure that the Windows version of Wechat do not use websocket at all, so ... what ... ?
from getting-started.
@realtebo @suntong Thank you very much for all the feedback and discussions.
I believe with the current wechaty-getting-started
repository(this repo), the beginners should be easier to run wechaty, and we hope it's an out-of-the-box task.
Is there have any other improvement we should do on this repo? if no, can we close this issue for now?
And any future suggestion & feedback will be welcome, thanks again!
from getting-started.
Fine with me.
Thanks for all those fantastic changes for people to easily get started.
from getting-started.
@suntong You are welcome!
I'll close this issue for now, and please let me know if there are any other problems.
from getting-started.
Related Issues (20)
- Why can't I receive messages from the group after I change the group name
- "wechaty": "^1.20.2", 这个版本下 不支持js环境吗,我没有用ts HOT 1
- 为什么不能发送微信语音 HOT 5
- Gitpod doesn't work
- Message ready() payload.talkerId not exist HOT 1
- The requested module 'wechaty' does not provide an export named
- Error: execute proxyWechaty(init) error: 503, init() without a ready angularenv HOT 4
- Module '"wechaty"' has no exported member 'MessageType'.
- 使用npm start之后占用内存过高,高达10g HOT 1
- 扫描二维码不能登陆 service unavailable for this account
- npm install error 依赖安装失败 HOT 6
- 企业微信扫码后手机端出现了新设备登录提醒
- Error: @swc/core threw an error when attempting to validate swc compiler options. You may be using an old version of swc which does not support the options used by ts-node. Try upgrading to the latest version of swc. HOT 1
- Contact FindAll() API does not work.
- 直接引入Friendship失败 HOT 1
- [TypeError]: Cannot read properties of undefined (reading 'status')
- npm install err HOT 2
- SyntaxError: Unexpected token ':'
- 直接启动报错 Maximum number of redirects exceeded
- npm start 显示令牌,服务地址命名已经设置为新的地址,却还是api.chat.io
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from getting-started.