expire: https://github.com/redis/redis-py/blob/42b937fa1f73f3e8251eba5ec8ead2fcbaec7c50/redis/commands/core.py#L1592 set: https://github.com/redis/redis-py/blob/42b937fa1f73f3e8251eba5ec8ead2fcbaec7c50/redis/commands/core.py#L2175 The `set` api `ex` should be a interger, but `expire`'s `time` can use a string(integer in string type) as input. It make me confusing. Both can also accept string type is more convenient.