diff --git a/.github/workflows/auto_fix_from_feedback.yml b/.github/workflows/auto_fix_from_feedback.yml index d6dbda0c..f40ba700 100644 --- a/.github/workflows/auto_fix_from_feedback.yml +++ b/.github/workflows/auto_fix_from_feedback.yml @@ -25,6 +25,8 @@ on: type: string permissions: + # Claude Code Action が GitHub App 認証に使う OIDC トークンを取得するために必要。 + id-token: write contents: write # prepare がスタブ issue を GITHUB_TOKEN で取得する。permissions を書いた # 時点で挙げなかった権限は none になるので、これを省くとそこで止まる。 diff --git a/AGENTS.md b/AGENTS.md index 24b0e9f5..fbe5079c 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -57,6 +57,9 @@ The Worker is the workspace root package. `stationapi`, `preprocessor`, and `dat - **`8!connections.csv` holds hand corrections to track lengths.** `preprocessor` computes the length between every pair of adjacent rail stations from N02; a row here (`station_cd1`, `station_cd2`, `distance` in meters, either direction) overrides the computed value. Use it only where N02's geometry or a station's coordinates make the computed value wrong, and cite the source of the corrected value in the pull request. - `data_validator` currently verifies that `5!station_station_types.csv` references valid station and type IDs, that `8!connections.csv` references valid stations with non-negative distances and no duplicate pair, and that order-sensitive station sequences in `3!stations.csv` stay intact under `ORDER BY e_sort, station_cd` (e.g. the Toei Oedo Line's Tochomae rows, whose misordering silently drops the station from ETA estimation). Extend the validator when new cross-references or order-sensitive spots are introduced and keep the process fail-fast (panic on invalid data). +## Feedback autofix authentication +- `.github/workflows/auto_fix_from_feedback.yml` grants `id-token: write` so Claude Code Action can request a GitHub-issued OIDC token and exchange it for a GitHub App token. GitHub supplies the OIDC request environment variables; do not add them as repository secrets. This permission does not replace the existing `ANTHROPIC_API_KEY` or `ISSUES_REPO_TOKEN` requirements. + ## Testing and Quality - **Tests** – `make test` runs the unit tests for every native crate, plus `cargo test -p stationapi-worker`. The Worker only *runs* on Workers, but `src/index.rs` is a pure in-memory data structure that builds and executes natively, so its tests (including the grid-versus-full-scan differential check) run here. They need no external services. - **Type checks** – `make check` covers the native crates and the wasm32 target separately. The Worker also compiles for the host, but only runs on Workers. diff --git a/README.md b/README.md index 1b4ab33c..e6a4e54c 100644 --- a/README.md +++ b/README.md @@ -13,6 +13,7 @@ A GraphQL API that provides nearby Japanese train stations and bus stops, runnin - For automation agent and contributor workflows, see [AGENTS.md](AGENTS.md). - For contribution guidelines, see [CONTRIBUTING.md](CONTRIBUTING.md). - For system architecture and design decisions, see [docs/architecture.md](docs/architecture.md). + - For the design of the transfer route search (`connectedRoutes`, RAPTOR), see [docs/route-search.md](docs/route-search.md). - For the source-backed operating constraints used by timetable-free search, see [docs/route-service-audit.md](docs/route-service-audit.md). - For the Keio stopping-pattern audit and regression checks, see [docs/keio-stopping-pattern-audit.md](docs/keio-stopping-pattern-audit.md). diff --git a/docs/architecture.md b/docs/architecture.md index 5db3980d..6a79a275 100644 --- a/docs/architecture.md +++ b/docs/architecture.md @@ -526,6 +526,7 @@ input RouteLegInput { lineGroupId: Int! fromStationId: Int! toStationId: Int! 基準の決め方と記録の更新方法は `travel_times/README.md` にあります。 + ### 行き先の検索 (`stationsByName`) `stationsByName` に `fromStationGroupId` を指定すると、その駅から行ける駅だけに