if you have such kind of problems it's best to decompose the line in question and you will normally find the error. or have a clearer understanding. example line1: v = uuid.uuid4() line 2: v = v.hex() line 3: v = v.upper() line 4: v = v[0:6]` ; line 5 : random = str(v) What's also important is to show us the import line, that you were using for uuid.
v = uuid.uuid4()line 2:v = v.hex()line 3:v = v.upper()line 4: v = v[0:6]` ; line 5 :random = str(v)What's also important is to show us the import line, that you were using for uuid.