A file scan reads every file as UTF-8, whatever its Encoding field says
Los mantenedores suelen responder en 1 día
@kz930 ya está trabajando en esto.
Desde el 19/9/2026.
Evaluación
Este issue todavía no se ha evaluado.
Descripción
What happened?
File Scan offers an Encoding field. FileScanSourceOpDesc stores it in its own encoding property, but FileScanSourceOpExec decodes with fileEncoding, the property inherited from ScanSourceOpDesc. The class carries @JsonIgnoreProperties(Array("limit", "offset", "fileEncoding")), so fileEncoding never survives serialization into the executor and is always its default, UTF_8.
Choosing any other charset therefore changes nothing. A UTF-16 file comes back decoded as UTF-8 rather than as its text.
Expected: the executor decodes with the charset the Encoding field names.
How to reproduce?
Deserialize a File Scan descriptor carrying "encoding":"UTF_16", write it out the way getPhysicalOp does, and read it back the way FileScanSourceOpExec does. fileEncoding comes back UTF_8, and the encoding the user chose is the only place UTF-16 survives.
In the UI: upload a UTF-16 text file, drop a File Scan on it, set Encoding to UTF_16 and run. The rows hold the file's bytes read as UTF-8, not its lines.
Version/Branch
1.4.0-incubating-SNAPSHOT (main)
Commit Hash (Optional)
2ab8ee0f2
What browsers are you seeing the problem on?
No response
Relevant log output
JSON = {"operatorType":"FileScan","dummyPropertyList":[],"encoding":"UTF_16","extract":false,"outputFileName":false,"attributeType":"string","attributeName":"line",...}
exec reads desc.fileEncoding = UTF_8
- Lenguaje dominante
- Scala
- Estrellas
- 316
- Forks
- 189
- Merge medio
- 4 d 21 h
- PR fusionados (30 d)
- 162
Preparar el entorno
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de apache/texera
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
apache/texera#8700 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 62/100
apache/texera#8682 · 4 comentarios ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 86/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 84/100
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 82/100
apache/texera#8300 · 3 comentarios ·
Los mantenedores suelen responder en 1 día
Todos los issues de apache/texera
Issues similares
-
bug performance priority:medium regression
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
apache/datafusion-comet#6313 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 1/5 Menos de una hora Aptitud para principiantes 88/100
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 70/100
com-lihaoyi/mill#7624 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
lichess-org/lila#21845 ·
Los mantenedores suelen responder en 1 día
-
bug
Dificultad 2/5 1-3 horas Aptitud para principiantes 72/100
Los mantenedores suelen responder en 1 día