id: labelAdded.validationDefenderError name: GitOps.PullRequestIssueManagement description: Handlers when "Validation-Defender-Error" label is added owner: resource: repository disabled: false where: configuration: resourceManagementConfiguration: eventResponderTasks: - description: >- When the label "Validation-Defender-Error" is added to a pull request * Add the PR specific reply notifying the issue author * Assign to the Author * Label with Needs-Author-Feedback * Remove the Needs-Attention Label if: - payloadType: Pull_Request - labelAdded: label: Validation-Defender-Error then: - addReply: reply: >- Hello ${issueAuthor}, The package manager bot was blocked from installing one of the installers listed in the url field, and cannot continue. The application included in this pull request failed to pass the [Installers Scan](https://docs.microsoft.com/en-us/windows/package-manager/package/winget-validation) test. This test is designed to ensure that the application installs on all environments without warnings. Please check to ensure the installer URL is correct and update the URL and the Hash if a change is made. If the package is mistakenly flagged as malware, you can [submit the installer(s) to the Microsoft Defender team for analysis](https://www.microsoft.com/en-us/wdsi/filesubmission). For more details on this error, see [Defender errors](https://learn.microsoft.com/en-us/windows/package-manager/package/repository#error-labels). ###### Template: msftbot/validationError/installers/validationDefender - assignTo: author: True - addLabel: label: Needs-Author-Feedback - removeLabel: label: Needs-Attention # This will automatically assign the ICM Users - addLabel: label: Validation-Guide # The policy service should trigger even when the label was added by the policy service triggerOnOwnActions: true onFailure: onSuccess: