[WIP] Add missing organization-custom-org-roles and organization-custom-repository-roles to JSON Schema - #56982
Conversation
|
@copilot try again |
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
Fixed: the workflow-level permission schema now includes |
There was a problem hiding this comment.
🟡 Changes recommended
Permission error hints remain stale, and actual frontmatter validation lacks direct regression coverage.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
Adds two supported organization role permissions to workflow schema validation and editor autocomplete.
Changes:
- Adds both permission scopes to the shared schema.
- Updates generated autocomplete metadata.
- Adds schema consistency checks.
File summaries
| File | Description |
|---|---|
pkg/parser/schemas/main_workflow_schema.json |
Defines both permission scopes. |
docs/public/editor/autocomplete-data.json |
Exposes scopes in autocomplete. |
pkg/workflow/permissions_schema_consistency_test.go |
Checks scope presence. |
Review details
- Files reviewed: 3/3 changed files
- Comments generated: 2
- Review effort level: Balanced
| "organization-custom-org-roles": { | ||
| "type": "string", | ||
| "enum": ["read", "write", "none"], | ||
| "description": "Permission level for organization custom org roles (read/write/none). Controls access to custom organization role metadata." |
There was a problem hiding this comment.
Added both scopes to knownFieldValidValues and knownFieldScopes for /permissions and /on/permissions in pkg/parser/schema_errors.go (commit 2eded67).
| if _, ok := actionsPermProps[string(scope)]; !ok { | ||
| t.Errorf("permission scope %q from GetAllGitHubAppOnlyScopes() is missing from "+ | ||
| "$defs.github_actions_permissions.properties in pkg/parser/schemas/main_workflow_schema.json", scope) | ||
| } |
There was a problem hiding this comment.
Added TestOrganizationCustomRolePermissionsValidateAgainstSchema using ValidateMainWorkflowFrontmatterWithSchemaAndLocation, covering both valid values and invalid-value rejection for both scopes (commit 2eded67).
|
@copilot run pr-finisher skill |
Co-authored-by: pelikhan <4175913+pelikhan@users.noreply.github.com>
|
@copilot PR #56982 still needs forward progress.
|
The permission error hints and direct frontmatter validation regression coverage were already added and pushed in commit 2eded67 (before this comment was posted). Both changes are present on the current HEAD:
Re-running the pr-finisher skill now. |
Thanks for asking me to work on this. I will get started on it and keep this PR's description up to date as I form a plan and make progress.