jobs: 0.89.0 changed jobs result shapes from snake_case to camelCase
維護者通常 3 天內回覆
還沒有人認領這個 Issue。
評估
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 新手友好度
- 48/100
- Issue 類型
- 缺陷
- 描述清晰度
- 基本清楚
- 活躍度
- 活躍
- 技術堆疊
- typescript
研究方向
Start with packages/appkit/src/connectors/jobs/client.ts and reproduce the runNow() result using the TypeScript snippet in the issue; compare the affected methods and status payloads with the documented behavior. The issue offers two possible resolutions, so confirm which is intended before changing code; done means either restoring the described snake_case shapes or documenting the breaking change and affected fields in the 0.89.0 release notes.
由索引模型根據 Issue 內容生成。
描述
Summary
In 0.89.0, the jobs plugin returns camelCase keys wherever it passes Jobs API objects through: the programmatic API, two routes, and the run object in status payloads. Through 0.88.1 these were snake_case. #647 says "Translate camelCase/bigint models back to the snake_case/number wire shape at the connector boundary, so the plugin's HTTP, SSE and cache output is unchanged", but the merged connector doesn't do that. The release notes list it as a feature, with no breaking-change note. Verified live against a real job on both versions.
Not affected (the common path)
Apps that trigger jobs and react to the status string see no change:
POST /api/jobs/:jobKey/runreturns{ runId }in both versions (confirmed from source).GET /api/jobs/:jobKey/statusand therunAndWait()/POST /run?stream=trueupdates keep the samestatusvalues (RUNNING,TERMINATED, and so on).- Failure results keep the same shape (
{ ok: false, status, message }). @databricks/appkit-uidoesn't read jobs results, so no built-in UI is affected.
Affected
Code that reads fields from a run or job object:
appkit.jobs(key).runNow():datawas{ run_id, number_in_job, wait }and is now{ runId }.getRun,listRuns,lastRun,getRunOutput,getJob: all keys are camelCase. For example,run_idis nowrunId,run_page_urlis nowrunPageUrl, andstate.life_cycle_stateis nowstate.lifeCycleState. TypeScript flags these at compile time; JavaScript getsundefined.GET /runsandGET /runs/:runId: they returnresult.datadirectly, so their JSON keys changed. Client code breaks silently.- The
runobject inGET /statusand inrunAndWait()/ streamed status updates: same key change.
Cause
packages/appkit/src/connectors/jobs/client.ts:
runNowreturns{ runId: Number(waiter.runId) }.- The other methods pass the modular SDK models through
toNumbers. That helper converts bigints to numbers but keeps the SDK's camelCase keys.
Repro
const result = await appkit.jobs("default").runNow();
console.log(Object.keys(result.data));
// 0.88.1: ["run_id", "number_in_job", "wait"]
// 0.89.0: ["runId"]
Why it matters
jobs is exported from the package root, not /beta. The stability doc says only /beta APIs "may change between minor releases".
Ask
Either restore the snake_case shape that #647 describes, or keep camelCase and add a breaking-change note to the 0.89.0 release notes listing the affected methods and fields. Related: docs/plugins/jobs.md already changed to result.data.runId in 0.89.0.
This issue was written by Isaac.
- 主要語言
- TypeScript
- 星號
- 119
- 分支
- 36
- 平均合併
- 4 天 16 小時
- 30 天內合併 PR
- 37
環境準備
- 沒有 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
databricks/appkit 的其他 Issue
-
難度 4/5 3-5 天 新手友好度 55/100
databricks/appkit#729 ·
維護者通常 3 天內回覆
-
@databricks/lakebase: pool drops maxLifetimeSeconds and other pg options, so connections never recycle and Unity Catalog claims access fails after 4 hours可能已有人在做 @billmcmillin 於 5 天前認領。 未關閉
難度 4/5 3-5 天 新手友好度 20/100
databricks/appkit#718 ·
維護者通常 3 天內回覆
-
難度 3/5 半天 新手友好度 42/100
databricks/appkit#656 · 1 則留言 ·
維護者通常 3 天內回覆
-
難度 4/5 3-5 天 新手友好度 28/100
databricks/appkit#648 · 2 則留言 ·
維護者通常 3 天內回覆
-
難度 3/5 1-2 天 新手友好度 58/100
databricks/appkit#603 ·
維護者通常 3 天內回覆
查看 databricks/appkit 的全部 Issue
相似的 Issue
-
Add "append" and "prepend" slots for vue-vuetify extended renderers可能已有人在做 @simeyc 今天認領。 未關閉
難度 2/5 1-3 小時 新手友好度 75/100
eclipsesource/jsonforms#2668 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 68/100
維護者通常 1 天內回覆
-
README の通知条件を実際の判定処理に合わせる可能已有人在做 @unhappychoice 今天認領。 未關閉factory:in-progress priority:medium
難度 1/5 1 小時以內 新手友好度 90/100
unhappychoice/oss-issue-opener#395 · 1 則留言 ·
維護者通常 1 天內回覆
-
bug Website
難度 2/5 1-3 小時 新手友好度 77/100
OWASP/OWASP-Hunting#88 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 76/100
維護者通常 1 天內回覆