Draft
Add timestamp-based package filtering (exclude-newer / exclude-older)#151
Conversation
Agent-Logs-Url: https://github.com/conda-incubator/conda-mirror/sessions/6a079e7c-4576-40fd-9fd9-aab0f5bf2afc Co-authored-by: pavelzw <29506042+pavelzw@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add timestamp based threshold support for package mirroring
Add timestamp-based package filtering (exclude-newer / exclude-older)
Mar 27, 2026
|
Thank you for opening this pull request! 👋🏼 This repository requires pull request titles to follow the Conventional Commits specification and it looks like your proposed title needs to be adjusted. Details |
Member
|
@copilot fix CI |
Agent-Logs-Url: https://github.com/conda-incubator/conda-mirror/sessions/90fb0126-16ac-43fd-86fd-f71280e2ac9a Co-authored-by: pavelzw <29506042+pavelzw@users.noreply.github.com>
Author
|
Was all off the code for this PR just vibe coded? Not used to seeing a bunch of copilot messages with no human interactions. |
Member
|
Yes I tried it out back then with semi success. Feel free to pick this thing up or start from scratch if you want :) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support for filtering mirrored packages by build timestamp, enabling use cases like "mirror only packages built after 2023".
Changes
PackageFilterreplacesMatchSpecWrapper— extends MatchSpec with optionalexclude-newer/exclude-oldertimestamp bounds. Both plain-string and object YAML forms are supported and can be freely mixed.parse_datetime— accepts RFC 3339 (2025-01-01T00:00:00Z), date-only (2025-01-01→ midnight UTC), and relative durations (90d= 90 days ago).MirrorModevariants updated to carryVec<PackageFilter>instead ofVec<MatchSpec>.get_packages_to_mirror— delegates toPackageFilter::matches(). Also fixes a pre-existing logic bug inIncludeExcludewhere packages matching anincludeoverride were still being excluded when anexcludelist was present.timestampfield always pass the bounds check (include-unknown).Example config
📱 Kick off Copilot coding agent tasks wherever you are with GitHub Mobile, available on iOS and Android.