whirm/tgs-pc — Issue #2: Text messages are limited to 255 characters
Author: eviy
Created: 2012-02-29 10:10:58+00:00
State: open

When a message exceeds 255 characters the GUI accepts it but the message can not be converted to binary. The limit can be increased (i.e. 1024 bytes, keeping into account the MTU size) but it must be checked in the GUI before the message is created.

E dispersy/callback:564 _loop | See
stderr for exception
E dispersy/callback:564 _loop |
Traceback (most recent call last):
File "/home/raul/git/tgs-pc/src/dispersy/callback.py", line 562, in _loop
result = call[0](*call[1], **call[2])
File "/home/raul/git/tgs-pc/src/community/community.py", line 65, in
create_text
message = meta.impl(authentication=(self._my_member,),
distribution=(self.claim_global_time(),), payload=(text,))
File "/home/raul/git/tgs-pc/src/dispersy/message.py", line 645, in impl
payload_impl = self._payload.Implementation(self._payload, *payload)
File "/home/raul/git/tgs-pc/src/community/payload.py", line 11, in __init__
assert len(text.encode("UTF-8")) <= 255
AssertionError