dateutil
dateutil copied to clipboard
Need help in doing the least expensive way to do date existence check in a recurrence rule?
For the input of date and rrule object, I want to get if the provided datetime object exists in the rule set. With the methods provided right now, I do a before and after check and then compare the occurrence, but this is non performant as it iterates over many epochs to reach my required date.
One of the technique I am thinking is to index the dates in a database and move the computation from my compute units to store units but if you have something which can do the same operation in O(log n) complexity I can save up on the network calls.