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

after using 'skip_id', i can't accept data #88

Closed
larryclean opened this issue Mar 24, 2017 · 9 comments
Closed

after using 'skip_id', i can't accept data #88

larryclean opened this issue Mar 24, 2017 · 9 comments
Labels

Comments

@larryclean
Copy link

larryclean commented Mar 24, 2017

sio.enter_room(sid, msg['Room'])
await sio.emit("join", ResultFactory(user_list, home_list, my_list, game, info.__dict__), room=sid)
await sio.emit('join', ResultFactory(info.__dict__), room=msg['Room'],skip_sid=sid)

This time ago can not receive any data.

@larryclean
Copy link
Author

wx20170324-115339

remove 'skip_sid'
wx20170324-115415

@larryclean
Copy link
Author

i want to notice everyone in the room except myself.
can i do?

@miguelgrinberg
Copy link
Owner

I can't reproduce this here.

I took the app.py example in this repository (from the sanic folder), and added skip_sid=sid to room broadcasts. I see no problems here.

Can you provide a short example that reproduces this problem?

@larryclean
Copy link
Author

after using 'socketio.AsyncRedisManager(redis_address)'

first open app.html is ok,but press "F5" refresh page.
This time ago can not receive any data.

@larryclean
Copy link
Author

larryclean commented Mar 24, 2017

归档.zip
this is demo

@larryclean
Copy link
Author

Can you reproduce?

@miguelgrinberg
Copy link
Owner

Sorry, I'm doing too many things at once and I dropped the ball on this.

I just tested your example and was able to reproduce the problem. The error only occurs when you send a message to only one client, and also include that client in the skip_sid argument, which basically means nothing should be sent. This condition wasn't well handled in the code. I will have a fix up in a few minutes.

@miguelgrinberg
Copy link
Owner

@Larry-Dev Can I ask you to retest with release 1.7.4? Let me know if that still gives you problems.

@larryclean
Copy link
Author

@miguelgrinberg I try to use '1.7.4'. The problem has been solved. thanks very much.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants