You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Mar 13, 2022. It is now read-only.
Repository navigation
This repository was archived by the owner on Mar 13, 2022. It is now read-only.
Boilerplate includes un-necessary shebang line #154
We should remove the shebang line from hack/boilerplate/boilerplate.py.txt and then remove it from the modules which aren't expected to run as scripts.
Yes, I see that this was discussed. And I also see that you made this comment in the past:
I don’t think the python shebang should appear in the non-executable files. This applies to most files you added the shebang.
What is correct for the main repository isn't blindly correct to a python software. The main repository contains Python scripts which are predestined to be run by CI jobs and developers. For this case it is easier to type ./hack/script-name.py instead of explicitly calling python before the script name. The main (k/k) repository contains:
$ cd ~/Software/kubernetes
$ find . -type f -name "*.py"
./hack/update_owners.py
./hack/boilerplate/test/fail.py
./hack/boilerplate/test/pass.py
./hack/boilerplate/boilerplate_test.py
./hack/boilerplate/boilerplate.py
./hack/verify-flags-underscore.py
./hack/verify-publishing-bot.py
./translations/extract.py
For this repository there no point adding the shebang in Python modules and packages. This looks bad and conveys bad code smell (which might decrease usage in favor for other clients and eventually distract potential contributions).
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.
Activity
micw523 commentedon Aug 15, 2019
See discussion in #107 - this has been discussed
oz123 commentedon Aug 15, 2019
Yes, I see that this was discussed. And I also see that you made this comment in the past:
What is correct for the main repository isn't blindly correct to a python software. The main repository contains Python scripts which are predestined to be run by CI jobs and developers. For this case it is easier to type
./hack/script-name.pyinstead of explicitly calling python before the script name. The main (k/k) repository contains:For this repository there no point adding the shebang in Python modules and packages. This looks bad and conveys bad code smell (which might decrease usage in favor for other clients and eventually distract potential contributions).
IMHO these should be removed.
scottilee commentedon Aug 18, 2019
+1 I agree with @oz123 on this.
yliaog commentedon Aug 20, 2019
/cc
oz123 commentedon Aug 20, 2019
So, there seems to be agreement on this here, I will prepare a PR for this.
yliaog commentedon Aug 20, 2019
thanks @oz123 please file a pr for this
oz123 commentedon Aug 25, 2019
@yliaog I created #155 for this, please see if this is OK.
roycaihw commentedon Oct 1, 2019
fixed in #155
/close
k8s-ci-robot commentedon Oct 1, 2019
@roycaihw: Closing this issue.
Details
In response to this:
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.