Read big boards within the agents' reach: countries and remote from the enabled agents, Europe for favourites, filtered at the source by six hosts

app/jobs/reach.py derives each board's reach once per pull and the pull hands it to the runner through the batch payload. SmartRecruiters, Eightfold and SuccessFactors filter one country a request, Phenom a list, Workday and Oracle by host ids from facets. Remote beside countries is a series of its own, since two facets intersect.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
WolfandClaude Opus 5.5 committed 2026-09-30 09:55:18 +02:00
1 parent 3adafd8950
commit 3462a4abe7
17 files changed
+1324 -116

No files matched your search

+13 -3
View File
@@ -3,16 +3,22 @@ with a stated total. The identifier is case-sensitive (`BoschGroup`).
Written from one real board on 2026-09-23; jobhunt-hq did not read
SmartRecruiters.
A country is filtered on the server, `?country=dk`, one a request
(`Filters(country="one")`): Bosch's DE, SE and DK summed to what the app held
(review, 2026-09-29), and DK answered 2 of 4,830 on 2026-09-30. The API
ignores a remote parameter, so remote is not filtered.
"""
from __future__ import annotations
import json
import logging
import re
from collections.abc import Callable
from typing import Any
from ._contract import Ask, Fields, Place, Reads
from ._contract import Ask, Fields, Filters, Place, Reads
from ._shared import Get, Page, Row, only, parse_dt, path_slug_ok
log = logging.getLogger(__name__)
@@ -27,7 +33,7 @@ PATTERNS = (
#: An unknown identifier answers an empty list, which is `empty="suspect"`.
READS = Reads(
scope="board", listing="paged", page_size=100, text="none", complete="stated",
places="one", empty="suspect",
places="one", empty="suspect", filters=Filters(country="one"),
fields=Fields(posted="trusted", remote="stated", country="stated", seniority="stated",
employment="stated"),
robots="api: no robots.txt check needed (public board API), 2026-09-30",
@@ -73,9 +79,13 @@ def probe_ok(body: bytes) -> bool:
def page(get: Get, slug: str, cursor: Any, ask: Ask = Ask()) -> Page:
"""One page, in the one country `ask` names, which the API takes in lower
case."""
offset = int(cursor or 0)
country = ask.countries[0].lower() if ask.countries else ""
where = f"&country={country}" if re.fullmatch(r"[a-z]{2}", country) else ""
data = json.loads(get(f"https://{_API}/v1/companies/{slug}/postings"
f"?offset={offset}&limit={PAGE_SIZE}"))
f"?offset={offset}&limit={PAGE_SIZE}{where}"))
content = data.get("content") or []
return data, content, data.get("totalFound"), offset + len(content) if content else None