redis-doc icon indicating copy to clipboard operation
redis-doc copied to clipboard

Command Does Not Include Response Type

Open skeggse opened this issue 11 years ago • 7 comments

commands.json should include an expected response type for each command. For example, INCR should have a response property of "integer", because under normal operating conditions it responds with a long integer.

skeggse avatar Jul 31 '13 06:07 skeggse

Hello @skeggse

I'm not sure that I understand the issue - commands.json at its current form does not feature the response type as it is already specified in each command's .md file.

itamarhaber avatar Oct 19 '19 18:10 itamarhaber

I opened this six years ago, and have no recollection about the problem I was trying to solve or any additional details. I'll consider this closed.

skeggse avatar Oct 19 '19 23:10 skeggse

Sure - my apologies for the belated reply.

itamarhaber avatar Oct 20 '19 08:10 itamarhaber

@itamarhaber, if I recall correctly, my use case was having response types in the JSON so that machines could process them. Specifically, there was a TypeScript library that derived typings from this project so that types could be verified via static analysis at compile time.

nl-brett-stime avatar Oct 20 '19 18:10 nl-brett-stime

@nl-brett-stime === @skeggse ?

Ok, I can see how this could be handy for clients that want to know beforehand about the response's type. Funnily enough, with RESP3 this should be a moot point. Still, it may be worth the effort if only for completeness' sake.

itamarhaber avatar Oct 20 '19 19:10 itamarhaber

Reopening this for further consideration

itamarhaber avatar Oct 20 '19 19:10 itamarhaber

Yeah this seems reasonable.

@nl-brett-stime === @skeggse ?

Nope!

skeggse avatar Oct 20 '19 19:10 skeggse

Closing as stale.

nermiller avatar Nov 10 '22 20:11 nermiller