Skip to content

Allow bots to be filtered based on labels #561

Done

Description

@mcwhittemore

This way you can have different types of bots react to different issue types

Activity

  1. self-assigned this
    on Nov 25, 2026
  2. loopway-bot commented on Nov 25, 2026

    @loopway-bot
    Contributor

    I can't start on this yet. #561 ("Allow bots to be filtered based on labels") has only one line of body and no How to test it or Done when section. Could you answer these, or edit the issue?

    1. Where is the label filter set? Is it a per-bot field in the loopway config, for example labels: ["bug"] on a bot, or something else?
    2. How should a bot with several labels match? Should the issue need any one of them, or all of them?
    3. What should a bot with no label filter do? I'd assume it keeps reacting to every issue, as it does now.
    4. Should the filter apply only to issues, or to pull requests too?
    5. What are the steps you would run to test it, and what should you see when it works?

    Reply here to answer: loopway-bot is waiting.

  3. mcwhittemore commented on Nov 25, 2026

    @mcwhittemore
    CollaboratorAuthor
    1. its part of the frontmater of the bot.md file
    2. we should have an and, or and ! opporator in the logic
    3. yes
    4. both
    5. we will want a new test bot for the sandbox for an epic bot. The issue bot shouldn't react to epic bot issues.
  4. loopway-bot commented on Nov 25, 2026

    @loopway-bot
    Contributor

    PR #562 adds a labels: expression to a bot's front matter, and a bot only starts a thread on subjects whose labels match it.

    • Syntax: labels: epic needs the label, and labels: "!epic" needs it absent. { and: [...] }, { or: [...] } and { not: ... } combine them, and a bare list means and. A bot with no labels: takes everything, and it applies to issues and pull requests.
    • Scratch bots: init-scratch now writes an epic bot, and dev has labels: "!epic".
    • Checks: build, test (289 and 41), typecheck, lint and format all pass.
    • Live in the sandbox:
      • An epic issue started only the epic bot.
      • A plain issue started only dev.
      • A label added later started the epic bot on an issue dev already had, and dev's thread stayed open.
    • Not run live: pull requests. The unit tests cover them.

    Details are in verifications/562.md on the branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions