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

Add V1 PipelineRun Golang struct #5324

Merged
merged 1 commit into from
Sep 1, 2022

Conversation

JeromeJu
Copy link
Member

@JeromeJu JeromeJu commented Aug 15, 2022

Changes

This commit adds structs and validation for v1 pipelineRun, including status,
params and workspaces. Since we do not yet serve a v1 version of Pipeline CRD,
this change should have no impact. This is copied from v1beta1 with the following
exceptions:

  • omitted PiepelineResourcesBinding
  • omitted PipelineRun.Timeout
  • omitted PipelineRun.Spec.PipelineRef.Bundle
  • renamed spec.TaskRunSpecs.taskServiceAccountName to spec.TaskRunSpecs.serviceAccountName
  • renamed spec.taskRunSpecs.taskPodTemplate to spec.taskRunSpecs.podTemplate

needs #5354
Part of #4987
kind /misc

Submitter Checklist

As the author of this PR, please check off the items in this checklist:

  • [n/a] Has Docs included if any changes are user facing
  • Has Tests included if any functionality added or changed
  • Follows the commit message standard
  • Meets the Tekton contributor standards (including
    functionality, content, code)
  • Has a kind label. You can add one by adding a comment on this PR that contains /kind <type>. Valid types are bug, cleanup, design, documentation, feature, flake, misc, question, tep
  • [n/a] Release notes block below has been updated with any user facing changes (API changes, bug fixes, changes requiring upgrade notices or deprecation warnings)
  • [n/a] Release notes contains the string "action required" if the change requires additional action from users switching to the new release

Release Notes

NONE

@tekton-robot
Copy link
Collaborator

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

@tekton-robot tekton-robot added do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Aug 15, 2022
@tekton-robot tekton-robot added size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files. release-note-none Denotes a PR that doesnt merit a release note. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. and removed do-not-merge/release-note-label-needed Indicates that a PR should not merge because it's missing one of the release note labels. labels Aug 15, 2022
@JeromeJu JeromeJu marked this pull request as ready for review August 22, 2022 20:45
@tekton-robot tekton-robot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Aug 22, 2022
@JeromeJu
Copy link
Member Author

JeromeJu commented Aug 23, 2022

Followup issue on the minimal status. #5355

1 Outdated Show resolved Hide resolved
@dibyom
Copy link
Member

dibyom commented Aug 23, 2022

/retest

@JeromeJu JeromeJu force-pushed the 4987-v1-pipelinerun branch 2 times, most recently from de8690b to ae9bbc7 Compare August 24, 2022 21:23
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 0.0%

@tekton-robot tekton-robot added the kind/misc Categorizes issue or PR as a miscellaneuous one. label Aug 24, 2022
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 0.0%

@tekton-robot tekton-robot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 25, 2022
@tekton-robot tekton-robot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 25, 2022
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 0.0%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 0.0%

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 90.9%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 57.7%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 89.0%

pkg/apis/pipeline/v1/pipelinerun_types.go Outdated Show resolved Hide resolved
pkg/apis/pipeline/v1/pipelinerun_types.go Outdated Show resolved Hide resolved
@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 90.9%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 57.7%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 89.0%

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 90.9%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 57.7%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 89.0%

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 90.9%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 57.7%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 89.0%

@JeromeJu JeromeJu requested review from lbernick and dibyom and removed request for dibyom and lbernick August 30, 2022 19:04
@tekton-robot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: lbernick

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@tekton-robot tekton-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 30, 2022
@dibyom
Copy link
Member

dibyom commented Sep 1, 2022

There's a file called pipeline.md.backup. Is that necessary?

@JeromeJu
Copy link
Member Author

JeromeJu commented Sep 1, 2022

There's a file called pipeline.md.backup. Is that necessary?

@dibyom Thanks for the review.

This was generated by https://github.com/tektoncd/pipeline/blob/main/hack/update-reference-docs.sh/#L26. I can remove it if not needed but meanwhile are there anything we need to change to the shell script?

@dibyom
Copy link
Member

dibyom commented Sep 1, 2022

Yeah, but it looks like the file was newly added. I think that file should be deleted by the script once its done?

This commit adds structs and validation for v1 pipelineRun, including status,
params and workspaces. Since we do not yet serve a v1 version of Pipeline CRD,
this change should have no impact. This is copied from v1beta1 with the following
exceptions:
- omitted PiepelineResourcesBinding
- deprecated PipelineRun.Timeout
- decpreated PipelineRun.Spec.PipelineRef.Bundle
- renamed spec.TaskRunSpecs.taskServiceAccountName to spec.TaskRunSpecs.serviceAccountName
- renamed spec.taskRunSpecs.taskPodTemplate to spec.taskRunSpecs.podTemplate
@JeromeJu
Copy link
Member Author

JeromeJu commented Sep 1, 2022

Yeah, but it looks like the file was newly added. I think that file should be deleted by the script once its done?

Deleted and reran ./hack/update-codegen. Was not able to reproduce the issue, this addition seems to be a flip.

@tekton-robot
Copy link
Collaborator

The following is the coverage report on the affected files.
Say /test pull-tekton-pipeline-go-coverage to re-run this coverage report

File Old Coverage New Coverage Delta
pkg/apis/pipeline/v1/pipelineref_validation.go Do not exist 100.0%
pkg/apis/pipeline/v1/pipelinerun_defaults.go Do not exist 90.9%
pkg/apis/pipeline/v1/pipelinerun_types.go Do not exist 57.7%
pkg/apis/pipeline/v1/pipelinerun_validation.go Do not exist 89.0%

@JeromeJu
Copy link
Member Author

JeromeJu commented Sep 1, 2022

/retest

2 similar comments
@JeromeJu
Copy link
Member Author

JeromeJu commented Sep 1, 2022

/retest

@JeromeJu
Copy link
Member Author

JeromeJu commented Sep 1, 2022

/retest

Copy link
Member

@dibyom dibyom left a comment

Choose a reason for hiding this comment

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

/lgtm

@tekton-robot tekton-robot added the lgtm Indicates that a PR is ready to be merged. label Sep 1, 2022
@tekton-robot tekton-robot merged commit a056c71 into tektoncd:main Sep 1, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. kind/misc Categorizes issue or PR as a miscellaneuous one. lgtm Indicates that a PR is ready to be merged. ok-to-test Indicates a non-member PR verified by an org member that is safe to test. release-note-none Denotes a PR that doesnt merit a release note. size/XXL Denotes a PR that changes 1000+ lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants