Improve Northflank diagnostics and support optional NORTHFLANK_TEAM_ID - #353
Open
kisernl wants to merge 15 commits into
Open
Improve Northflank diagnostics and support optional NORTHFLANK_TEAM_ID#353kisernl wants to merge 15 commits into
kisernl wants to merge 15 commits into
Conversation
…nd legacy results Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Contributor
🤖 Devin AI EngineerI'll be helping with this pull request! Here's what you should know: ✅ I will automatically:
Note: I can only respond to comments from users who have write access to this repository. ⚙️ Control Options:
|
Contributor License AgreementAll contributors are covered by a CLA. |
…onse shape Co-Authored-By: Noah Kiser <noah@computesdk.com>
… id-token permission Co-Authored-By: Noah Kiser <noah@computesdk.com>
…-client dependency Co-Authored-By: Noah Kiser <noah@computesdk.com>
…workflow Co-Authored-By: Noah Kiser <noah@computesdk.com>
Contributor
|
The temporary |
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
Co-Authored-By: Noah Kiser <noah@computesdk.com>
…eate Co-Authored-By: Noah Kiser <noah@computesdk.com>
…gnostic Co-Authored-By: Noah Kiser <noah@computesdk.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Investigation showed that the benchmark is failing because the configured
NORTHFLANK_TOKENcan authenticate to account-level endpoints (/v1/plansand/v1/projects) but gets401 Unauthorizedon every project-level endpoint:The token does see one personal project whose ID matches
NORTHFLANK_PROJECT_ID, so the project exists and the token can list it, but it cannot read or modify it. Northflank API tokens inherit their permissions from an RBAC role, and the role assigned to this token is missing the project-level permissions the provider needs:Project > Projects > Manage > ReadProject > Services > General > ReadProject > Services > General > Create(andUpdate/Deletefor destroy)This PR makes two changes to help surface and fix the issue:
Better diagnostics in benchmark output
packages/benchsdk-runner/src/runner.tsprints the provider'serrorMessagealongside the error code, so runs now showFAILED — NorthflankApiCallError: Unauthorizedinstead of justFAILED — NorthflankApiCallError.benchmarks/sandbox/types.tsandbenchmarks/sandbox/legacy-results.tscarry that message through to the legacy JSON results.Support for team-scoped Northflank projects
benchmarks/sandbox/providers.tsnow passesprocess.env.NORTHFLANK_TEAM_IDto the Northflank provider.NORTHFLANK_TEAM_IDfrom the vault.@computesdk/northflankalready supportedteamIdinprojectParams/serviceParams; the benchmark was simply not wiring the env var through.If the project is team-owned, the token must be generated under that team and
NORTHFLANK_TEAM_IDmust be set in the vault. If the project is personal, the token's RBAC role needs the project/service permissions above. TheNorthflankApiCallError: Unauthorizedmessage should now make this obvious in future runs.Link to Devin session: https://app.devin.ai/sessions/fd1b73e919a34eae8db2f1f1937c3205
Requested by: @kisernl