Permissions: change from list to key/value pairs in manifest #168
No reviewers
Labels
No Label
Priority
Critical
Priority
High
Priority
Low
Priority
Normal
Reviewed
Confirmed
Reviewed
Duplicate
Reviewed
Invalid
Reviewed
Won't Fix
Status
Abandoned
Status
Blocked
Status
Need More Info
Type
Breaking
Type
Documentation
Type
Enhancement
Type
Feature
Type
Report
Type
Security
Type
Suggestion
Type
Testing
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: infrastructure/extensions-website#168
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "permissions-dict"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
See #166
This PR changes validation rules for
permissions
field of the manifest.When present, the field is expected to represent a dictionary of {slug: reason}
key-value pairs. Previous format was a list of [slug].
Validation for these reason strings ensures that a reason is a non-empty string,
no longer than 64 characters, and doesn't end in punctuation.
No visible changes on the website are done in this PR.
/api/v1/extensions/
endpoint now returnspermissions
field as a dict{slug: reason}, where reason is taken from
VersionPermission.help
fieldmanaged via admin.
The new values are stored in metadata, but the
Version.permissions
modelis not changing yet, and thus it doesn't store the reason values.
We can decide to keep the model as is and lookup the reasons from
Version.file.metadata
, but this needs more thought.LGTM