Commit 6fbee287 authored by Pierre Dittgen's avatar Pierre Dittgen
Browse files
parent ed807aa8
......@@ -5,6 +5,7 @@ from pathlib import Path
from typing import Dict, Union
import frictionless
from frictionless.plugins.excel import ExcelDialect
from .error_messages import error_translate
......@@ -99,6 +100,8 @@ class FileContentValidataResource(ValidataResource):
if format in {"csv", "tsv"}:
options["encoding"] = ValidataResource.detect_encoding(self.content)
if format in {"xlsx"}:
options["dialect"] = ExcelDialect(preserve_formatting=True)
source = self.content
return (source, options)
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment