Skip to content

PM-3764: restore work-layer read parity#15

Merged
jmgasper merged 1 commit intodevfrom
PM-3764-2
Apr 7, 2026
Merged

PM-3764: restore work-layer read parity#15
jmgasper merged 1 commit intodevfrom
PM-3764-2

Conversation

@jmgasper
Copy link
Copy Markdown
Contributor

@jmgasper jmgasper commented Apr 6, 2026

What was broken
Work stream, work, and work item read routes could still reject legitimate Projects API users before or during permission evaluation. The work-layer controllers only admitted a narrow role subset, and the named work-view permissions still excluded manager-tier legacy project-view access.

Root cause (if identifiable)
The earlier PM-3764 follow-ups restored legacy read parity for projects, members, invites, and attachments, but the work-layer endpoints were still using narrower auth rules than the legacy v5 projectView policy.

What was changed
Broadened the work-layer coarse role gate to accept all known human roles so project-member access reaches PermissionGuard.
Updated work-layer view permissions to allow manager-tier legacy project-view access and machine connect_project_admin scope, and aligned the Swagger/docs output with that behavior.
Documented the remaining PM-3764 work-layer read parity in the permissions docs.

Any added/updated tests
Added a TokenRolesGuard regression for Topcoder User tokens on work-layer routes.
Expanded PermissionService regression coverage for manager-tier work-layer reads and machine connect_project_admin scope.
Validated with pnpm lint, targeted auth/work regressions, and pnpm build.
Full pnpm test still has the existing unrelated metadata event-bus failures on the current dev baseline.

What was broken
Work stream, work, and work item read routes could still reject legitimate Projects API users before or during permission evaluation. The work-layer controllers only admitted a narrow role subset, and the named work-view permissions still excluded manager-tier legacy project-view access.

Root cause (if identifiable)
The earlier PM-3764 follow-ups restored legacy read parity for projects, members, invites, and attachments, but the work-layer endpoints were still using narrower auth rules than the legacy v5 projectView policy.

What was changed
Broadened the work-layer coarse role gate to accept all known human roles so project-member access reaches PermissionGuard.
Updated work-layer view permissions to allow manager-tier legacy project-view access and machine connect_project_admin scope, and aligned the Swagger/docs output with that behavior.
Documented the remaining PM-3764 work-layer read parity in the permissions docs.

Any added/updated tests
Added a TokenRolesGuard regression for Topcoder User tokens on work-layer routes.
Expanded PermissionService regression coverage for manager-tier work-layer reads and machine connect_project_admin scope.
Validated with pnpm lint, targeted auth/work regressions, and pnpm build.
Full pnpm test still has the existing unrelated metadata event-bus failures on the current dev baseline.
@jmgasper jmgasper merged commit 5ff0844 into dev Apr 7, 2026
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant