Add support for end dates/IDs to diff processing functions
This adds a new parameter `end_id` to the diff processing functions, which allows to define the precise ID when to stop downloading diffs. This gives more fine-grained control over the number of diffs downloaded than `max_size` can do.
The tools pyosmium-get-changes and pyosmium-up-to-date get two new parameters where you can define the end date either with an ID or a date. The latter will automatically compute the appropriate ID for your convenience. Just keep in mind that date-to-ID conversions are always approximate. There is no guarantee that using `--end-date` in one run and the same date as `--start-date` in the next run will result in continuous, non-overlapping diffs. Always use the returned ID as a base for the next run.
Adds proper typing for the tool code and some tests for pyosmium-up-to-date. The tests in turn uncovered that file replacement doesn't work as expected on Windows. So fixed that.
合并状态:已合并 合并于 2025-10-05 关闭于 2025-10-05 0 条评论