diff mbox series

[isar-cip-core] Drop redundant expand=True parameter from getVar

Message ID 20230524094724.1953389-1-srinuvasan_a@mentor.com (mailing list archive)
State Accepted
Headers show
Series [isar-cip-core] Drop redundant expand=True parameter from getVar | expand

Commit Message

Srinuvasan Arjunan May 24, 2023, 9:47 a.m. UTC
From: Srinuvasan A <srinuvasan.a@siemens.com>

It is long True by default, but people keep adding new cases of this
redundancy, hence fix this one.

Signed-off-by: Srinuvasan A <srinuvasan.a@siemens.com>
---
 classes/image_uuid.bbclass | 2 +-
 classes/swupdate.bbclass   | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

Comments

Felix Moessbauer May 26, 2023, 6:35 a.m. UTC | #1
On Wed, 2023-05-24 at 15:17 +0530, Srinuvasan Arjunan wrote:
> From: Srinuvasan A <srinuvasan.a@siemens.com>
> 
> It is long True by default, but people keep adding new cases of this
> redundancy, hence fix this one.

Oh yes... Thanks. I also can't remember that this changed in bitbake.
Acked!

Felix
> 
> Signed-off-by: Srinuvasan A <srinuvasan.a@siemens.com>
> ---
>  classes/image_uuid.bbclass | 2 +-
>  classes/swupdate.bbclass   | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/classes/image_uuid.bbclass b/classes/image_uuid.bbclass
> index 9ffe14d..f6b631f 100644
> --- a/classes/image_uuid.bbclass
> +++ b/classes/image_uuid.bbclass
> @@ -18,7 +18,7 @@ inherit image
>  def generate_image_uuid(d):
>      import uuid
>  
> -    base_hash = d.getVar("BB_TASKHASH", True)
> +    base_hash = d.getVar("BB_TASKHASH")
>      if base_hash is None:
>          return None
>      return str(uuid.UUID(base_hash[:32], version=4))
> diff --git a/classes/swupdate.bbclass b/classes/swupdate.bbclass
> index 9a4d509..1056ab5 100644
> --- a/classes/swupdate.bbclass
> +++ b/classes/swupdate.bbclass
> @@ -67,7 +67,7 @@ python(){
>  
>  # convert between swupdate compressor name and imagetype extension
>  def get_swu_compression_type(d):
> -    swu_ct = d.getVar('SWU_COMPRESSION_TYPE', True)
> +    swu_ct = d.getVar('SWU_COMPRESSION_TYPE')
>      if not swu_ct:
>          return ''
>      swu_to_image = {'zlib': '.gz', 'zstd': '.zst'}
Jan Kiszka May 27, 2023, 4:52 p.m. UTC | #2
On 24.05.23 11:47, Srinuvasan Arjunan wrote:
> From: Srinuvasan A <srinuvasan.a@siemens.com>
> 
> It is long True by default, but people keep adding new cases of this
> redundancy, hence fix this one.
> 
> Signed-off-by: Srinuvasan A <srinuvasan.a@siemens.com>
> ---
>  classes/image_uuid.bbclass | 2 +-
>  classes/swupdate.bbclass   | 2 +-
>  2 files changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/classes/image_uuid.bbclass b/classes/image_uuid.bbclass
> index 9ffe14d..f6b631f 100644
> --- a/classes/image_uuid.bbclass
> +++ b/classes/image_uuid.bbclass
> @@ -18,7 +18,7 @@ inherit image
>  def generate_image_uuid(d):
>      import uuid
>  
> -    base_hash = d.getVar("BB_TASKHASH", True)
> +    base_hash = d.getVar("BB_TASKHASH")
>      if base_hash is None:
>          return None
>      return str(uuid.UUID(base_hash[:32], version=4))
> diff --git a/classes/swupdate.bbclass b/classes/swupdate.bbclass
> index 9a4d509..1056ab5 100644
> --- a/classes/swupdate.bbclass
> +++ b/classes/swupdate.bbclass
> @@ -67,7 +67,7 @@ python(){
>  
>  # convert between swupdate compressor name and imagetype extension
>  def get_swu_compression_type(d):
> -    swu_ct = d.getVar('SWU_COMPRESSION_TYPE', True)
> +    swu_ct = d.getVar('SWU_COMPRESSION_TYPE')
>      if not swu_ct:
>          return ''
>      swu_to_image = {'zlib': '.gz', 'zstd': '.zst'}

Thanks, applied.

Jan
diff mbox series

Patch

diff --git a/classes/image_uuid.bbclass b/classes/image_uuid.bbclass
index 9ffe14d..f6b631f 100644
--- a/classes/image_uuid.bbclass
+++ b/classes/image_uuid.bbclass
@@ -18,7 +18,7 @@  inherit image
 def generate_image_uuid(d):
     import uuid
 
-    base_hash = d.getVar("BB_TASKHASH", True)
+    base_hash = d.getVar("BB_TASKHASH")
     if base_hash is None:
         return None
     return str(uuid.UUID(base_hash[:32], version=4))
diff --git a/classes/swupdate.bbclass b/classes/swupdate.bbclass
index 9a4d509..1056ab5 100644
--- a/classes/swupdate.bbclass
+++ b/classes/swupdate.bbclass
@@ -67,7 +67,7 @@  python(){
 
 # convert between swupdate compressor name and imagetype extension
 def get_swu_compression_type(d):
-    swu_ct = d.getVar('SWU_COMPRESSION_TYPE', True)
+    swu_ct = d.getVar('SWU_COMPRESSION_TYPE')
     if not swu_ct:
         return ''
     swu_to_image = {'zlib': '.gz', 'zstd': '.zst'}