Skip to content

Conversation

@wking
Copy link
Member

@wking wking commented Jun 18, 2020

Address:

In .//ci-operator/step-registry/gather/aws-console/gather-aws-console-commands.sh line 35:
cat "${TMPDIR}/node-provider-IDs.txt" | sort | uniq | while read -r INSTANCE_ID
    ^-- SC2002: Useless cat. Consider 'cmd < file | ..' or 'cmd file | ..' instead.

For more information:
  https://www.shellcheck.net/wiki/SC2002 -- Useless cat. Consider 'cmd < file...

In .//ci-operator/step-registry/gather/extra/gather-extra-commands.sh line 28:
mkdir -p ${ARTIFACT_DIR}/pods ${ARTIFACT_DIR}/nodes ${ARTIFACT_DIR}/metrics ${ARTIFACT_DIR}/bootstrap ${ARTIFACT_DIR}/network ${ARTIFACT_DIR}/oc_cmds
         ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                              ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                    ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                                            ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                                                                      ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                                                                                              ^-------------^ SC2086: Double quote to prevent globbing and word splitting.

Did you mean:
mkdir -p "${ARTIFACT_DIR}"/pods "${ARTIFACT_DIR}"/nodes "${ARTIFACT_DIR}"/metrics "${ARTIFACT_DIR}"/bootstrap "${ARTIFACT_DIR}"/network "${ARTIFACT_DIR}"/oc_cmds

In .//ci-operator/step-registry/gather/extra/gather-extra-commands.sh line 31:
oc --insecure-skip-tls-verify --request-timeout=5s get pods --all-namespaces --template '{{ range .items }}{{ $name := .metadata.name }}{{ $ns := .metadata.namespace }}{{ range .spec.containers }}-n {{ $ns }} {{ $name }} -c {{ .name }}{{ "\n" }}{{ end }}{{ range .spec.initContainers }}-n {{ $ns }} {{ $name }} -c {{ .name }}{{ "\n" }}{{ end }}{{ end }}' > /tmp/containers
                                                                                        ^-- SC2016: Expressions don't expand in single quotes, use double quotes for that.
...
For more information:
  https://www.shellcheck.net/wiki/SC2016 -- Expressions don't expand in singl...
  https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ...

The syntax for ignore directives with trailing comments is documented here.

I've also dropped a redundant template layer from the JSONPath expressions.

This helps prepare for #9772.

@openshift-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: wking

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

The pull request process is described here

Details 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

@openshift-ci-robot openshift-ci-robot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Jun 18, 2020
@wking
Copy link
Member Author

wking commented Jun 19, 2020

Looks like I flubbed the JSONPath de-template:

error: error parsing jsonpath {range .items}{$name := .metadata.name}{$ns := .metadata.namespace}{range .spec.containers}-n {$ns} {$name} -c {.name}{"\n"}{end}{range .spec.initContainers}-n {$ns} {$name} -c {.name}{"\n"}{end}{end}, unrecognized character in action: U+003A ':'

/hold

@openshift-ci-robot openshift-ci-robot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jun 19, 2020
…'cat'

Address [1,2]:

  In .//ci-operator/step-registry/gather/aws-console/gather-aws-console-commands.sh line 35:
  cat "${TMPDIR}/node-provider-IDs.txt" | sort | uniq | while read -r INSTANCE_ID
      ^-- SC2002: Useless cat. Consider 'cmd < file | ..' or 'cmd file | ..' instead.

  For more information:
    https://www.shellcheck.net/wiki/SC2002 -- Useless cat. Consider 'cmd < file...

  In .//ci-operator/step-registry/gather/extra/gather-extra-commands.sh line 28:
  mkdir -p ${ARTIFACT_DIR}/pods ${ARTIFACT_DIR}/nodes ${ARTIFACT_DIR}/metrics ${ARTIFACT_DIR}/bootstrap ${ARTIFACT_DIR}/network ${ARTIFACT_DIR}/oc_cmds
           ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                      ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                                              ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                                                                        ^-------------^ SC2086: Double quote to prevent globbing and word splitting.
                                                                                                                                ^-------------^ SC2086: Double quote to prevent globbing and word splitting.

  Did you mean:
  mkdir -p "${ARTIFACT_DIR}"/pods "${ARTIFACT_DIR}"/nodes "${ARTIFACT_DIR}"/metrics "${ARTIFACT_DIR}"/bootstrap "${ARTIFACT_DIR}"/network "${ARTIFACT_DIR}"/oc_cmds

  In .//ci-operator/step-registry/gather/extra/gather-extra-commands.sh line 31:
  oc --insecure-skip-tls-verify --request-timeout=5s get pods --all-namespaces --template '{{ range .items }}{{ $name := .metadata.name }}{{ $ns := .metadata.namespace }}{{ range .spec.containers }}-n {{ $ns }} {{ $name }} -c {{ .name }}{{ "\n" }}{{ end }}{{ range .spec.initContainers }}-n {{ $ns }} {{ $name }} -c {{ .name }}{{ "\n" }}{{ end }}{{ end }}' > /tmp/containers
                                                                                          ^-- SC2016: Expressions don't expand in single quotes, use double quotes for that.
  ...
  For more information:
    https://www.shellcheck.net/wiki/SC2016 -- Expressions don't expand in singl...
    https://www.shellcheck.net/wiki/SC2086 -- Double quote to prevent globbing ...

Also:

  In gather/loki/gather-loki-commands.sh line 84:
  if [[ $(oc get ns -o json | jq '.items[].metadata.name' | grep '"loki"' | wc -l) -eq 0 ]]; then
                                                            ^-----------^ SC2126: Consider using grep -c instead of grep|wc -l.

  For more information:
    https://www.shellcheck.net/wiki/SC2126 -- Consider using grep -c instead of...

The syntax for ignore directives with trailing comments is documented in [3].

I've also dropped a redundant template layer from the JSONPath
expressions where I could figure out how to do that.

[1]: https://deck-ci.apps.ci.l2s4.p1.openshiftapps.com/view/gcs/origin-ci-test/pr-logs/pull/openshift_release/9772/pull-ci-openshift-release-master-step-registry-shellcheck/1273670881133989888#1:build-log.txt%3A271
[2]: https://storage.googleapis.com/origin-ci-test/pr-logs/pull/openshift_release/9772/pull-ci-openshift-release-master-step-registry-shellcheck/1273670881133989888/build-log.txt
[3]: https://github.com/koalaman/shellcheck/wiki/Directive#documenting-directive-use
@wking wking force-pushed the gather-shellcheck-cleanup branch from 777f4fd to 1959390 Compare July 8, 2020 05:33
@wking
Copy link
Member Author

wking commented Jul 8, 2020

/hold cancel

Gave up on trying to figure out that particular template -> JSONPath translation, so reverted it to master's template while rebasing onto master with 777f4fdbf0 -> 1959390.

@openshift-ci-robot openshift-ci-robot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Jul 8, 2020
@openshift-ci-robot
Copy link
Contributor

@wking: The following tests failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/rehearse/openshift/kubernetes/marun-testing/e2e-cmd 777f4fdbf07cd7f9c2f27f017b268ed1c26ee04f link /test pj-rehearse
ci/rehearse/openshift/origin/master/e2e-gcp 777f4fdbf07cd7f9c2f27f017b268ed1c26ee04f link /test pj-rehearse
ci/rehearse/openshift/installer/master/e2e-vsphere 777f4fdbf07cd7f9c2f27f017b268ed1c26ee04f link /test pj-rehearse
ci/rehearse/cri-o/cri-o/release-1.13/e2e-aws 777f4fdbf07cd7f9c2f27f017b268ed1c26ee04f link /test pj-rehearse
ci/rehearse/openshift/kubernetes/marun-testing13/kubernetes-e2e 1959390 link /test pj-rehearse
ci/rehearse/openshift/cluster-network-operator/master/e2e-vsphere 1959390 link /test pj-rehearse
ci/rehearse/openshift/builder/master/e2e-aws-image-ecosystem 1959390 link /test pj-rehearse
ci/rehearse/openshift/cluster-image-registry-operator/master/e2e-aws-image-registry 1959390 link /test pj-rehearse
ci/rehearse/openshift/installer/fcos/e2e-vsphere 1959390 link /test pj-rehearse
ci/rehearse/openshift/cluster-network-operator/master/e2e-aws-sdn-single 1959390 link /test pj-rehearse
ci/rehearse/openshift/origin/marun-testing/e2e-gcp 1959390 link /test pj-rehearse
ci/rehearse/openshift/installer/master/e2e-aws-shared-vpc 1959390 link /test pj-rehearse
ci/rehearse/openshift/installer/master/e2e-gcp-shared-vpc 1959390 link /test pj-rehearse
ci/rehearse/cri-o/cri-o/master/e2e-aws 1959390 link /test pj-rehearse
ci/rehearse/openshift/cloud-credential-operator/master/e2e-azure 1959390 link /test pj-rehearse
ci/rehearse/openshift-knative/serverless-operator/master/4.3-e2e-aws-ocp-43 1959390 link /test pj-rehearse
ci/rehearse/openshift/installer/master/e2e-gcp-upi-xpn 1959390 link /test pj-rehearse
ci/rehearse/openshift/cluster-network-operator/master/e2e-windows-hybrid-network 1959390 link /test pj-rehearse
ci/rehearse/openshift/cluster-network-operator/master/e2e-ovn-step-registry 1959390 link /test pj-rehearse
ci/rehearse/openshift/installer/master/e2e-azure-shared-vpc 1959390 link /test pj-rehearse
ci/rehearse/openshift/openshift-controller-manager/master/e2e-gcp-builds 1959390 link /test pj-rehearse
ci/rehearse/openshift/cluster-network-operator/master/e2e-azure 1959390 link /test pj-rehearse
ci/prow/pj-rehearse 1959390 link /test pj-rehearse
ci/prow/ci-testgrid-allow-list 1959390 link /test ci-testgrid-allow-list
ci/prow/yamllint 1959390 link /test yamllint
ci/prow/boskos-config 1959390 link /test boskos-config

Full PR test history. Your PR dashboard.

Details

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. I understand the commands that are listed here.

@openshift-merge-robot
Copy link
Contributor

@wking: The following tests failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/release-config 1959390 link /test release-config
ci/prow/boskos-config-generation 1959390 link /test boskos-config-generation
ci/prow/secret-generator-config-valid 1959390 link /test secret-generator-config-valid
ci/prow/deprecate-templates 1959390 link /test deprecate-templates

Full PR test history. Your PR dashboard.

Details

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. I understand the commands that are listed here.

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jan 14, 2021

@wking: The following test failed, say /retest to rerun all failed tests:

Test name Commit Details Rerun command
ci/prow/ci-secret-generator-config 1959390 link /test ci-secret-generator-config

Full PR test history. Your PR dashboard.

Details

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. I understand the commands that are listed here.

@openshift-bot
Copy link
Contributor

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@openshift-ci-robot openshift-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Apr 14, 2021
@openshift-ci
Copy link
Contributor

openshift-ci bot commented Apr 14, 2021

@wking: PR needs rebase.

Details

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.

@openshift-ci openshift-ci bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 14, 2021
@openshift-bot
Copy link
Contributor

Stale issues rot after 30d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle rotten
/remove-lifecycle stale

@openshift-ci openshift-ci bot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels May 14, 2021
@openshift-bot
Copy link
Contributor

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

@openshift-ci
Copy link
Contributor

openshift-ci bot commented Jun 13, 2021

@openshift-bot: Closed this PR.

Details

In response to this:

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

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.

@openshift-ci openshift-ci bot closed this Jun 13, 2021
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. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants