Open Herringway opened 1 year ago
Given,
Request up to
limit
number of messages [...]
and
While an ISUPPORT token value of 0 may be used to indicate no message limit exists, servers SHOULD set and enforce a reasonable maximum and properly throttle CHATHISTORY commands to prevent abuse.
I read this as a <limit>
of 0
would return no messages.
I cannot see how "no message limit" could be interpreted as "a limit of zero messages".
The semantics of the 005 token and the limit argument of the CHATHISTORY
command are separate. The specification, as written, entails that a CHATHISTORY
command with a limit argument of 0
receives an empty batch.
A <limit>
of 0
to indicate "no message limit" or "some default limit" would IMO be more useful than making a request for "0 messages". I don't see why anyone would ever desire the latter.
If a <limit>
of 0
isn't desired as "no message limit" for whatever reason, allowing for the use of *
to indicate "some default limit" would be nice.
I would hope this gets addressed before #437 is completed.
I cannot see how "no message limit" could be interpreted as "a limit of zero messages".
because I interpreted this parameter as a direct argument to something like https://www.sqlite.org/lang_select.html#the_limit_clause
If a
of 0 isn't desired as "no message limit" for whatever reason, allowing for the use of * to indicate "some default limit" would be nice.
Could you clarify the use case here? The CHATHISTORY
command is not intended for use by end users directly, it's intended for programmatic use by client software. Is there a reason client software would not be able to choose its own limit?
If a of 0 isn't desired as "no message limit" for whatever reason, allowing for the use of * to indicate "some default limit" would be nice.
Could you clarify the use case here? The
CHATHISTORY
command is not intended for use by end users directly, it's intended for programmatic use by client software. Is there a reason client software would not be able to choose its own limit?
Ah, I somehow missed the part where it says a CHATHISTORY
ISUPPORT token MUST be sent with the server's limit. With that in mind I can't imagine a <limit>
of *
being all that useful.
It is unclear what a server is expected to do when receiving a limit of 0 in a CHATHISTORY message. Does it mean no messages? Or does it mean no limit, like in the ISUPPORT token? The latter option seems much more useful and consistent, IMO.