MCPcopy
hub / github.com/redis/redis-py / __range_params

Method __range_params

redis/commands/timeseries/commands.py:739–766  ·  view source on GitHub ↗

Create TS.RANGE and TS.REVRANGE arguments.

(
        self,
        key: KeyT,
        from_time: int | str,
        to_time: int | str,
        count: int | None,
        aggregation_type: str | list[str] | None,
        bucket_size_msec: int | None,
        filter_by_ts: List[int] | None,
        filter_by_min_value: int | None,
        filter_by_max_value: int | None,
        align: int | str | None,
        latest: bool | None,
        bucket_timestamp: str | None,
        empty: bool | None,
    )

Source from the content-addressed store, hash-verified

737 return self.execute_command(DELETERULE_CMD, source_key, dest_key)
738
739 def __range_params(
740 self,
741 key: KeyT,
742 from_time: int | str,
743 to_time: int | str,
744 count: int | None,
745 aggregation_type: str | list[str] | None,
746 bucket_size_msec: int | None,
747 filter_by_ts: List[int] | None,
748 filter_by_min_value: int | None,
749 filter_by_max_value: int | None,
750 align: int | str | None,
751 latest: bool | None,
752 bucket_timestamp: str | None,
753 empty: bool | None,
754 ):
755 """Create TS.RANGE and TS.REVRANGE arguments."""
756 params: list[EncodableT] = [key, from_time, to_time]
757 self._append_latest(params, latest)
758 self._append_filer_by_ts(params, filter_by_ts)
759 self._append_filer_by_value(params, filter_by_min_value, filter_by_max_value)
760 self._append_count(params, count)
761 self._append_align(params, align)
762 self._append_aggregation(params, aggregation_type, bucket_size_msec)
763 self._append_bucket_timestamp(params, bucket_timestamp)
764 self._append_empty(params, empty)
765
766 return params
767
768 @overload
769 def range(

Callers 2

rangeMethod · 0.95
revrangeMethod · 0.95

Calls 8

_append_latestMethod · 0.95
_append_filer_by_tsMethod · 0.95
_append_countMethod · 0.95
_append_alignMethod · 0.95
_append_aggregationMethod · 0.95
_append_emptyMethod · 0.95

Tested by

no test coverage detected