ahmadazizi / redis_timeseries_manager

RedisTimeseriesManager is a redis timeseries management system that enhance redis timeseries with features including multi-line data, built-in timeframes, data classifiers and convenient data accessors.
https://github.com/ahmadazizi/redis_timeseries_manager
MIT License
17 stars 8 forks source link

'timeframe_specs' as str? Looks like it's a dict. #1

Open tlk3 opened 1 year ago

tlk3 commented 1 year ago

As far as I can tell, 'timeframe_specs' is used as a dict (including your examples). Is there a time when it's used as a str? Does typing need to be updated?

` def _create_rule(self, c1:str, c2:str, line:str, timeframe_name:str, timeframe_specs:str, source_key:str, dest_key:str):

timeframe_specs (str): timeframe specs

`

_timeframes = { '1m': {'retention_secs': 60*60*24*10}, '1h': {'retention_secs': 60*60*24*90, 'bucket_size_secs': 3600}, '1d': {'retention_secs': 60*60*24*365, 'ignore_rules': True}, }

tlk3 commented 1 year ago

Ugh what's up with missing newlines.

ahmadazizi commented 1 year ago

Yes, it's a wrong type hint in function definition. It has to be as dict