Skip to content
This repository was archived by the owner on May 15, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
42 commits
Select commit Hold shift + click to select a range
54a2c93
Rebased on anyHorizontal for errors
roll Oct 28, 2025
52d0461
Drop target names first
roll Oct 28, 2025
34bddd6
Use limit over head
roll Oct 28, 2025
5daf8a5
Added streaming
roll Oct 28, 2025
5e20216
Added p-all
roll Oct 28, 2025
cdec8d5
Updated validateFields/validateData
roll Oct 28, 2025
0264604
Removed dontParse
roll Oct 28, 2025
209e55c
Added narrow TODO
roll Oct 28, 2025
1228a3e
Added error to fieldTable
roll Oct 28, 2025
0ea1269
First working version
roll Oct 28, 2025
5ccaa16
Added fielType to type error
roll Oct 28, 2025
22dac80
Added maxFieldErorrs
roll Oct 28, 2025
92f877c
Updated unique check
roll Oct 28, 2025
2e36936
Updated required check
roll Oct 28, 2025
0045d45
Updated pattern check
roll Oct 28, 2025
8f7f8ec
Updated minLength check
roll Oct 28, 2025
f1994e6
Updated maxLength check
roll Oct 28, 2025
c48e6f3
Updated enum
roll Oct 28, 2025
508e0cd
Updated maximum/minimum
roll Oct 28, 2025
5b0b387
Extended cell errors metadata
roll Oct 29, 2025
c4970f2
Updated browser errors
roll Oct 29, 2025
e8d0540
Rebased on mappings
roll Oct 29, 2025
a56fcd0
Fixed enum tests
roll Oct 29, 2025
719325b
Improved expr naming
roll Oct 29, 2025
0b7cf27
Fixed maximum tests
roll Oct 29, 2025
ff11f37
Fixed tests
roll Oct 29, 2025
5dbede8
Fixed unique row checks
roll Oct 29, 2025
82fc223
Enabled support for `dialect.lineTerminator`
roll Oct 29, 2025
80ae048
Improved nomalizeField
roll Oct 29, 2025
56b4601
Implementd type narrowing from numbers to integers
roll Oct 29, 2025
6175236
Renamed to resolveDialect/Schema
roll Oct 29, 2025
cf9c35b
Infer integers from floats
roll Oct 30, 2025
f381f15
Fixed tests
roll Oct 30, 2025
c334709
Full minimum support
roll Oct 30, 2025
8456e05
Full minimum support
roll Oct 30, 2025
5f9a015
Fixed maxLength and minLength error types
roll Oct 30, 2025
3f70128
Suport date/time in minimum/maximum checks
roll Oct 30, 2025
c1f7cd4
Support year min/max
roll Oct 30, 2025
d9bce96
Removed TODO
roll Oct 30, 2025
39b7c8d
Bootstrapped yearmonth min/max support
roll Oct 30, 2025
89b298e
Support enum parsing
roll Oct 30, 2025
034b021
Added partial enum parsing
roll Oct 30, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions arrow/table/load.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { Resource } from "@dpkit/core"
import { loadResourceSchema } from "@dpkit/core"
import { resolveSchema } from "@dpkit/core"
import { prefetchFiles } from "@dpkit/file"
import type { LoadTableOptions } from "@dpkit/table"
import { inferSchemaFromTable, normalizeTable } from "@dpkit/table"
Expand All @@ -21,7 +21,7 @@ export async function loadArrowTable(
}

if (!options?.denormalized) {
let schema = await loadResourceSchema(resource.schema)
let schema = await resolveSchema(resource.schema)
if (!schema) schema = await inferSchemaFromTable(table, options)
table = await normalizeTable(table, schema)
}
Expand Down
139 changes: 98 additions & 41 deletions browser/components/Report/Error/Cell.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,27 @@ import { useTranslation } from "react-i18next"

export function CellTypeError(props: { error: errorTypes.CellTypeError }) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is not")}
<Code fz="lg" fw="bold">
{[error.fieldType, error.fieldFormat].filter(Boolean).join("/")}
</Code>{" "}
{t("has a wrong type")}
{"type"}
</Text>
)
}
Expand All @@ -27,15 +33,17 @@ export function CellRequiredError(props: {
error: errorTypes.CellRequiredError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("A required cell in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is missing")}
</Text>
Expand All @@ -46,21 +54,27 @@ export function CellMinimumError(props: {
error: errorTypes.CellMinimumError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is less than")}
<Code fz="lg" fw="bold">
{error.minimum}
</Code>{" "}
{t("is less than minimum")}
{t("minimum")}
</Text>
)
}
Expand All @@ -69,21 +83,27 @@ export function CellMaximumError(props: {
error: errorTypes.CellMaximumError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is more than maximum")}
{t("is more than")}
<Code fz="lg" fw="bold">
{error.maximum}
</Code>{" "}
{t("maximum")}
</Text>
)
}
Expand All @@ -92,21 +112,27 @@ export function CellExclusiveMinimumError(props: {
error: errorTypes.CellExclusiveMinimumError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is less or equal to exclusive minimum")}
{t("is less or equal to")}
<Code fz="lg" fw="bold">
{error.minimum}
</Code>{" "}
{t("exclusive minimum")}
</Text>
)
}
Expand All @@ -115,21 +141,27 @@ export function CellExclusiveMaximumError(props: {
error: errorTypes.CellExclusiveMaximumError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is more or equal to exclusive maximum")}
{t("is less or equal to")}
<Code fz="lg" fw="bold">
{error.maximum}
</Code>{" "}
{t("exclusive maximum")}
</Text>
)
}
Expand All @@ -138,21 +170,27 @@ export function CellMinLengthError(props: {
error: errorTypes.CellMinLengthError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Length of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is less than")}
<Code fz="lg" fw="bold">
{error.minLength}
</Code>{" "}
{t("is less than minimum")}
{t("minimum")}
</Text>
)
}
Expand All @@ -161,21 +199,26 @@ export function CellMaxLengthError(props: {
error: errorTypes.CellMaxLengthError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Length of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
<Code fz="lg" fw="bold">
{error.maxLength}
</Code>{" "}
{t("is more than maximum")}
{t("maximum")}
</Text>
)
}
Expand All @@ -184,40 +227,48 @@ export function CellPatternError(props: {
error: errorTypes.CellPatternError
}) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("does not match the")}
<Code fz="lg" fw="bold">
{error.pattern}
</Code>{" "}
{t("does not match the pattern")}
{t("pattern")}
</Text>
)
}

export function CellUniqueError(props: { error: errorTypes.CellUniqueError }) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is not unique")}
</Text>
Expand All @@ -226,21 +277,27 @@ export function CellUniqueError(props: { error: errorTypes.CellUniqueError }) {

export function CellEnumError(props: { error: errorTypes.CellEnumError }) {
const { t } = useTranslation()
const { error } = props

return (
<Text>
{t("Value of the cell")}{" "}
<Code fz="lg" fw="bold">
{props.error.cell}
{error.cell}
</Code>{" "}
{t("in field")}{" "}
<Code fz="lg" fw="bold">
{props.error.fieldName}
{error.fieldName}
</Code>{" "}
{t("of row")}{" "}
<Code fz="lg" fw="bold">
{props.error.rowNumber}
{error.rowNumber}
</Code>{" "}
{t("is not in the allowed")}
<Code fz="lg" fw="bold">
{error.enum.join(", ")}
</Code>{" "}
{t("is not in allowed values")}
{t("values")}
</Text>
)
}
14 changes: 14 additions & 0 deletions browser/locales/de.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,13 +34,27 @@
"has a wrong type": "hat einen falschen Typ",
"A required cell in field": "Eine erforderliche Zelle im Feld",
"is missing": "fehlt",
"is not": "ist nicht",
"is not of the": "ist nicht vom",
"is less than": "ist kleiner als",
"minimum": "Minimum",
"is more than": "ist größer als",
"maximum": "Maximum",
"is less or equal to": "ist kleiner oder gleich",
"exclusive minimum": "exklusives Minimum",
"is more or equal to": "ist größer oder gleich",
"exclusive maximum": "exklusives Maximum",
"is less than minimum": "ist kleiner als das Minimum",
"is more than maximum": "ist größer als das Maximum",
"is less or equal to exclusive minimum": "ist kleiner oder gleich dem exklusiven Minimum",
"is more or equal to exclusive maximum": "ist größer oder gleich dem exklusiven Maximum",
"Length of the cell": "Länge der Zelle",
"does not match the": "stimmt nicht überein mit",
"pattern": "Muster",
"does not match the pattern": "stimmt nicht mit dem Muster überein",
"is not unique": "ist nicht eindeutig",
"is not in the allowed": "ist nicht in den erlaubten",
"values": "Werten",
"is not in allowed values": "ist nicht in den erlaubten Werten",
"Field name is expected to be": "Feldname soll sein",
"but it is actually": "aber es ist tatsächlich",
Expand Down
Loading