fixed quoting in load

This commit is contained in:
Abubakar Abid 2022-03-17 10:39:50 -07:00
parent 7a43afa8ee
commit 0eefdaaf37

View File

@ -54,7 +54,7 @@ def cache_interface_examples(interface: Interface) -> None:
def load_from_cache(interface: Interface, example_id: int) -> List[Any]: def load_from_cache(interface: Interface, example_id: int) -> List[Any]:
"""Loads a particular cached example for the interface.""" """Loads a particular cached example for the interface."""
with open(CACHE_FILE) as cache: with open(CACHE_FILE) as cache:
examples = list(csv.reader(cache)) examples = list(csv.reader(cache, quotechar="'"))
example = examples[example_id + 1] # +1 to adjust for header example = examples[example_id + 1] # +1 to adjust for header
output = [] output = []
for component, cell in zip(interface.output_components, example): for component, cell in zip(interface.output_components, example):