From c4c32f0da1e924b897341c17dde44e0f64dfbc59 Mon Sep 17 00:00:00 2001 From: Jake VanderPlas Date: Sun, 9 Feb 2020 09:04:00 -0800 Subject: [PATCH] BUG: fix schema validation error in Python 3.8 --- altair/utils/schemapi.py | 2 +- tools/schemapi/schemapi.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/altair/utils/schemapi.py b/altair/utils/schemapi.py index abfaaf682..88d4bd1ca 100644 --- a/altair/utils/schemapi.py +++ b/altair/utils/schemapi.py @@ -106,7 +106,7 @@ def __str__(self): cls = self.obj.__class__ schema_path = ['{}.{}'.format(cls.__module__, cls.__name__)] schema_path.extend(self.schema_path) - schema_path = '->'.join(val for val in schema_path[:-1] + schema_path = '->'.join(str(val) for val in schema_path[:-1] if val not in ('properties', 'additionalProperties', 'patternProperties')) diff --git a/tools/schemapi/schemapi.py b/tools/schemapi/schemapi.py index 69b222de8..24775fd3e 100644 --- a/tools/schemapi/schemapi.py +++ b/tools/schemapi/schemapi.py @@ -102,7 +102,7 @@ def __str__(self): cls = self.obj.__class__ schema_path = ['{}.{}'.format(cls.__module__, cls.__name__)] schema_path.extend(self.schema_path) - schema_path = '->'.join(val for val in schema_path[:-1] + schema_path = '->'.join(str(val) for val in schema_path[:-1] if val not in ('properties', 'additionalProperties', 'patternProperties'))