Skip to content

cannot match .Query.Keywords with re_replace filter #877

Description

@spanktastic2120

Is there an existing issue for this?

  • I have searched the existing issues

Current Behavior

I'm attempting to insert the current year into the title of a result as a workaround for Radarr refusing to support sports.

My indexer definition looks like this:

title-0:
  selector: div.tt-name > a[href^="/"]
  filters:
    - name: strdump
title-1:
  text: "{{ .Result.title-0 }}"
  filters:
    - name: re_replace
      args: ["(?i)({{.Query.Keywords}})","{{ .Query.Keywords }} ({{ .Today.Year }})"]
    - name: strdump
title-2:
  text: "{{ .Result.title-1 }}"
  filters:
    - name: re_replace
      args: ["WWE WrestleMania 42 Saturday","{{ .Query.Keywords }} ({{ .Today.Year }})"]
    - name: strdump
title:
  text: "{{ .Result.title-2 }}"

As you will see in the logs, title-0 and title-1 are identical, as re_replace fails to match. But on title-2 the match is successful using literal text instead of a variable.

I cannot tell if re_replace does not support variables in the pattern or if theres some whitespace mismatch between what .Query.Keywords supplies to re_replace and what it prints using strdump.

Expected Behavior

I expect re_replace to support variables in either argument.

Steps To Reproduce

  1. Edit any indexer definition to have a re_replace filter with .Query.Keywords as the pattern
  2. Perform a search on that indexer

Environment

- OS: Ubuntu 22.04.5 LTS
- Prowlarr: 2.3.5.5327-ls143 by linuxserver.io
- Docker Install: yes
- Using Reverse Proxy: no
- Browser: any

What branch are you running?

Master

Trace Logs? Not Optional

2026-04-23 21:04:29.5|Trace|Http|Req: 14 [GET] /api/v1/search?query=WWE%20WrestleMania%2042%20Saturday&indexerIds=49&type=search&limit=100&offset=0 (from 192.168.1.5 Mozilla/5.0 (X11; Linux x86_64; rv:148.0) Gecko/20100101 Firefox/148.0)
2026-04-23 21:04:29.7|Info|ReleaseSearchService|Searching indexer(s): [TorrentDownload - Sports] for Term: [WWE WrestleMania 42 Saturday], Offset: 0, Limit: 100, Categories: []
2026-04-23 21:04:29.7|Trace|Cardigann|Getting Basic search
2026-04-23 21:04:29.7|Trace|ConfigService|Using default config value for 'logindexerresponse' defaultValue:'False'
2026-04-23 21:04:29.7|Trace|Cardigann|Populating config vars
2026-04-23 21:04:29.7|Debug|Cardigann|Adding request for TorrentDownload - Sports: https://www.torrentdownload.info/searchd?q=WWE%20WrestleMania%2042%20Saturday
2026-04-23 21:04:29.7|Debug|Cardigann|Downloading Feed https://www.torrentdownload.info/searchd?q=WWE%20WrestleMania%2042%20Saturday
2026-04-23 21:04:29.7|Trace|ConfigService|Using default config value for 'logindexerresponse' defaultValue:'False'
2026-04-23 21:04:29.7|Trace|IndexerHttpClient|Req: [GET] https://www.torrentdownload.info/searchd?q=WWE%20WrestleMania%2042%20Saturday
2026-04-23 21:04:29.7|Trace|ConfigService|Using default config value for 'proxyenabled' defaultValue:'False'
2026-04-23 21:04:30.0|Trace|IndexerHttpClient|Res: HTTP/2.0 [GET] https://www.torrentdownload.info/searchd?q=WWE%20WrestleMania%2042%20Saturday: 200.OK (13366 bytes) (281 ms)
2026-04-23 21:04:30.0|Trace|Cardigann|Cardigann (torrentdownload-sports): Parsing response
2026-04-23 21:04:30.0|Trace|ConfigService|Using default config value for 'logindexerresponse' defaultValue:'False'
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE WrestleMania 42 Saturday NF iNT 720p WEBRip h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE WrestleMania 42 Saturday NF iNT 720p WEBRip h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE WrestleMania 42 Saturday (2026) NF iNT 720p WEBRip h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE WrestleMania 42 Saturday 1080p WEB h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE WrestleMania 42 Saturday 1080p WEB h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE WrestleMania 42 Saturday (2026) 1080p WEB h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to WrestleMania 42 Saturday 1080p WEB h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to WrestleMania 42 Saturday 1080p WEB h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to WrestleMania 42 Saturday 1080p WEB h264 HEEL [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Wrestlemania 42 Saturday 1080p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Wrestlemania 42 Saturday 1080p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Wrestlemania 42 Saturday 1080p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Wrestlemania 42 Saturday 720p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Wrestlemania 42 Saturday 720p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Wrestlemania 42 Saturday 720p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to Wrestlemania 42 Saturday 1080p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to Wrestlemania 42 Saturday 1080p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to Wrestlemania 42 Saturday 1080p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to Wrestlemania 42 Saturday 720p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to Wrestlemania 42 Saturday 720p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Debug|Cardigann|CardigannIndexer (torrentdownload-sports): strdump: WWE Countdown to Wrestlemania 42 Saturday 720p WEB H264 XWT [TJET]
2026-04-23 21:04:30.0|Trace|Cardigann|Cardigann (torrentdownload-sports): Got 7 releases
2026-04-23 21:04:30.0|Trace|EventAggregator|Publishing IndexerQueryEvent
2026-04-23 21:04:30.0|Trace|EventAggregator|IndexerQueryEvent -> HistoryService
2026-04-23 21:04:30.0|Trace|EventAggregator|IndexerQueryEvent <- HistoryService
2026-04-23 21:04:30.0|Debug|ReleaseSearchService|Total of 7 reports were found for Term: [WWE WrestleMania 42 Saturday], Offset: 0, Limit: 100, Categories: [] from 1 indexer(s)
2026-04-23 21:04:30.1|Trace|Http|Res: 14 [GET] /api/v1/search?query=WWE%20WrestleMania%2042%20Saturday&indexerIds=49&type=search&limit=100&offset=0: 200.OK (531 ms)
2026-04-23 21:04:30.1|Debug|Api|[GET] /api/v1/search?query=WWE%20WrestleMania%2042%20Saturday&indexerIds=49&type=search&limit=100&offset=0: 200.OK (531 ms)

Trace Logs have been provided as applicable. Reports will be closed if the required logs are not provided.

  • I have read and followed the steps in the wiki link above and provided the required trace logs - the logs contain trace - that are relevant and show this issue.

Activity

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

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions