Arnau EC edited this page Mar 2, 2018 · 6 revisions

How to prevent your bot from disconnecting after a specific time?

Make sure to include YowIqProtocolLayer in your stack, this layer handles the ping mesages like this:

# *snip*
from yowsup.layers.protocol_iq import YowIqProtocolLayer
# *snip*
layers = (
  YourLayer,
  YowParallelLayer(YowAuthenticationProtocolLayer, YowMessagesProtocolLayer, YowIqProtocolLayer, YowReceiptProtocolLayer,   YowAckProtocolLayer),
  ) + YOWSUP_CORE_LAYERS
# *snip*
stack = YowStack(layers)
# *snip*

TODOs

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.