Skip to content

if type(df.index) == pd.DatetimeIndex or df.index[-1]>1e8 or '.RangeIndex' not in str(type(df.index)) bug: #571

Description

@iceteapi

the source code

if type(df.index) == pd.DatetimeIndex or df.index[-1]>1e8 or '.RangeIndex' not in str(type(df.index)):
df = df.reset_index()

something wrong :
df = self.klines_cached.set_index('datetime').copy()
df.index = pd.to_datetime(df.index, unit='ms')
print("type(df.index)=", type(df.index))
if df.index[-1] > 1e8:
type(df.index) is pd.DatetimeIndex ,

if df.index[-1] > 1e8:
^^^^^^^^^^^^^^^^^^
TypeError: '>' not supported between instances of 'Timestamp' and 'float'

No activity

Activity on this issue will appear here.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions