Skip to content

feat(task): pass scoped user secret names - #319

Open
michaelbuchar wants to merge 1 commit into
reanahub:masterfrom
michaelbuchar:feat/scoped-user-secrets
Open

feat(task): pass scoped user secret names#319
michaelbuchar wants to merge 1 commit into
reanahub:masterfrom
michaelbuchar:feat/scoped-user-secrets

Conversation

@michaelbuchar

Copy link
Copy Markdown

Forward optional secret allowlists and step-local REANA hints from CWL workflows so job submissions preserve workflow defaults, step overrides, and the documented omitted-versus-empty semantics.

Closes reanahub/reana#978

michaelbuchar pushed a commit to michaelbuchar/reana-workflow-engine-cwl that referenced this pull request Jun 26, 2026
Forward optional secret allowlists and step-local REANA hints
from CWL workflows so job submissions preserve workflow defaults,
step overrides, and the documented omitted-versus-empty semantics.

Closes reanahub/reana#978
@michaelbuchar
michaelbuchar force-pushed the feat/scoped-user-secrets branch from b589a4b to 155d2f4 Compare June 26, 2026 13:10
michaelbuchar pushed a commit to michaelbuchar/reana-workflow-engine-cwl that referenced this pull request Jun 26, 2026
Forward optional secret allowlists and step-local REANA hints
from CWL workflows so job submissions preserve workflow defaults,
step overrides, and the documented omitted-versus-empty semantics.

Closes reanahub/reana#978
@michaelbuchar
michaelbuchar force-pushed the feat/scoped-user-secrets branch from 155d2f4 to f2a39f2 Compare June 26, 2026 13:15
@codecov

codecov Bot commented Jun 26, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 75.00000% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 29.54%. Comparing base (6a43f16) to head (83680b0).

Files with missing lines Patch % Lines
reana_workflow_engine_cwl/cwl_reana.py 81.81% 2 Missing ⚠️
reana_workflow_engine_cwl/main.py 0.00% 1 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff             @@
##           master     #319       +/-   ##
===========================================
+ Coverage   17.47%   29.54%   +12.06%     
===========================================
  Files          10       10               
  Lines         578      589       +11     
===========================================
+ Hits          101      174       +73     
+ Misses        477      415       -62     
Files with missing lines Coverage Δ
reana_workflow_engine_cwl/tasks.py 0.00% <ø> (ø)
reana_workflow_engine_cwl/main.py 0.00% <0.00%> (ø)
reana_workflow_engine_cwl/cwl_reana.py 39.58% <81.81%> (+21.12%) ⬆️
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

michaelbuchar pushed a commit to michaelbuchar/reana-workflow-engine-cwl that referenced this pull request Jun 26, 2026
Forward optional secret allowlists and step-local REANA hints
from CWL workflows so job submissions preserve workflow defaults,
step overrides, and the documented omitted-versus-empty semantics.

Closes reanahub/reana#978
@michaelbuchar
michaelbuchar force-pushed the feat/scoped-user-secrets branch from f2a39f2 to a9b1c4c Compare June 26, 2026 13:18
@michaelbuchar
michaelbuchar marked this pull request as ready for review June 26, 2026 13:18
michaelbuchar pushed a commit to michaelbuchar/reana-workflow-engine-cwl that referenced this pull request Aug 19, 2026
Forward optional secret allowlists and step-local REANA hints
from CWL workflows so job submissions preserve workflow defaults,
step overrides, and the documented omitted-versus-empty semantics.

Closes reanahub/reana#978
@michaelbuchar
michaelbuchar force-pushed the feat/scoped-user-secrets branch from a9b1c4c to 83680b0 Compare August 19, 2026 14:59
Forward optional secret allowlists and step-local REANA hints
from CWL workflows so job submissions preserve workflow defaults,
step overrides, and the documented omitted-versus-empty semantics.

Closes reanahub/reana#978
@michaelbuchar
michaelbuchar force-pushed the feat/scoped-user-secrets branch from 83680b0 to aecf8fc Compare August 21, 2026 07:05

@tiborsimko tiborsimko left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 PR319-01: Modified files omit the current copyright year (NIT)

reana_workflow_engine_cwl/main.py and reana_workflow_engine_cwl/tasks.py are modified in 2026, but their copyright headers currently end in 2025 and 2021 respectively. The repository convention is to include the year of each substantive modification.

Suggested fix — add 2026 to both copyright headers.

c4p_cpu_cores = self._get_hint("c4p_cpu_cores")
c4p_memory_limit = self._get_hint("c4p_memory_limit")
c4p_additional_requirements = self._get_hint("c4p_additional_requirements")
secret_names = resolve_secret_names(

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤖 Cross-component note for PR546-07: align CWL runtime hint resolution with sidecar discovery

The corresponding commons review found that packed-CWL sidecar discovery and ReanaPipelineJob._get_hint() resolve inherited REANA hints differently. Commons currently models step → tool and omits the Workflow node, while the runtime job scans cwltool's inherited workflow → step → tool list from the beginning. A workflow-only secret_names hint therefore scopes the job but leaves the sidecar at None (all secrets), and a step cannot narrow a conflicting workflow-level value.

The runtime resolver in this PR is one half of that contract. Its forward scan also governs compute_backend, kerberos, voms_proxy, rucio, kubernetes_uid, and the other REANA-specific fields, so changing precedence requires coordinated coverage beyond secret_names.

Suggested fix — coordinate this PR with the shared resolver proposed in PR546-07 so runtime job construction and packed-workflow discovery use the same explicitly defined workflow/step/tool precedence. Add packed-CWL regressions for workflow-only and conflicting workflow/step/tool hints, including a shared tool invoked from steps with different local values.

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.

Allow restricting which user secrets are exposed to workflow jobs and interactive sessions

2 participants