BugBot: Difference between revisions

4,268 bytes added ,  10 December 2025
→‎Active Rules: Add a section about the inactive telemetry alerts rule.
(Fix a typo)
(→‎Active Rules: Add a section about the inactive telemetry alerts rule.)
 
(21 intermediate revisions by 5 users not shown)
Line 6: Line 6:
= Introduction =
= Introduction =
Every day hundreds of tickets are opened in [https://bugzilla.mozilla.org Bugzilla] which track the tasks, defects and enhancements needed for the development of Firefox and other Mozilla projects.
Every day hundreds of tickets are opened in [https://bugzilla.mozilla.org Bugzilla] which track the tasks, defects and enhancements needed for the development of Firefox and other Mozilla projects.
Triaging and priotirizing these bugs are an essential part of our development process and we automate part of this process so as to increase our development turn around and improve the quality of our bugs metadata. The set of tools we use to improve the quality of our bugs, decrease our triaging time and help Release Management ship better quality software is called '''BugBot''' (formerly known as Autonag).
Triaging and prioritizing these bugs are an essential part of our development process and we automate part of this process so as to increase our development turn around and improve the quality of our bugs metadata. The set of tools we use to improve the quality of our bugs, decrease our triaging time and help Release Management ship better quality software is called '''BugBot''' (formerly known as Autonag).


Initially created as an alerting system (by email) to our triagers, BugBot rules now also make changes to our bugs metadata on Bugzilla so as to fix inconsistencies.
Initially created as an alerting system (by email) to our triagers, BugBot rules now also make changes to our bugs metadata on Bugzilla so as to fix inconsistencies.
Rules that change automatically some data in Bugzilla (change a priority, needinfo somebody, close a bug…) are called "Rules with Autofix".
Rules that do not change data but have other results such as generate a report or send an email are called "Rules without Autofix".


If you want the bot to not make changes to a specific bug, add <code>[no-nag]</code> to its ''whiteboard'' field.
If you want the bot to not make changes to a specific bug, add <code>[no-nag]</code> to its ''whiteboard'' field.


= Rules =
= Active Rules =
== With autofix ==
{{BugBotRule
{{BugBotRule
  | Rule ID  = 163
   | Rule name = Variant Expiration
   | Rule name = Variant Expiration
   | Purpose  = Follow up on variants that need to be dropped or extended
   | Purpose  = Follow up on variants that need to be dropped or extended
Line 29: Line 25:
   | Action    = Close the bug as "INVALID" and move it to the "Invalid Bugs" product
   | Action    = Close the bug as "INVALID" and move it to the "Invalid Bugs" product
   | Source    = spambug.py  
   | Source    = spambug.py  
}}
{{BugBotRule
  | Rule name = File bugs for new actionable crashes
  | Purpose  = Automate discovering actionable crash reports to speed up fixes, reduce user impact, and save engineering time.
  | Action    = Open a crash bug with the relevant information
  | Source    = file_crash_bug.py
}}
}}
{{BugBotRule
{{BugBotRule
Line 59: Line 61:
   | Action    = Set the 'Has STR' field to be 'yes'  
   | Action    = Set the 'Has STR' field to be 'yes'  
   | Source    = has_str_no_hasstr.py  
   | Source    = has_str_no_hasstr.py  
}}
{{BugBotRule
  | Rule name = Bugs with STR and no regression range
  | Purpose  = Compleat missing metadata
  | Action    = Needinfo the bug creator to find the regression range
  | Source    = has_str_no_range.py
}}
}}
{{BugBotRule
{{BugBotRule
Line 174: Line 170:
}}
}}
{{BugBotRule
{{BugBotRule
   | Rule name = Increase severity of bugs tracked by Release Managers
   | Rule name = Needinfo triage owner to set severity on bugs
   | Purpose  = Fix inconsistency in metadata
   | Purpose  = Every defect should have a severity set. Also bugs with no severity set are harder to prioritize for Release Managers with regards to the release (see [https://firefox-source-docs.mozilla.org/bug-mgmt/policies/triage-bugzilla.html#what-do-you-triage what-do-you-triage])
   | Action    = If a bug is tracked for an upcoming release but it's severity field is low, the severity is increased
   | Action    = The triage owner is needinfoed in Bugzilla to set a severity on bugs
  | Example  = 1538966
   | Source    = workflow/no_severity_ni.py
   | Source    = tracked_bad_severity.py
  | Note      = Dropped in favor of [[BugBot#tracked_attention.py|Tracked bugs that need attention]]
}}
}}
{{BugBotRule
{{BugBotRule
   | Rule name = Nag triage owner to set severity on bugs
   | Rule name = Nag triage owner to set severity on bugs
   | Purpose  = Every defect should have a severity set. Also bugs with no severity set are harder to prioritize for Release Managers with regards to the release (see [https://firefox-source-docs.mozilla.org/bug-mgmt/policies/triage-bugzilla.html#what-do-you-triage what-do-you-triage])
   | Purpose  = Every defect should have a severity set. Also bugs with no severity set are harder to prioritize for Release Managers with regards to the release (see [https://firefox-source-docs.mozilla.org/bug-mgmt/policies/triage-bugzilla.html#what-do-you-triage what-do-you-triage])
   | Action    = The triage owner is needinfoed in Bugzilla or nagged via email to set a severity on bugs
   | Action    = The triage owner is nagged via email to set a severity on bugs
  | Example  = 1527818
   | Source    = workflow/no_severity_nag.py
   | Source    = workflow/no_severity.py
}}
}}
{{BugBotRule
{{BugBotRule
Line 204: Line 197:
{{BugBotRule
{{BugBotRule
   | Rule name = Change the priority from P2 to P1 on assigned bug the merge day
   | Rule name = Change the priority from P2 to P1 on assigned bug the merge day
   | Purpose  = Since P2 means that the bug should be fixed for the next next release (see [https://firefox-source-docs.mozilla.org/bug-mgmt/policies/triage-bugzilla.html#what-do-you-triage what-do-you-triage]), when we are the merge day then this bug automatically becomes a P1.
   | Purpose  = Since P2 means that the bug should be fixed for the next release (see [https://firefox-source-docs.mozilla.org/bug-mgmt/policies/triage-bugzilla.html#what-do-you-triage what-do-you-triage]), when we are the merge day then this bug automatically becomes a P1.
   | Action    = Update the priority to P1 and add a comment to explain.
   | Action    = Update the priority to P1 and add a comment to explain.
   | Example  =  
   | Example  =  
Line 212: Line 205:
   | Rule name = Patch not landed  
   | Rule name = Patch not landed  
   | Purpose  = Identify bugs with an unlanded r+ patch. Maybe the patch is now obsolete or the bug needs to have a sheriff land the code with the <code>checkin-needed</code> keyword set.
   | Purpose  = Identify bugs with an unlanded r+ patch. Maybe the patch is now obsolete or the bug needs to have a sheriff land the code with the <code>checkin-needed</code> keyword set.
   | Action    = The bug assignee is needinfoed in Bugzilla to ask her/him to have look
   | Action    = The bug assignee is needinfoed in Bugzilla to ask her/him to have a look
   | Example  = 1496844
   | Example  = 1496844
   | Source    = not_landed.py
   | Source    = not_landed.py
Line 243: Line 236:
   | Example  = 1620434
   | Example  = 1620434
   | Source    = uplift_beta.py
   | Source    = uplift_beta.py
}}
{{BugBotRule
  | Rule name = Fuzzing bisection without regressed_by
  | Purpose  = Identify bugs which contain a bisection made by fuzzing tools and an empty regressed_by, probably people forgot to set the field.
  | Action    = The bug assignee is needinfoed to ask to fill regressed_by when it's possible.
  | Example  = 1683535
  | Source    = fuzzing_bisection_without_regressed_by.py
  | Note      = Replaced with [[BugBot#bisection_without_regressed_by.py|Bisection without regressed_by]]
}}
}}
{{BugBotRule
{{BugBotRule
Line 274: Line 259:
}}
}}
{{BugBotRule
{{BugBotRule
   | Rule name = Bugs with top-crash signatures
   | Rule name = Highlight topcrash bugs
   | Purpose  = Identify bugs that are missing topcrash or topcrash-startup keywords
   | Purpose  = Identify topcrash bugs that are missing topcrash keywords or have low severity
   | Action    = Add the missing keyword and needinfo to suggest increasing severity in case of a low severity
   | Action    = Add the missing keywords and needinfo to suggest increasing severity in case of a low severity
   | Source    = topcrash_add_keyword.py  
   | Source    = topcrash_highlight.py
}}
{{BugBotRule
  | Rule name = Topcrash notify
  | Purpose  = Identify topcrash bugs with needinfo without recent activity
  | Action    = Notify managers and release managers
  | Source    = topcrash_notify.py  
}}
}}
{{BugBotRule
{{BugBotRule
Line 285: Line 276:
   | Source    = telemetry_expiry_tracking_autoapproval.py  
   | Source    = telemetry_expiry_tracking_autoapproval.py  
}}
}}
== Without autofix ==
{{BugBotRule
{{BugBotRule
   | Rule name = Feature vs regression
   | Rule name = Feature vs regression
Line 310: Line 297:
   | Rule name = Alert for lack of feedback in a bug
   | Rule name = Alert for lack of feedback in a bug
   | Purpose  = Increase reaction time on bugs prioritized by upper management or release managers
   | Purpose  = Increase reaction time on bugs prioritized by upper management or release managers
   | Action    = If a bug as an unanswered NeedInfo request from a release manager or a director, send a warning email
   | Action    = If a bug has an unanswered needinfo request from a release manager or a director, send a warning email
   | Source    = ni_from_manager.py  
   | Source    = ni_from_manager.py  
}}
}}
Line 321: Line 308:
{{BugBotRule
{{BugBotRule
   | Rule name = Reporter not answering to Needinfo request
   | Rule name = Reporter not answering to Needinfo request
   | Purpose  = identify bugs stalled because we need more information fron the reporter to reproduce it
   | Purpose  = Identify bugs stalled because we need more information from the reporter to reproduce it
   | Source    = reporter_with_ni.py
   | Source    = reporter_with_ni.py
}}
{{BugBotRule
  | Rule name = Top crashers with low severity
  | Purpose  = Consistency and help getting traction on top-crash bugs
  | Action    = Needinfo the assignee or the triage owner if not assigned yet
  | Example  = 1471692
  | Source    = topcrash_bad_severity.py
}}
}}
{{BugBotRule
{{BugBotRule
Line 369: Line 349:
{{BugBotRule
{{BugBotRule
   | Rule name = New user with a Needinfo request
   | Rule name = New user with a Needinfo request
   | Purpose  = Help identify potentially unactionnable bugs per lack of information
   | Purpose  = Help identify potentially unactionable bugs per lack of information
   | Action    = Send an email
   | Action    = Send an email
   | Source    = newbie_with_ni.py
   | Source    = newbie_with_ni.py
Line 386: Line 366:
}}
}}
{{BugBotRule
{{BugBotRule
   | Rule name = Regression bugs where regressor author is not involved
   | Rule name = Regression bugs where the regressor author is not involved
   | Purpose  = Highlight regressions to people who caused them
   | Purpose  = Highlight regressions to people who caused them
   | Action    = Needinfo the assignee of the bug that caused the regression
   | Action    = Needinfo the assignee of the bug that caused the regression
Line 396: Line 376:
   | Action    = Needinfo to propose increasing the severity
   | Action    = Needinfo to propose increasing the severity
   | Source    = severity_high_security.py
   | Source    = severity_high_security.py
}}
{{BugBotRule
  | Rule name = Low severity bugs with tracking status
  | Purpose  = Suggest increasing the severity for bugs that are marked as blocking or are tracked for nightly, beta, or release
  | Action    = Needinfo the assignee or the triage owner if not assigned yet
  | Source    = severity_tracked.py
  | Note      = Dropped in favor of [[BugBot#tracked_attention.py|Tracked bugs that need attention]]
}}
}}
{{BugBotRule
{{BugBotRule
Line 488: Line 461:
   | Source    = moved_to_performance.py  
   | Source    = moved_to_performance.py  
}}
}}
{{BugBotRule
  | Rule name = Uh-hide duplicate security bugs
  | Purpose  = Publish security bugs that are already fixed and safe to be public.
  | Action    = Send emails to people in the security team to highlight security bugs which are duplicates of already-public bugs.
  | Source    = security_unhide_dups.py
}}
{{BugBotRule
  | Rule name = Label WebCompat platform bugs
  | Purpose  = Ensure core bugs blocking webcompat knowledge base entries have webcompat:platform-bug keyword.
  | Action    = Add webcompat:platform-bug keyword where it's missing
  | Source    = webcompat_platform_without_keyword.py
}}
{{BugBotRule
  | Rule name = Bugs with the [webcompat:sightline] whiteboard tag updated
  | Purpose  = Ensure webcompat bugs affecting a sightline top 1000 site have the appropriate keyword set
  | Action    = Add [webcompat:sightline] whiteboard tag where it's missing, or remove it when it shouldn't be set
  | Source    = webcompat_sightline.py
}}
{{BugBotRule
  | Rule name = Inactive performance regressions
  | Purpose  = Ensure progress continues on resolving performance regressions.
  | Action    = Needinfo author of regressor after a period of inactivity.
  | Source    = perfalert_inactive_regression.py
}}
{{BugBotRule
  | Rule name = Performance regression resolution monitoring
  | Purpose  = Ensure proper resolutions are provided for performance alerts, and request resolution reasoning if needed.
  | Action    = Needinfo individual who resolved alert when resolution reasoning is not provided, and provide summary emails of resolution changes.
  | Source    = perfalert_resolved_regression.py
}}
{{BugBotRule
  | Rule name = Inactive telemetry alerts
  | Purpose  = Ensure progress continues on resolving telemetry alerts.
  | Action    = Needinfo telemetry probe owner after a period of inactivity.
  | Source    = telemetryalert_inactive_regression.py
}}
{{BugBotRule
  | Rule name = web-features links
  | Purpose  = Ensure bugs marked with a web feature have see-also links to the relevant feature.
  | Action    = Add see-also links to bugs with `web-feature: <name>` in the user story.
  | Source    = web_platform_features.py
}}
= Removed Rules =
{{BugBotRule
  | Rule name = Fuzzing bisection without regressed_by
  | Purpose  = Identify bugs which contain a bisection made by fuzzing tools and an empty regressed_by, probably people forgot to set the field.
  | Action    = The bug assignee is needinfoed to ask to fill regressed_by when it's possible.
  | Example  = 1683535
  | Source    = fuzzing_bisection_without_regressed_by.py
  | Removed  = yes
  | Note      = Replaced with [[BugBot#bisection_without_regressed_by.py|Bisection without regressed_by]]
}}
{{BugBotRule
  | Rule name = Bugs with top-crash signatures
  | Purpose  = Identify bugs that are missing topcrash or topcrash-startup keywords
  | Action    = Add the missing keyword and needinfo to suggest increasing severity in case of a low severity
  | Source    = topcrash_add_keyword.py
  | Removed  = yes
  | Note      = Replaced with [[BugBot#topcrash_highlight.py|Highlight topcrash bugs]]
}}
{{BugBotRule
  | Rule name = Top crashers with low severity
  | Purpose  = Consistency and help getting traction on top-crash bugs
  | Action    = Needinfo the assignee or the triage owner if not assigned yet
  | Example  = 1471692
  | Source    = topcrash_bad_severity.py
  | Removed  = yes
  | Note      = Replaced with [[BugBot#topcrash_highlight.py|Highlight topcrash bugs]]
}}
{{BugBotRule
  | Rule name = Low severity bugs with tracking status
  | Purpose  = Suggest increasing the severity for bugs that are marked as blocking or are tracked for nightly, beta, or release
  | Action    = Needinfo the assignee or the triage owner if not assigned yet
  | Source    = severity_tracked.py
  | Removed  = yes
  | Note      = Dropped in favor of [[BugBot#tracked_attention.py|Tracked bugs that need attention]]
}}
{{BugBotRule
  | Rule name = Increase severity of bugs tracked by Release Managers
  | Purpose  = Fix inconsistency in metadata
  | Action    = If a bug is tracked for an upcoming release but it's severity field is low, the severity is increased
  | Example  = 1538966
  | Source    = tracked_bad_severity.py
  | Removed  = yes
  | Note      = Dropped in favor of [[BugBot#tracked_attention.py|Tracked bugs that need attention]]
}}
{{BugBotRule
  | Rule name = Bugs with STR and no regression range
  | Purpose  = Compleat missing metadata
  | Action    = Needinfo the bug creator to find the regression range
  | Source    = has_str_no_range.py
  | Removed  = yes
  | Note      = Removed on 2024-02-13
}}
{{BugBotRule
  | Rule name = Nag triage owner to set severity on bugs
  | Purpose  = Every defect should have a severity set. Also bugs with no severity set are harder to prioritize for Release Managers with regards to the release (see [https://firefox-source-docs.mozilla.org/bug-mgmt/policies/triage-bugzilla.html#what-do-you-triage what-do-you-triage])
  | Action    = The triage owner is needinfoed in Bugzilla or nagged via email to set a severity on bugs
  | Source    = workflow/no_severity.py
  | Removed  = yes
  | Note      = Split into two rules: [[BugBot#Needinfo_triage_owner_to_set_severity_on_bugs|Needinfo triage owner to set severity on bugs]] and [[BugBot#Nag_triage_owner_to_set_severity_on_bugs|Nag triage owner to set severity on bugs]]
}}
__TOC__
97

edits