Skip to content

Commit 7dc0e64

Browse files
authored
agents: add constraint synchronization rule for dependency bumps (#4107)
When dependencies are bumped, hardcoded version pins in constraint files can conflict with newly resolved requirements and cause lockfile update targets to fail. To prevent these conflicts, expand the lockfile and dependency agent rules to trigger on constraint files and instruct agents to update any conflicting constraint pins and rerun affected update targets during dependency updates.
1 parent b28a813 commit 7dc0e64

1 file changed

Lines changed: 8 additions & 1 deletion

File tree

‎.agents/rules/lockfiles.md‎

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
---
22
trigger: glob
33
description: Rules for updating uv.lock and requirements.txt files
4-
globs: "*requirements*.txt,*requirements*.in,uv.lock,pyproject.toml"
4+
globs:
5+
- "*requirements*.txt"
6+
- "*requirements*.in"
7+
- "uv.lock"
8+
- "pyproject.toml"
9+
- "*constraints*.txt"
510
---
611

712
# Lockfile & Dependency Rules
@@ -25,3 +30,5 @@ When dependencies bump, manually synchronize:
2530
entries in `examples/bzlmod/patches/*.patch`.
2631
* **Test Assertions**: Update hardcoded versions and `dist-info` file lists in
2732
tests (`pip_whl_mods_test.py`, `pip_parse/test.py`, `pip_parse_test.py`).
33+
* **Constraints**: Update conflicting pins in `*constraints*.txt` and rerun
34+
affected `.update` targets.

0 commit comments

Comments
 (0)