-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
DataclassReader fails to read a csv file when there are quotes around column names in header.
Example error output (notice how the column names are identical, except the file fields have quotes around them):
Traceback (most recent call last):
File "/Users/.../main.py", line 5, in <module>
movie = next(movies)
File "/Users/.../movie.py", line 57, in tmdb_dataset
reader = DataclassReader(csv_file, Movie)
File "/Users/.../dataclass_io/dataclass_io/reader.py", line 44, in __init__
assert_file_header_matches_dataclass(
File "/Users/.../dataclass_io/dataclass_io/_lib/assertions.py", line 122, in assert_file_header_matches_dataclass
raise ValueError(
ValueError: The provided file does not have the same field names as the provided dataclass:
Dataclass: Movie
Dataclass fields: id, title, vote_average, vote_count, status, release_date, revenue, runtime, adult, backdrop_path, budget, homepage, imdb_id, original_language, original_title, overview, popularity, poster_path, tagline, genres, production_companies, production_countries, spoken_languages, keywords
File fields: "id","title","vote_average","vote_count","status","release_date","revenue","runtime","adult","backdrop_path","budget","homepage","imdb_id","original_language","original_title","overview","popularity","poster_path","tagline","genres","production_companies","production_countries","spoken_languages","keywords"
Metadata
Metadata
Assignees
Labels
No labels