From 4465dc29bb229fbe58a320421b493f9c8257d6c0 Mon Sep 17 00:00:00 2001 From: Roland Dobai Date: Thu, 20 Sep 2018 12:01:54 +0200 Subject: [PATCH] partition_table: Fix encoding for Python 2.7.3 struct.pack can handle Unicode argument in latest Python 2.7 but cannot (at least) in 2.7.3. --- components/partition_table/gen_esp32part.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/partition_table/gen_esp32part.py b/components/partition_table/gen_esp32part.py index cc748b9f1..7d7f34ad4 100755 --- a/components/partition_table/gen_esp32part.py +++ b/components/partition_table/gen_esp32part.py @@ -355,7 +355,7 @@ class PartitionDefinition(object): if self.name in all_subtype_names and SUBTYPES.get(self.type, {}).get(self.name, "") != self.subtype: critical("WARNING: Partition has name '%s' which is a partition subtype, but this partition has non-matching type 0x%x and subtype 0x%x. Mistake in partition table?" % (self.name, self.type, self.subtype)) - STRUCT_FORMAT = "<2sBBLL16sL" + STRUCT_FORMAT = b"<2sBBLL16sL" @classmethod def from_binary(cls, b):