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

[feature] Conditions emit no events like other Tekton resources #2461

Closed
afrittoli opened this issue Apr 21, 2020 · 5 comments
Closed

[feature] Conditions emit no events like other Tekton resources #2461

afrittoli opened this issue Apr 21, 2020 · 5 comments
Labels
kind/feature Categorizes issue or PR as related to a new feature. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.

Comments

@afrittoli
Copy link
Member

Expected Behavior

Conditions shall emit k8s events like other resources

Actual Behavior

No events are emitted for conditions in any case

Steps to Reproduce the Problem

  1. Run a condition
  2. kubectl describe taskrun/<tr-name>

Example:

$ k describe tr/tekton-yamllint-nf9c5-check-reset-9tx62-check-name-matche-xs7xt -n tektonci
Name:         tekton-yamllint-nf9c5-check-reset-9tx62-check-name-matche-xs7xt
Namespace:    tektonci
Labels:       app.kubernetes.io/managed-by=tekton-pipelines
              prow.k8s.io/build-id=85e12e80-83e8-11ea-874a-07e90178c9b9
              tekton.dev/check-name=plumbing-yamllint
              tekton.dev/conditionCheck=tekton-yamllint-nf9c5-check-reset-9tx62-check-name-matche-xs7xt
              tekton.dev/kind=ci
              tekton.dev/pipeline=tekton-yamllint
              tekton.dev/pipelineRun=tekton-yamllint-nf9c5
              tekton.dev/pipelineTask=check-reset
              tekton.dev/pr-number=346
              triggers.tekton.dev/eventlistener=tekton-ci-webhook
              triggers.tekton.dev/trigger=pull-request-trigger
              triggers.tekton.dev/triggers-eventid=224rq
Annotations:  kubectl.kubernetes.io/last-applied-configuration:
                {"apiVersion":"tekton.dev/v1beta1","kind":"Pipeline","metadata":{"annotations":{},"name":"tekton-yamllint","namespace":"tektonci"},"spec":...
              pipeline.tekton.dev/release: devel
              tekton.dev/gitURL: https://github.com/tektoncd/plumbing
API Version:  tekton.dev/v1beta1
Kind:         TaskRun
Metadata:
  Creation Timestamp:  2020-04-21T16:11:32Z
  Generation:          1
  Owner References:
    API Version:           tekton.dev/v1alpha1
    Block Owner Deletion:  true
    Controller:            true
    Kind:                  PipelineRun
    Name:                  tekton-yamllint-nf9c5
    UID:                   f62c9507-7c52-40c9-a737-f85a949f2ade
  Resource Version:        81050558
  Self Link:               /apis/tekton.dev/v1beta1/namespaces/tektonci/taskruns/tekton-yamllint-nf9c5-check-reset-9tx62-check-name-matche-xs7xt
  UID:                     2c1d19dc-1ed1-4d95-a887-af6a66b0fa07
Spec:
  Params:
    Name:   gitHubCommand
    Value:
    Name:   checkName
    Value:  plumbing-yamllint
  Resources:
  Service Account Name:  tekton-ci-jobs
  Task Spec:
    Params:
      Description:  The whole comment left on GitHub
      Name:         gitHubCommand
      Type:         string
      Description:  The name of the check
      Name:         checkName
      Type:         string
    Steps:
      Image:  alpine
      Name:   condition-check-check-name-matches
      Resources:
      Script:  #!/bin/sh
set -ex
set -o pipefail

# TODO(afrittoli) We might want to move this to an external script so
# we can attach unit tests to it.

# If no command was specified, the check is successful
[[ "$(inputs.params.gitHubCommand)" == "" ]] && exit 0

# If a command was specified, the regex should match the checkName
REGEX="$(echo $(inputs.params.gitHubCommand) | awk '{ print $2}')"
[[ "$REGEX" == "" ]] && REGEX='.*'
echo "$(inputs.params.checkName)" | grep -E $REGEX

  Timeout:  1h0m0s
Status:
  Completion Time:  2020-04-21T16:11:53Z
  Conditions:
    Last Transition Time:  2020-04-21T16:11:53Z
    Message:               All Steps have completed executing
    Reason:                Succeeded
    Status:                True
    Type:                  Succeeded
  Pod Name:                tekton-yamllint-nf9c5-check-reset-9tx62-check-name-matche-6qxds
  Start Time:              2020-04-21T16:11:33Z
  Steps:
    Container:  step-condition-check-check-name-matches
    Image ID:   docker-pullable://alpine@sha256:cb8a924afdf0229ef7515d9e5b3024e23b3eb03ddbba287f4a19c6ac90b8d221
    Name:       condition-check-check-name-matches
    Terminated:
      Container ID:  docker://d9b07260ebf8c3c8330d5711749ccb992618d009e19934cedff979c2eac71b20
      Exit Code:     0
      Finished At:   2020-04-21T16:11:51Z
      Reason:        Completed
      Started At:    2020-04-21T16:11:51Z
Events:              <none>

Additional Info

  • Kubernetes version:
    Output of kubectl version:

Server Version: version.Info{Major:"1", Minor:"15+", GitVersion:"v1.15.9-gke.24", GitCommit:"39e41a8d6b7221b901a95d3af358dea6994b4a40", GitTreeState:"clean", BuildDate:"2020-02-29T01:24:35Z", GoVersion:"go1.12.12b4", Compiler:"gc", Platform:"linux/amd64"} ```

  • Tekton Pipeline version:

    Output of tkn version or kubectl get pods -n tekton-pipelines -l app=tekton-pipelines-controller -o=jsonpath='{.items[0].metadata.labels.version}'

Client version: 0.8.0
Pipeline version: v0.11.1
@vdemeester
Copy link
Member

/kind feature

@tekton-robot tekton-robot added the kind/feature Categorizes issue or PR as related to a new feature. label Apr 22, 2020
@tekton-robot
Copy link
Collaborator

Stale issues rot after 30d of inactivity.
Mark the issue as fresh with /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
If this issue is safe to close now please do so with /close.

/lifecycle rotten

Send feedback to tektoncd/plumbing.

@tekton-robot
Copy link
Collaborator

Issues go stale after 90d of inactivity.
Mark the issue as fresh with /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
If this issue is safe to close now please do so with /close.

/lifecycle stale

Send feedback to tektoncd/plumbing.

@tekton-robot
Copy link
Collaborator

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

/close

Send feedback to tektoncd/plumbing.

@tekton-robot tekton-robot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Aug 14, 2020
@tekton-robot
Copy link
Collaborator

@tekton-robot: Closing this issue.

In response to this:

Rotten issues close after 30d of inactivity.
Reopen the issue with /reopen.
Mark the issue as fresh with /remove-lifecycle rotten.

/close

Send feedback to tektoncd/plumbing.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale.
Projects
None yet
Development

No branches or pull requests

3 participants