You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit f898f1d
Browse filesBrowse the repository at this point in the historyBrowse files
Patch release. User-facing: BigQuery finops tools were 100%-broken and are
now fixed, and work in any BigQuery region (previously hardcoded to US).
Changes since v0.6.0:
- fix: BigQuery finops SQL — correct INFORMATION_SCHEMA columns + multi-region
support (#739, closes#738). `error_message`/`error_code`/`total_rows` bugs
plus `state='SUCCESS'` vs BQ's actual `'DONE'` (every completed job was
being reported as FAILED). All 5 finops modules now read the BQ
connection's `location` via a sanitised `{region}` placeholder.
- fix: make anti-slop workflow advisory instead of auto-closing legitimate
PRs (#741, closes#740).
- fix: marker-guard hotfix for isValidDatabricksHost env-fallback path.
- docs: 12 end-to-end showcase examples + `location` documented for BQ (#742).
Review: 5-persona review (CTO/PM/DE/Tech Lead/Chaos Gremlin) ran on main —
no P0s, no HOLDs. 1 P1 (silent `us` fallback compliance concern — addressed
via docs + changelog warnings; behaviour-change follow-ups tracked in #754).
2 HIGH docs-accuracy items fixed pre-tag: `location` row in drivers.md and
finops-tools.md.
Tests:
- 47 new adversarial tests in test/skill/release-v0.6.1-adversarial.test.ts
(sanitizeBqRegion injection vectors, interpolateBqRegion idempotency,
bqRegionFor registry edge cases, BIGQUERY_HISTORY_SQL column-name
regression guards for all four #739 bugs, cross-module {region} guard,
buildHistoryQuery full-pipeline incl. Snowflake/Databricks no-regression).
- 409/409 tests pass across finops + skill suites. Full altimate suite
previously green (2917/2917) on #739 merge.
- Typecheck: 5/5 pass. Marker guard: clean. Pre-release sanity: all 4 green.
Deferred: BQ finops UX + robustness follow-ups filed as #754 (surface
queried region in responses, distinguish no-location vs invalid-location,
warn at warehouse_add time, friendlier perms error, options-object
refactor, e2e silent-skip warning).
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Copy file name to clipboardExpand all lines: CHANGELOG.md
+26Lines changed: 26 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,6 +5,32 @@ All notable changes to this project will be documented in this file.
5
5
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
8
+
## [0.6.1] - 2026-04-24
9
+
10
+
### Fixed
11
+
12
+
-**BigQuery finops tools were broken — now work, in any region.**`finops_query_history` was failing 100% on BigQuery with `Unrecognized name: error_message at [11:5]`. Three separate bugs in the `INFORMATION_SCHEMA.JOBS` template: (a) `error_message` and `error_code` were read as top-level columns but they only exist inside the `error_result` struct — now reads `error_result.message` and `error_result.reason`; (b) `total_rows` is a `PARTITIONS` column, not `JOBS` — replaced with `CAST(NULL AS INT64) AS rows_produced`; (c) BigQuery's `state` returns `'DONE'`, not `'SUCCESS'`, so the summary loop was reporting every completed job as FAILED — now derives `execution_status` from `error_result IS NULL`. Every successful BQ job now reports as SUCCESS. (#739, closes #738)
13
+
-**BigQuery finops unusable outside US region.** All five finops modules (`finops_query_history`, `finops_analyze_credits`, `finops_expensive_queries`, `finops_warehouse_advice`, `finops_unused_resources`, `finops_role_grants`) hardcoded `` `region-US.INFORMATION_SCHEMA.*` ``. Now reads the BigQuery connection's configured `location` (e.g. `us`, `eu`, `us-central1`, `asia-northeast1`), sanitised via an `[a-z0-9-]` allowlist with a 64-char cap and hyphen trim. If `location` is unset the tool defaults to `us` — **set `location` explicitly on the BigQuery connection for non-US projects** or you will query the wrong region. Snowflake and Databricks paths are unchanged. (#739)
14
+
15
+
### Docs
16
+
17
+
-**New showcase page** (`docs/examples/`) with 12 end-to-end workflow demos — dbt peer review, column-level lineage diff, MS SQL → Fabric migration, Fabric platform admin, upstream schema change, NYC Taxi, Olist, Spotify, and more. (#742)
18
+
-**`location` field documented** on the BigQuery connection and called out on the finops tools page.
19
+
20
+
### Data handling
21
+
22
+
-`finops_query_history`, `finops_analyze_credits`, and `finops_warehouse_advice` read `user_email` (BigQuery), `user_name` (Snowflake / Databricks / ClickHouse), and raw `query_text` from warehouse system views. Results are returned to the agent and enter the LLM context window. No telemetry or backend upload. Review your tenant's data-handling policy before enabling finops tools in regulated (PII / PHI / PCI) environments.
23
+
-`finops_unused_resources` on BigQuery reads `INFORMATION_SCHEMA.TABLE_STORAGE`, which is an org-level view. Project-scoped service accounts typically require `bigquery.resourceAdmin` at the org to avoid a permission error.
24
+
25
+
### Internal
26
+
27
+
-`anti-slop` CI workflow is now advisory — labels + comments still fire on blocked-term hits, but the workflow no longer auto-closes PRs. Root cause: the repo's pull-request template embeds an HTML comment instructing AI to insert "PINEAPPLE", which `anti-slop.yml` also blocklists — every AI-assisted team-member PR was auto-closing within two minutes. (#741, closes #740)
28
+
- Marker-guard hotfix: the `isValidDatabricksHost` env-fallback path added in v0.6.0 straddled the post-push Marker Guard's `-U5` diff window; wrapped in an inline `altimate_change` marker pair to keep strict mode green.
29
+
30
+
### Testing
31
+
32
+
- New adversarial tests for v0.6.1 in `packages/opencode/test/skill/release-v0.6.1-adversarial.test.ts`: `sanitizeBqRegion` injection vectors (CRLF, null bytes, backticks, path traversal, Unicode homoglyphs, prototype-pollution-adjacent inputs), `interpolateBqRegion` idempotency and multi-placeholder safety, `bqRegionFor` registry edge cases, BIGQUERY_HISTORY_SQL column-name regression guards (all four #739 bugs), cross-module "every BQ template uses `{region}`" guard, and full-pipeline `buildHistoryQuery` behaviour including Snowflake / Databricks no-regression guards.
Copy file name to clipboardExpand all lines: docs/docs/data-engineering/tools/finops-tools.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,7 +35,7 @@ Summary:
35
35
36
36
**Data sources by warehouse:**
37
37
- Snowflake: `QUERY_HISTORY` function
38
-
- BigQuery: `INFORMATION_SCHEMA.JOBS`
38
+
- BigQuery: region-qualified `` `region-<location>.INFORMATION_SCHEMA.JOBS``` — the region is auto-resolved from the BigQuery connection's `location` (e.g. `us`, `eu`, `us-central1`, `asia-northeast1`). If `location` is unset the tool defaults to `us`. Set `location` explicitly for non-US projects or you will query the wrong region.
Optional: `location` (e.g. `us`, `eu`, `us-central1`, `asia-northeast1`). Required for non-US projects using finops tools — the `INFORMATION_SCHEMA` views are region-scoped. Defaults to `us` if unset.
0 commit comments