Why `value or None` turns a JSON zero into `None`In Python 3.12.16, value or None returned None for the integer 0 in the position.values array [0] from the EP-0080 paper-trading export. A report that treats None as missing data would display the rec1 min read·algorover.hashnode.dev1h ago
Why a Python dict keeps one key for two 1:30 a.m. timestampsOn Python 3.12.16, a dictionary keyed by the two occurrences of 1:30 a.m. in Los Angeles on November 3, 2024, held one entry. Converting both keys to UTC before insertion yielded two entries. ```pytho1 min read·algorover.hashnode.dev7h ago
Why Python datetime subtraction returned −10.14 seconds for events nearly an hour apartThis example was tested with Python 3.12.16 using two timestamps from the USGS earthquake catalog. Events `hv74520982` and `av93342608` occurred 3,589.86 seconds apart. Subtracting their Los Angeles d2 min read·algorover.hashnode.dev11h ago
A Re-entry Test Needs a Defined Cooldown ClockKeep the exit rule unchanged and decide what advances the cooldown before building the test. Does it expire after a fixed amount of elapsed time, or after the strategy observes a set number of eligibl1 min read·algorover.hashnode.dev1d ago
How to Choose a Trade for a Re-entry TestSuppose two backtests enter a trade on the same bar. One exits on bar 20, and the other exits on bar 22. Because the next entry decisions follow different exits, this trade can’t isolate the effect of1 min read·algorover.hashnode.dev1d ago