From 1848816e30922d4e524cc3f010ad6d4b1f258811 Mon Sep 17 00:00:00 2001 From: Kumaresan Date: Sun, 13 Sep 2026 12:28:47 +0530 Subject: [PATCH] Escape the dot in the .NET detection regex used to label issues The issue labeler tested bodies and titles with /.net/i. The unescaped dot is a regex wildcard, so any character followed by "net" matched: "internet", "network", "AF_INET", "Mainnet". Python-only issues were labeled .NET as a result, and the label title prefix workflow then rewrote their titles with a ".Net:" prefix. Escaping the dot makes the check match a literal ".net" (".NET", "ASP.NET"), which is what the comment above it describes. The "dotnet", "C#" and "csharp" checks are unchanged, so genuine .NET issues that spell it that way are still labeled. Replaying both regexes over the 98 currently open issues changes the outcome for 6 of them; every change removes a false .NET label and none removes a true one. Examples still carrying the wrong label: #14412 ("internet") and #13974 ("Mainnet"). --- .github/workflows/label-issues.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/label-issues.yml b/.github/workflows/label-issues.yml index 30681c79005f..523f09fc0343 100644 --- a/.github/workflows/label-issues.yml +++ b/.github/workflows/label-issues.yml @@ -62,7 +62,7 @@ jobs: } // Check if the body or the title contains the words 'dotnet', '.net', 'c#' or 'csharp' (case-insensitive) - if ((body != null && body.match(/.net/i)) || (title != null && title.match(/.net/i)) || + if ((body != null && body.match(/\.net/i)) || (title != null && title.match(/\.net/i)) || (body != null && body.match(/dotnet/i)) || (title != null && title.match(/dotnet/i)) || (body != null && body.match(/C#/i)) || (title != null && title.match(/C#/i)) || (body != null && body.match(/csharp/i)) || (title != null && title.match(/csharp/i))) {