Skip to content

Fix classification file export omitting empty target values#1512

Open
adamnadolny-wizipisi wants to merge 3 commits into
halestudio:masterfrom
adamnadolny-wizipisi:fix/classification-export-empty-values-959
Open

Fix classification file export omitting empty target values#1512
adamnadolny-wizipisi wants to merge 3 commits into
halestudio:masterfrom
adamnadolny-wizipisi:fix/classification-export-empty-values-959

Conversation

@adamnadolny-wizipisi

@adamnadolny-wizipisi adamnadolny-wizipisi commented Jun 22, 2026

Copy link
Copy Markdown
Contributor

Summary

When using "Fill source values with enumeration" in the classification mapping, the resulting CSV/XLS export silently dropped all rows where the target value was not yet mapped. This made it impossible to send a partially-filled classification to an expert for completion.

Root cause: LookupTableImpl constructor filtered out all
ull target values via Predicates.notNull(), so they never reached the export writers.

Fix:

  • Remove the
    otNull() filter in LookupTableImpl so entries with null target values are preserved in the table.
  • Guard
    everse() to skip null values (ArrayListMultimap does not accept null keys).
  • Update CSVLookupWriter and XLSLookupTableWriter to write an empty string instead of calling .as(String.class) on a null Value.

Fixes #959
Submitted by: The Wroclaw Institute of Spatial Information and Artificial Intelligence
(WIZIPISI — Wrocławski Instytut Zastosowań Informacji Przestrzennej i Sztucznej Inteligencji)

Previously the constructor filtered out all entries with null values via
Predicates.notNull(), which caused rows with unmapped target values to be
silently dropped. The reverse() method is guarded to skip null values since
ArrayListMultimap does not accept null keys.

Fixes halestudio#959
Write empty string instead of calling .as(String.class) on a null Value
when exporting rows with no mapped target value.

Fixes halestudio#959
Write empty string instead of calling .as(String.class) on a null Value
when exporting rows with no mapped target value.

Fixes halestudio#959
@adamnadolny-wizipisi
adamnadolny-wizipisi force-pushed the fix/classification-export-empty-values-959 branch from 6312165 to baaf5e6 Compare June 23, 2026 07:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

export classification file doe not include empty target values

1 participant