]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
scripts/oe-setup-layers: do not clobber json module with a variable named 'json'
authorAlexander Kanavin <alex.kanavin@gmail.com>
Sun, 19 Feb 2023 19:30:24 +0000 (20:30 +0100)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Mon, 20 Feb 2023 15:12:24 +0000 (15:12 +0000)
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
scripts/oe-setup-layers

index 6c02262663c4100477a28ad3babf5bf1fb7fa1c5..c8012fa6705eb13597f30bca9f9f42d121bbf8fa 100755 (executable)
@@ -112,10 +112,10 @@ parser.add_argument('--jsondata', default=__file__+".json", help='File containin
 args = parser.parse_args()
 
 with open(args.jsondata) as f:
-    json = json.load(f)
+    json_f = json.load(f)
 
 supported_versions = ["1.0"]
-if json["version"] not in supported_versions:
-    raise Exception("File {} has version {}, which is not in supported versions: {}".format(args.jsondata, json["version"], supported_versions))
+if json_f["version"] not in supported_versions:
+    raise Exception("File {} has version {}, which is not in supported versions: {}".format(args.jsondata, json_f["version"], supported_versions))
 
-_do_checkout(vars(args), json)
+_do_checkout(vars(args), json_f)