fix: workflow access bugs#838
Open
Kevin Loftus (kevin-loftus-dept) wants to merge 1 commit into
Open
Conversation
8956b83 to
2d20fda
Compare
Ignacio Nistal (ignacionistal)
approved these changes
Jul 10, 2026
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.
Title*
fix: workflow access bugs — paginate catalog before filtering & stop denying workflows on "default on"
Type of Change*
Description
Fixes several related bugs in the laboratory workflow-access feature where granted workflows/pipelines could be invisible to lab users, and where enabling "new workflows by default" hid everything.
1.
list-private-workflowsonly filtered the first page (AWS HealthOmics)The lambda fetched a single page of PRIVATE workflows and then applied the access filter. Any granted workflow beyond the first page was hidden from every user, even though it appeared in the (fully paginated) admin workflow catalog. Added
listAllPrivateWorkflows()to page through all results (maxResults: 100, followingnextToken) before filtering. The response now returns the filtered{ items }only, instead of spreading the raw paginated response (which leaked a misleadingnextToken).2.
list-pipelinesonly filtered the first page (Seqera / NextFlow Tower)Same class of bug for Seqera pipelines. Added
listAllPipelines()that pages viaoffset/max, de-dupes bypipelineId, preserves caller-supplied search +workspaceIdparams, and returns the full set with a correctedtotalSizebefore the access filter runs.3. "Enable new workflows by default" denied the entire catalog
On the strict → default-on transition, the migration wrote a
DENYrow for every catalog workflow that wasn't explicitly allowed. Because default-on means "allowed unless explicitly denied," this produced the reported "toggle is on, but nobody can see any workflows" state. The migration now simply clears leftover strict-mode rows (redundantALLOWrows and stale/spuriousDENYrows) and never writes catalogDENYrows, landing the lab on a clean "allowed by default" state.4. Unified catalog no longer enumerates SHARED workflows
buildUnifiedWorkflowCatalogForOrganizationpreviously included HealthOmics SHARED workflows. Since the lab-facing endpoint only ever returns PRIVATE workflows, shared entries were grantable in the admin panel yet never visible to lab users. Shared-workflow enumeration (and its now-unused helper/imports) was removed so the admin catalog matches what labs can actually see.Testing*
list-private-workflows.lambda.test.tsto mock multi-page responses and assert the access filter is applied across every page (verifieslistWorkflowsis called for each page and both allowed workflows from separate pages are returned).laboratory-workflow-access-default-migration.test.tsfor the new strict → default-on behavior: asserts noDENYrows are written and that both the redundantALLOWand staleDENYrows are removed.Impact
Additional Information
Branch is rebased onto the current
staging(which was reset to matchmain) and contains a single commit, so the diff is limited to the six files of this fix.Checklist*