ArcticDB icon indicating copy to clipboard operation
ArcticDB copied to clipboard

IndexRange interect does not take into account if the intervals are opened/closed

Open vasil-pashov opened this issue 1 year ago • 1 comments

Describe the bug

IndexRange has a few utility functions:

  • friend bool intersects(const IndexRange &left, const IndexRange& right)
  • friend bool intersects(const IndexRange &rg, const IndexValue &start, const IndexValue &end)
  • friend bool overlaps(const IndexRange &left, const IndexRange& right) none of which takes into account if the intervals passed are opened or closed. The code calling them has various adjustments to deal with this, but they are not in a central place and seem arbitrary.

Steps/Code to Reproduce

n/a

Expected Results

All functions should deal with opened/closed intervals rather than expecting the user to pass the right kind of interval (which currently is closed on both sides)

OS, Python Version and ArcticDB Version

all

Backend storage used

No response

Additional Context

No response

vasil-pashov avatar Feb 06 '24 16:02 vasil-pashov