uboot-sign.bbclass: Remove tab indentations in python code
cover uboot-sign.bbclass: Remove tab indentations in python code
Note, I send this patch separately is because it depends on another patch of mine which was sent on Wed.:
uboot-sign.bbclass: fix signature and deployment
// Robert
The following changes since commit d29e9922e750bc1637f4fe454f4cc6dcfb74f09a:
uboot-sign.bbclass: fix signature and deployment (2018-11-23 19:05:39 +0800)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib rbt/uboot_py
http://cgit.openembedded.org/openembedded-core-contrib/log/?h=rbt/uboot_py
Robert Yang (1):
uboot-sign.bbclass: Remove tab indentations in python code
meta/classes/uboot-sign.bbclass | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
Signature · 1 line
2.7.4
PATCH 1/1 uboot-sign.bbclass: Remove tab indentations in python code
Use 4 spaces to replace a tab.
--- meta/classes/uboot-sign.bbclass | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)
meta/classes/uboot-sign.bbclass +8 -8
@@ -93,14 +93,14 @@ do_install_append() { } python () { - if d.getVar('UBOOT_SIGN_ENABLE') == '1' and d.getVar('PN') == d.getVar('UBOOT_PN'): - kernel_pn = d.getVar('PREFERRED_PROVIDER_virtual/kernel') + if d.getVar('UBOOT_SIGN_ENABLE') == '1' and d.getVar('PN') == d.getVar('UBOOT_PN'): + kernel_pn = d.getVar('PREFERRED_PROVIDER_virtual/kernel') - # Make "bitbake u-boot -cdeploy" deploys the signed u-boot.dtb - d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' % kernel_pn) + # Make "bitbake u-boot -cdeploy" deploys the signed u-boot.dtb + d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' % kernel_pn) - # kernerl's do_deploy is a litle special, so we can't use - # do_deploy_append, otherwise it would override - # kernel_do_deploy. - d.appendVarFlag('do_deploy', 'prefuncs', ' concat_dtb') + # kernerl's do_deploy is a litle special, so we can't use + # do_deploy_append, otherwise it would override + # kernel_do_deploy. + d.appendVarFlag('do_deploy', 'prefuncs', ' concat_dtb') }
Signature · 1 line
2.7.4
I wish we could have the same warning for shell code as well :).
Can you please take care of meta-gplv2 as well?
WARNING: meta-gplv2/recipes-core/coreutils/coreutils_6.9.bb: python should use 4 spaces indentation, but found tabs in coreutils_6.9.bb, line 95
I've sent patch for meta-oe issue:
http://lists.openembedded.org/pipermail/openembedded-devel/2018-December/197803.html
Quoted 49 lines · Robert Yang
Use 4 spaces to replace a tab.
Signed-off-by Robert Yang <[email protected]>--- meta/classes/uboot-sign.bbclass | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)meta/classes/uboot-sign.bbclass +0
-1@@ -93,14 +93,14 @@ do_install_append() { } python () { - if d.getVar('UBOOT_SIGN_ENABLE') == '1' and d.getVar('PN') ==
d.getVar('UBOOT_PN'):meta/classes/uboot-sign.bbclass +1
-1- kernel_pn = d.getVar('PREFERRED_PROVIDER_virtual/kernel') + if d.getVar('UBOOT_SIGN_ENABLE') == '1' and d.getVar('PN') ==
d.getVar('UBOOT_PN'):meta/classes/uboot-sign.bbclass +1
-1+ kernel_pn = d.getVar('PREFERRED_PROVIDER_virtual/kernel') - # Make "bitbake u-boot -cdeploy" deploys the signedu-boot.dtb
- d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' %kernel_pn)meta/classes/uboot-sign.bbclass +2
-0+ # Make "bitbake u-boot -cdeploy" deploys the signed u-boot.dtb + d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' %
kernel_pn)meta/classes/uboot-sign.bbclass +4
-5- # kernerl's do_deploy is a litle special, so we can't use - # do_deploy_append, otherwise it would override - # kernel_do_deploy. - d.appendVarFlag('do_deploy', 'prefuncs', ' concat_dtb') + # kernerl's do_deploy is a litle special, so we can't use + # do_deploy_append, otherwise it would override + # kernel_do_deploy. + d.appendVarFlag('do_deploy', 'prefuncs', ' concat_dtb') } --2.7.4
--
_______________________________________________
Openembedded-core mailing list
[email protected]
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Hi Martin,
Quoted 2 lines · Martin Jansa
I wish we could have the same warning for shell code as well :).
According to oe's Format Guidelines:
https://www.openembedded.org/wiki/Styleguide#Format_Guidelines
- Python functions must be four space indented - no tabs.
- Shell functions in OE-Core usually use tabs for indentation, but other layers usually use consistent indentation with 4 spaces (in shell functions, python functions and for indentation of multi-line variables)
So I think that shell code can use either spaces or tabs as indentation.
Quoted 2 lines
Can you please take care of meta-gplv2 as well?
WARNING: meta-gplv2/recipes-core/coreutils/coreutils_6.9.bb <http://coreutils_6.9.bb>: python should use 4 spaces indentation, but found tabs in coreutils_6.9.bb <http://coreutils_6.9.bb>, line 95
Thanks, I've sent a patch for it.
// Robert
Quoted 55 lines
I've sent patch for meta-oe issue:
http://lists.openembedded.org/pipermail/openembedded-devel/2018-December/197803.htmlOn Fri, Nov 23, 2018 at 11:51 AM Robert Yang <[email protected] <mailto:[email protected]>> wrote:
Use 4 spaces to replace a tab.
Signed-off-by Robert Yang <[email protected]<mailto:[email protected]>>
---
meta/classes/uboot-sign.bbclass | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)diff --git a/meta/classes/uboot-sign.bbclass b/meta/classes/uboot-sign.bbclass index 0e5e1b1..03100b8 100644
--- a/meta/classes/uboot-sign.bbclass
+++ b/meta/classes/uboot-sign.bbclass
@@ -93,14 +93,14 @@do_install_append(){
}python () {
- ifd.getVar('UBOOT_SIGN_ENABLE')== '1' andd.getVar('PN')==d.getVar('UBOOT_PN'):
- kernel_pn =d.getVar('PREFERRED_PROVIDER_virtual/kernel')+ ifd.getVar('UBOOT_SIGN_ENABLE')== '1' andd.getVar('PN')==d.getVar('UBOOT_PN'):
+kernel_pn=d.getVar('PREFERRED_PROVIDER_virtual/kernel')- # Make "bitbake u-boot -cdeploy" deploys the signed u-boot.dtb - d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' %
kernel_pn)
+ # Make "bitbake u-boot -cdeploy" deploys the signed u-boot.dtb +d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' % kernel_pn)- # kernerl's
do_deployis a litle special, so we can't use - #do_deploy_append, otherwise it would override - #kernel_do_deploy.
- d.appendVarFlag('do_deploy', 'prefuncs', 'concat_dtb') + # kernerl'sdo_deployis a litle special, so we can't use + #do_deploy_append, otherwise it would override
+ #kernel_do_deploy.
+d.appendVarFlag('do_deploy', 'prefuncs', ' concat_dtb')
}
--
2.7.4--
_______________________________________________
Openembedded-core mailing list [email protected] <mailto:[email protected]>
http://lists.openembedded.org/mailman/listinfo/openembedded-core
Quoted 1 line
So I think that shell code can use either spaces or tabs as indentation.
True, that's why I used "I wish" and ":)" because as Christmas gift I always wanted consistency (not only between layers, but between shell and python code as well).
Quoted 96 lines · Robert Yang
Hi Martin,
Quoted 2 lines · Martin Jansa
I wish we could have the same warning for shell code as well :).
According to oe's Format Guidelines:
https://www.openembedded.org/wiki/Styleguide#Format_Guidelines
- Python functions must be four space indented - no tabs.
- Shell functions in OE-Core usually use tabs for indentation, but other layers
usually use consistent indentation with 4 spaces (in shell functions, python
functions and for indentation of multi-line variables)So I think that shell code can use either spaces or tabs as indentation.
Quoted 3 lines
Can you please take care of meta-gplv2 as well?
WARNING: meta-gplv2/recipes-core/coreutils/coreutils_6.9.bb
<http://coreutils_6.9.bb>: python should use 4 spaces indentation, butfound
Quoted 1 line
tabs in coreutils_6.9.bb <http://coreutils_6.9.bb>, line 95
Thanks, I've sent a patch for it.
// Robert
Quoted 3 lines
I've sent patch for meta-oe issue:
http://lists.openembedded.org/pipermail/openembedded-devel/2018-December/197803.html
Quoted 7 lines
On Fri, Nov 23, 2018 at 11:51 AM Robert Yang <[email protected] <mailto:[email protected]>> wrote:
Use 4 spaces to replace a tab.
Quoted 7 lines
Signed-off-by Robert Yang <[email protected]<mailto:[email protected]>>
---
meta/classes/uboot-sign.bbclass | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-)diff --git a/meta/classes/uboot-sign.bbclass
b/meta/classes/uboot-sign.bbclass
Quoted 10 lines
index 0e5e1b1..03100b8 100644 --- a/meta/classes/uboot-sign.bbclass +++ b/meta/classes/uboot-sign.bbclass @@ -93,14 +93,14 @@ do_install_append() { } python () { - if d.getVar('UBOOT_SIGN_ENABLE') == '1' and d.getVar('PN') == d.getVar('UBOOT_PN'): - kernel_pn =
d.getVar('PREFERRED_PROVIDER_virtual/kernel')Quoted 5 lines
+ if
d.getVar('UBOOT_SIGN_ENABLE')== '1' andd.getVar('PN')==
d.getVar('UBOOT_PN'):
+kernel_pn=d.getVar('PREFERRED_PROVIDER_virtual/kernel')- # Make "bitbake u-boot -cdeploy" deploys the signed
u-boot.dtb
Quoted 1 line
- d.appendVarFlag('do_deploy', 'depends', '
%s:do_deploy' %
Quoted 2 lines
kernel_pn)
+ # Make "bitbake u-boot -cdeploy" deploys the signedu-boot.dtb
Quoted 1 line
+ d.appendVarFlag('do_deploy', 'depends', ' %s:do_deploy' %
kernel_pn)Quoted 2 lines
- # kernerl's
do_deployis a litle special, so wecan't use
Quoted 3 lines
- # do_deploy_append, otherwise it would override - # kernel_do_deploy. - d.appendVarFlag('do_deploy', 'prefuncs', '
concat_dtb')Quoted 15 lines
+ # kernerl's do_deploy is a litle special, so we can't use + # do_deploy_append, otherwise it would override + # kernel_do_deploy. + d.appendVarFlag('do_deploy', 'prefuncs', ' concat_dtb') } -- 2.7.4 -- _______________________________________________ Openembedded-core mailing list [email protected] <mailto:[email protected]> http://lists.openembedded.org/mailman/listinfo/openembedded-core
✗ patchtest: failure for uboot-sign.bbclass: Remove tab indentations in python code
In reply to Robert Yang== Series Details ==
Series: uboot-sign.bbclass: Remove tab indentations in python code
Revision: 1
URL : https://patchwork.openembedded.org/series/15061/
State : failure
== Summary ==
Thank you for submitting this patch series to OpenEmbedded Core. This is an automated response. Several tests have been executed on the proposed series by patchtest resulting in the following failures:
* Issue Series does not apply on top of target branch [test_series_merge_on_head]
Suggested fix Rebase your series on top of targeted branch
Targeted branch master (currently at c80972be1f)
If you believe any of these test results are incorrect, please reply to the mailing list ([email protected]) raising your concerns. Otherwise we would appreciate you correcting the issues and submitting a new version of the patchset if applicable. Please ensure you add/increment the version number when sending the new version (i.e. [PATCH] -> [PATCH v2] -> [PATCH v3] -> ...).
---
Guidelines: https://www.openembedded.org/wiki/Commit_Patch_Message_Guidelines Test framework: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest Test suite: http://git.yoctoproject.org/cgit/cgit.cgi/patchtest-oe