Skip to content

Candles: Start and End Time - Wrong Object Call #52

Description

@SHAHRUKH-KHAN

The _epoch_millis(start) or _epoch_millis(end) method calls will throw and is throwing attribute error
image

This happens because the documentation says that start and end should be an integer.
image

Two Fixes

  1. Either Send a datetime object in the
    candles = bitvavo.candles('BTC-EUR', '1h', start = datetime(2024, 8, 10, 9, 30), end = datetime(2024, 8, 10, 9, 40))

  2. Just update the _epoch_millis(dt) to return dt*1000 instead of return dt.datetime()*1000. If one sends an integer, this function will always throw an error as mentioned above.

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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions