Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Executing workflows in the UI unexpectedly uses the namespace last selected in the UI #9462

Closed
2 of 3 tasks
asfaltboy opened this issue Aug 29, 2022 · 4 comments
Closed
2 of 3 tasks
Labels
area/ui problem/stale This has not had a response in some time type/bug

Comments

@asfaltboy
Copy link

asfaltboy commented Aug 29, 2022

Checklist

  • Double-checked my configuration.
  • Tested using the latest version. -- looking to upgrade soon
  • Used the Emissary executor.

Summary

The issue can be summarised as 3 distinct behaviours:

  1. Executing workflows in the UI unexpectedly uses the namespace last selected in the UI, e.g set by filtering workflow list in the by the namespace field (possibly introduced in feat(ui): cache namespace selection. Closes #2439 #2441).

  2. There seems to be no way to specify a namespace in the UI for a ClusterWorkflowTemplate without a namespace defined in the manifest yaml (at least I could not find one, please correct me if I'm wrong). So, the problem described in (1) above seems to be the only workaround for this missing feature (see step-by-step instructions below for an example).

  3. Submitting a workflow from the "Workflows" UI page does allow selecting the workflow namespace, but this action also seems to "select a namespace" same as filtering by namespace in the UI described in (1).

I think this behaviour in (3) may be desired. But, I think that it, along with the feature mentioned in (1) should probably be documented as well. Not sure about (2), how come we're not allowing to set namespace in CWTs? Please let me know if anything in the descriptions seems wrong.

We're running argo workflows version 3.2.4

Diagnostics

Workflow yaml (copy pasted from the docs, not tested this particular workflow myself, but should work the same I reckon):

apiVersion: argoproj.io/v1alpha1
kind: ClusterWorkflowTemplate
metadata:
  name: cluster-workflow-template-whalesay-template
spec:
  templates:
  - name: whalesay-template
    inputs:
      parameters:
      - name: message
    container:
      image: docker/whalesay
      command: [cowsay]
      args: ["{{inputs.parameters.message}}"]

Step-by-step instructions:

  1. Have a ClusterWorkflowTemplate with no namespace defined, let's call it "my-workflow".
  2. Use the Workflows -> +Submit workflow action to create the "argosay" example workflow, in the default namespace
  3. Use the Cluster Workflow Templates -> Create New Cluster Workflow Template action to create an instance of "my-workflow" template. Result: it runs in the default namespace.
  4. Repeat step 2, but use workflows namespace
  5. Repeat step 3. Result: it runs in the workflows namespace.

Additional discussion is in the thread here:
https://cloud-native.slack.com/archives/C01QW9QSSSK/p1660849688488899

NOTE: will add logs when I'm back in office.

# Logs from the workflow controller:
kubectl logs -n argo deploy/workflow-controller | grep ${workflow}

# If the workflow's pods have not been created, you can skip the rest of the diagnostics.

# The workflow's pods that are problematic:
kubectl get pod -o yaml -l workflows.argoproj.io/workflow=${workflow},workflow.argoproj.io/phase!=Succeeded

# Logs from in your workflow's wait container, something like:
kubectl logs -c wait -l workflows.argoproj.io/workflow=${workflow},workflow.argoproj.io/phase!=Succeeded

Message from the maintainers:

Impacted by this regression? Give it a 👍. We prioritise the issues with the most 👍.

@asfaltboy asfaltboy added type/bug type/regression Regression from previous behavior (a specific type of bug) triage labels Aug 29, 2022
@sarabala1979 sarabala1979 removed the type/regression Regression from previous behavior (a specific type of bug) label Aug 29, 2022
@alexec alexec added the area/ui label Sep 5, 2022
@alexec
Copy link
Contributor

alexec commented Sep 5, 2022

I've no comment on this issue. Someone needs to start up the UI and start debugging.

@ravitejasssihl
Copy link

Hey @alexec @asfaltboy can you please assign me this project,I would like to work on this.

@stale
Copy link

stale bot commented Oct 1, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If this is a mentoring request, please provide an update here. Thank you for your contributions.

@stale stale bot added the problem/stale This has not had a response in some time label Oct 1, 2022
@stale
Copy link

stale bot commented Oct 16, 2022

This issue has been closed due to inactivity. Feel free to re-open if you still encounter this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/ui problem/stale This has not had a response in some time type/bug
Projects
None yet
Development

No branches or pull requests

4 participants