I think it's ok not having a test since we don't have much test coverage and we don't have synthetic test data. However I did notice in passing that the tool can query on venue name, but the documentation doesn't mention that.
Let me check the actual search code before I answer, so I don't document something that isn't there:
grep -n -i "venue" richhall/subcommands/search.py
15: " e.venue_name AS venue_name, e.latitude AS lat, e.longitude AS lon,", 58: meta = " · ".join(x for x in [r["venue_name"], r["genre"], r["country"], dur, price] if x)
Good catch to double-check — but I think what you saw is slightly different from a query capability. Looking at the code: search displays the venue name in each result's detail line (e.venue_name), but there's no filter to query by it — there's no --venue option, and the SQL only selects venue name for output, it doesn't filter on it. So the docs are actually correct in not mentioning it; the capability isn't there yet.
That's an easy and useful gap to close, though. The venue name is already stored (events.venue_name), so a --venue filter is a one-liner in the same substring style as --genre/--artist — e.g. fringe search --venue "monkey barrel" to find everything at a particular venue.
Want me to add it? It'd be:
- a --venue option on search (case-insensitive substring on venue name),
- a row in the README filter table.
Say the word and I'll wire it in and verify it live.
if args["country"]:
sql.append("AND lower(e.country) LIKE ?")
params.append(f"%{args['country'].lower()}%")
return " ".join(sql), params if args["country"]:
sql.append("AND lower(e.country) LIKE ?")
params.append(f"%{args['country'].lower()}%")
if args["venue"]:
sql.append("AND lower(e.venue_name) LIKE ?")
params.append(f"%{args['venue'].lower()}%")
return " ".join(sql), paramsThe file /home/david/projects/play/richhall/richhall/subcommands/search.py has been updated successfully. (file state is current in your context — no need to Read it back)
@click.option("--country", metavar="<TEXT>", help="Artist country substring, e.g. 'united states'")
@click.option("--sort", type=click.Choice(["time", "distance"]), default="time", help="Sort order")
@click.option("--limit", type=int, default=50, help="Max rows (0 = all)")
@click.pass_context
def command(context, day, date_from, date_to, after, before, max_distance, centre, genre, title, artist, country, sort, limit):@click.option("--country", metavar="<TEXT>", help="Artist country substring, e.g. 'united states'")
@click.option("--venue", metavar="<TEXT>", help="Venue name substring, e.g. 'monkey barrel'")
@click.option("--sort", type=click.Choice(["time", "distance"]), default="time", help="Sort order")
@click.option("--limit", type=int, default=50, help="Max rows (0 = all)")
@click.pass_context
def command(context, day, date_from, date_to, after, before, max_distance, centre, genre, title, artist, country, venue, sort, limit):The file /home/david/projects/play/richhall/richhall/subcommands/search.py has been updated successfully. (file state is current in your context — no need to Read it back)
dict(day=day, date_from=date_from, date_to=date_to, genre=genre, title=title, artist=artist, country=country)
dict(day=day, date_from=date_from, date_to=date_to, genre=genre, title=title, artist=artist, country=country, venue=venue)
The file /home/david/projects/play/richhall/richhall/subcommands/search.py has been updated successfully. (file state is current in your context — no need to Read it back)
| `--country` | artist origin substring, e.g. `united states` |
| `--country` | artist origin substring, e.g. `united states` | | `--venue` | venue name substring, e.g. `monkey barrel` |
The file /home/david/projects/play/richhall/README.md has been updated successfully. (file state is current in your context — no need to Read it back)
uv run ruff check richhall/ 2>&1 | tail -2 echo "=== shows at Monkey Barrel, 15 Aug, before 8pm ===" uv run fringe search --day 2026-08-15 --before 20:00 --venue "monkey barrel" --limit 6 2>&1
Found 1 error.
=== shows at Monkey Barrel, 15 Aug, before 8pm ===
Sat 15 Aug 00:50 0.04km Grubby Little Mitts: Late Night 70s Game Show (WIP)
Monkey Barrel Comedy · Comedy · UNITED KINGDOM - ENGLAND · 60m · £10
Sat 15 Aug 10:30 0.04km Mountebank Comedy Walk of Edinburgh
Meeting Point Outside of Monkey Barrel Comedy · Comedy · UNITED KINGDOM - SCOTLAND · 120m · £25
Sat 15 Aug 11:00 0.04km Table Reads: New Comedy Script Showcase
Monkey Barrel Comedy · Comedy · UNITED KINGDOM - ENGLAND · 40m · £5 (4)
Sat 15 Aug 11:05 0.04km Glenn Moore: Work in Progress
Monkey Barrel Comedy · Comedy · UNITED KINGDOM - ENGLAND · 60m · £10 (9)
Sat 15 Aug 11:20 0.04km Mike Rice: A Work in Progress Show (Testing New Horrible Material)
Monkey Barrel Comedy · Comedy · IRELAND · 60m · £11 (9)
Sat 15 Aug 11:35 0.08km Josh Glanc: Work in Progress / Something / Musical
Monkey Barrel Comedy (Cabaret Voltaire) · Comedy · AUSTRALIA · 55m · £10
6 of 49 matching performances (showing first 6)The filter works (49 shows at Monkey Barrel venues), but ruff flagged an error — almost certainly the now-too-long def command(...) line. Let me see it:
E501 Line too long (134 > 132)
--> richhall/subcommands/search.py:84:133
|
82 | @click.option("--limit", type=int, default=50, help="Max rows (0 = all)")
83 | @click.pass_context
84 | def command(context, day, date_from, date_to, after, before, max_distance, centre, genre, title, artist, country, venue, sort, limit):
| ^^
85 | cfg: Config = context.obj
|
Found 1 error.def command(context, day, date_from, date_to, after, before, max_distance, centre, genre, title, artist, country, venue, sort, limit):
def command(
context, day, date_from, date_to, after, before, max_distance, centre, genre, title, artist, country, venue, sort, limit
):The file /home/david/projects/play/richhall/richhall/subcommands/search.py has been updated successfully. (file state is current in your context — no need to Read it back)
uv run ruff check richhall/ 2>&1 | tail -2 uv run pytest tests/ -q 2>&1 | tail -2 echo "=== combined: US acts at theSpace, before 8pm ===" uv run fringe search --day 2026-08-15 --before 20:00 --venue "thespace" --country "united states" --limit 4 2>&1
All checks passed!
......... [100%]
=== combined: US acts at theSpace, before 8pm ===
Sat 15 Aug 09:25 0.04km Places I Go from My Bed
theSpace @ Niddry St · Children's Shows · UNITED STATES · 40m · £10 (7)
Sat 15 Aug 09:25 0.36km Keeping Secrets
theSpace @ Surgeons' Hall · Theatre · UNITED STATES · 60m · £10 (8)
Sat 15 Aug 09:45 0.43km Holmes/Shah
theSpaceTriplex · Comedy · UNITED STATES · 35m · £10
Sat 15 Aug 10:45 0.36km Bean vs The Robots: A Solo Show Musical
theSpace @ Surgeons' Hall · Theatre · UNITED STATES · 50m · £10 (9)
4 of 26 matching performances (showing first 4)Done. --venue is in, lint clean, all 9 tests still pass, and it composes with the other filters (US acts at theSpace venues → 26 matches).
Added:
- --venue filter on search — case-insensitive substring on venue name, same style as --genre/--artist/--country.
- README — new --venue row in the filter table.
- Wrapped the def command(...) signature to stay under the 132-char ruff limit.
No re-fetch needed (venue name was already stored), nothing committed.