Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 8 additions & 2 deletions .agents/rules/starlark.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,11 @@ globs: "*.bzl,BUILD,BUILD.bazel,*.bazel"
* In macro implementations, internal repository target references **MUST** be
canonicalized using `str(Label("//path/to:target"))` so they resolve in the
macro's module context rather than the caller's repository context.
* Note that `python/private/common_labels.bzl` defines `labels`, a struct
containing common canonicalized label strings used across the project.
* **Reuse `python/private/common_labels.bzl`**: When a target label is listed in
`python/private/common_labels.bzl` (or shared across multiple `.bzl` files
such as `flags.bzl` and `config_settings.bzl`), load `labels` from
`:common_labels.bzl` and use `labels.<NAME>` (or `Label(labels.<NAME>)`)
instead of redefining duplicate `Label("//...")` values.

## Manual Tag on Internal Macro Helper Targets
* When macros instantiate internal helper targets (such as private rule targets
Expand Down Expand Up @@ -61,6 +64,9 @@ globs: "*.bzl,BUILD,BUILD.bazel,*.bazel"
## Code Style & Conventions
* **Dict union (`|`)**: Use `|` instead of `dicts.add(...)` from
`@bazel_skylib//lib:dicts.bzl` when merging dictionaries.
* **Type Checks (`@bazel_skylib//lib:types.bzl`)**: Prefer `types.is_*` helpers
(e.g., `types.is_dict(x)`, `types.is_list(x)`, `types.is_string(x)`) from
`@bazel_skylib//lib:types.bzl` instead of `type(x)` comparisons.
* **Non-Info Provider Naming**: Add `# buildifier: disable=name-conventions`
above `provider()` declarations that do not end in `Info` (e.g. `*Fileset`).
* **Docstring Formatting Invariants**: Use triple-quoted strings for multi-line
Expand Down
5 changes: 4 additions & 1 deletion .agents/rules/workspace.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,7 @@ basis:
* When pushing to a checked-out PR branch from an external fork, push
explicitly to that remote (`git push <remote> HEAD:<branch>`). Do not rely on
a bare `git push`.

* When syncing a branch with `upstream/main`, commit or stash local changes
*before* running `git merge upstream/main` and conclude the merge in its own
dedicated commit. Never run `git stash` while `MERGE_HEAD` is active, as
`git stash` clears `MERGE_HEAD`.
9 changes: 5 additions & 4 deletions .agents/skills/monitor-ci-results/SKILL.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ or when monitoring CI after PR updates:
> launch duplicate monitoring jobs for the same PR.

1. **Check Existing Process**: Check if a monitor script is already running for
**this specific PR** using `pgrep -f "monitor_remote_ci.py <pr_number>"`. Do
NOT use a generic grep without `<pr_number>`, as other active agent
conversations may be monitoring different PRs concurrently. If one is
already running for this PR, do not start another instance.
**this specific PR** using
`pgrep -af "[m]onitor_remote_ci.py <pr_number>"`. Do NOT use a generic grep
without `<pr_number>`, as other active agent conversations may be monitoring
different PRs concurrently. If one is already running for this PR, do not
start another instance.
2. **Launch Monitoring Script**: If no monitor process is active for
`<pr_number>`, launch the script in the background:
```bash
Expand Down
4 changes: 4 additions & 0 deletions .agents/skills/review-code/review-starlark-prompt.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,5 +12,9 @@ in `git diff` against the project's Starlark coding rules and conventions:
5. Check multi-line rule/macro doc arguments: use triple-quoted strings
(`"""`), and do NOT use trailing backslashes (`\`) on opening triple-quotes.
6. Verify analysis tests use `rules_testing`, not `bazel_skylib`.
7. Ensure shared labels use `labels.<NAME>` from
`python/private/common_labels.bzl` rather than redefining `Label("//...")`.
8. Prefer `types.is_*` helpers from `@bazel_skylib//lib:types.bzl` over
`type(x)` comparisons.

@.agents/skills/review-code/review-report-format.md
Loading