csv delimiter fix
This commit is contained in:
parent
3046b1ee7b
commit
fbdb6f9f5a
2 changed files with 5 additions and 2 deletions
support_formatter/logic
|
@ -15,7 +15,10 @@ def process_csv(path: pathlib.Path):
|
|||
data, entries = {}, []
|
||||
|
||||
with open(path, "r") as csv_file:
|
||||
csv_reader = csv.DictReader(csv_file)
|
||||
dialect = csv.Sniffer().sniff(csv_file.read(1024), delimiters=";,")
|
||||
csv_file.seek(0)
|
||||
|
||||
csv_reader = csv.DictReader(csv_file, dialect=dialect)
|
||||
csv_type = determine_type(csv_reader.fieldnames)
|
||||
|
||||
if csv_type == "unknown":
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue