[Bug] Power BI connector generated client fails TypeScript type check (Goals operations)
@eschavez đang làm issue này rồi.
Từ ngày 23/10/2026.
Đánh giá
Issue này chưa được đánh giá.
Mô tả
Describe the bug
After adding the Power BI connector (shared_powerbi) as an action-mode data source, the generated client fails tsc --noEmit with two errors, both in Goals (scorecard) operations. The app only calls ExecuteDatasetQuery, but the generated files include all 24 operations, so the type check fails and the app can't pass a pre-publish type check. Regenerating (refresh data source) produces the same output.
Errors:
generated/models/PowerBIModel.ts(299,14): error TS2552: Cannot find name 'GoalValueOrNoteUpsertedstatus'. Did you mean 'GoalValueOrNoteUpserted'?
generated/services/PowerBIService.ts(153,5): error TS1016: A required parameter cannot follow an optional parameter.
GoalValueOrNoteUpserted.checkIns[].statusreferences a typeGoalValueOrNoteUpsertedstatusthat is never emitted (looks like an inline enum/string schema that the generator names but doesn't define):
// The status of the goal at the time of check-in.
status?: GoalValueOrNoteUpsertedstatus;
GetGoalputs a required$expandafter the optionalpbi_source. Per the Power BI REST docs (Goals – Get By ID),expandis an optional query parameter:
public static async GetGoal(
groupid: string,
scorecardId: string,
goalId: string,
pbi_source?: string,
$expand: string
): Promise<IOperationResult<FetchedGoal>>
Steps to Reproduce
- Create a code app / managed app (React + Vite + TypeScript template).
- Add data source: connector
shared_powerbi, action mode (no table). - Run
tsc -p tsconfig.app.json --noEmit(or the template'stypecheckscript). - Observe the two errors above. Refresh/regenerate the data source: same result.
Expected behavior
Generated files type-check without manual edits. Either emit the missing GoalValueOrNoteUpsertedstatus type (or fall back to string), and generate $expand as optional ($expand?: string) or order required parameters before optional ones.
Environment information
- Package:
@microsoft/managed-apps0.5.11 (app built with App Builder in Microsoft 365 Copilot) - TypeScript ~5.8.3, Vite 7
- Connector:
shared_powerbi(Power BI, Microsoft), action mode - Production build (
vite build) succeeds; only the type check fails.
Workaround
None without hand-editing generated files (which are overwritten on refresh). Fixing the two lines locally (status?: string; and $expand?: string) makes the type check pass.
Related
Originally filed as microsoft/PowerAppsCodeApps#510 and redirected here.
- Ngôn ngữ chính
- TypeScript
- Star
- 32
- Fork
- 9
- Merge trung bình
- 5 giờ 29 phút
- Pull request đã merge (30 ngày)
- 4
Chuẩn bị môi trường
Dự án này không cung cấp dev container, Dockerfile hay hướng dẫn đóng góp, nên bạn cần tự thiết lập môi trường: hãy bắt đầu từ README và xem hướng dẫn đóng góp lần đầu của chúng tôi để biết các bước chung.
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của microsoft/managed-apps
-
[Bug] SQL Server (`shared_sql`) action operations are always routed to `/procedures` with an unresolved path template, so Insert row (V2), Execute a SQL query (V2), Get tables (V2) etc. all return 404Có thể đã có người làm @tonystevenj đã nhận 5 ngày trước. Đang mởbug product team investigating
microsoft/managed-apps#45 · 1 bình luận · 1 người được giao ·
-
[Bug] Table-mode create/update sends a JSON body without a Content-Type header, so the SQL Server connector rejects inserts with 415 "media type 'text/plain' is not supportedCó thể đã có người làm @tonystevenj đã nhận 5 ngày trước. Đang mởbug product team investigating
microsoft/managed-apps#44 · 1 bình luận · 1 người được giao ·
-
[Bug] Cannot block Tenant wide CLI pathCó thể đã có người làm @ergonza93 đã nhận 5 ngày trước. Đang mởbug
microsoft/managed-apps#43 · 1 bình luận · 1 người được giao ·
-
[Bug] `ms app clone` fails on macOSCó thể đã có người làm @sokhenglim1 đã nhận 4 ngày trước. Đang mởbug
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 58/100
microsoft/managed-apps#42 · 1 bình luận · 1 người được giao ·
-
[Bug] Device-code sign-in fails with post_request_failed: invalid_client in CLI 0.27.0–0.29.0Có thể đã có người làm @jiankai82 đã nhận 5 ngày trước. Đang mởbug
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 15/100
microsoft/managed-apps#39 · 3 bình luận · 1 người được giao ·
Tất cả issue của microsoft/managed-apps
Issue tương tự
-
a10y a10y-audit ai-driven-qa claude
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 86/100
linagora/twake-directory-manager#219 ·
Maintainer thường phản hồi trong vòng 1 ngày
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
Maintainer thường phản hồi trong vòng 1 ngày
-
type: bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 79/100
Maintainer thường phản hồi trong vòng 1 ngày
-
0️⃣ phase/new
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 82/100
Maintainer thường phản hồi trong vòng 1 ngày
-
Pulse v7: buildPreferencesFromTelos() bypasses telosSectionOrFile(), renders empty on unified-TELOS installsCó thể đã có người làm @zephyr91 đã nhận hôm nay. Đang mở
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 75/100
danielmiessler/LifeOS#2393 ·
Maintainer thường phản hồi trong vòng 4 ngày