while I was examining binance futures files, I came across something like this and I’m having this problem, sometimes the system data repeats itself and that’s why, how can I solve it?
I played with the value in the limit field I removed it I made 500 I made 1000 I made 1500
**end = int(dt.datetime.now(dt.timezone.utc).timestamp() * 1000)
candles = Binance.client.futures_klines(symbol=self.symbol, interval=self.interval , limit = 1000 ,endTime=end)**
df = pd.DataFrame(candles)
df = df.drop(range(6, 12), axis=1)
col_names = ['time', 'open', 'high', 'low', 'close', 'volume']
df.columns = col_names
for col in col_names:
df[col] = df[col].astype(float)
Sorry what’s the problem is? what do you mean by repeat?
The problem is that because the endtime and start time are not sent, the last values are repeated, for example, the value I took as close sometimes appears the same 3-4 times, how can I prevent this problem and prevent the problem in a healthy way. Do you understand what I mean, I use translation so I had to ask thanks my friend
I don’t think that’s an issue. When you sending the request to get klines without startTime and endTime, you will always get the latest klines. If your sending requests during the interval of last kline, you will always get the same kline. It depends on your app, but you can use the time in kline to process data.
so what solution would you suggest me because i have met many people with problems like this and sometimes it says data is duplicated even for very little time. I’m just talking about this happening sometimes and the problem can’t be resolved because the kline returns the previous value
is there anyone else guys i still have a problem or tell me how to pull the data cleanly