gerrit: linking to bugs is broken

#319
Opened by tazjin at 2023-10-11T21·02+00

The matching for linking to e.g. b/123 has stopped working in Gerrit.

  1. It seems like the regexes from our config:

          # Auto-link panettone bug links
          commentlink.panettone = {
            match = "b/(\\\\d+)";
            html = "<a href=\"https://b.tvl.fyi/issues/$1\">b/$1</a>";
          };
    
          # Auto-link other CLs
          commentlink.gerrit = {
            match = "cl/(\\\\d+)";
            html = "<a href=\"https://cl.tvl.fyi/$1\">cl/$1</a>";
          };
    

    now appear verbatim in the Gerrit config:

    [commentlink "gerrit"]
            html = "<a href=\"https://cl.tvl.fyi/$1\">cl/$1</a>"
            match = "cl/(\\\\d+)"
    
    [commentlink "panettone"]
            html = "<a href=\"https://b.tvl.fyi/issues/$1\">b/$1</a>"
            match = "b/(\\\\d+)"
    

    This looks to me like we lost a layer of escaping somewhere?

    tazjin at 2023-11-05T09·24+00

  2. This has been fixed in cl/9952

    flokli at 2023-11-15T22·11+00

  3. flokli closed this issue at 2023-11-15T22·11+00