# Luxembourg (LU) — internal licensing notes

## Source research, 2026-09-02 — sellability + reproducibility audit

**Clean GO.** GeoNames' postal export carries both admin tiers Luxembourg
has (canton, commune) — no gap to fill, no second source needed. Same shape
as AT's audit.

### The source — GeoNames LU

```
https://download.geonames.org/export/zip/LU.zip      # 4,519 rows
```

Licence **CC-BY-4.0**, verified against `export/zip/readme.txt` on
2026-09-02 — Luxembourg carries no per-country caveat (the readme's only
restricted countries are GB, CL, CN, IE, MT, AR, BR).

**Verified directly against the raw source file:**
- `admin_name1`/`admin_code1` — Canton, 12/12 covered (Capellen…Wiltz),
  GeoNames' own 2-letter code (`CA`…`WI`).
- `admin_name2` — Commune, 105 distinct values, `admin_code2` is a
  **per-canton sequence number** (e.g. "01" repeats across many different
  cantons) — not a globally unique commune code, so it cannot be used alone
  as part of a primary key.
- `admin_name3`/`admin_code3` — **always empty**. Luxembourg's postal
  source has no third admin tier at all (unlike AT, which has Gemeinde as
  admin3) — confirmed empty on all 4,519 rows, not a partial-coverage gap.
- 1 (postal_code, place_name) pair collides: "Blumenthal" at `L-7639` is
  listed twice — once under Bech/Echternach canton, once under
  Junglinster/Grevenmacher canton — a real border locality straddling a
  commune/canton boundary, same pattern as AT's Weissenbach. Real primary
  key is (postal_code, place_name, admin_name2), verified unique across all
  4,519 rows.

**ISO 3166-2:LU derivation verified 2026-09-02** against Wikipedia's
ISO_3166-2:LU page: GeoNames' own canton codes (`CA`, `CL`, `DI`, `EC`,
`ES`, `GR`, `LU`, `ME`, `RD`, `RM`, `VD`, `WI`) map 1:1, letter-for-letter,
onto the ISO codes (just prepend `LU-`) — even simpler than AT's numeric
crosswalk, no ambiguity.

## licence_status

```json
{
  "channel": "postal-codes-r2",
  "source_url": "https://download.geonames.org/export/zip/LU.zip",
  "licence_id": "CC-BY-4.0",
  "collected_at": "2026-09-02",
  "decision": "compatible",
  "decided_by": "claude-session-2026-09-02",
  "decided_at": "2026-09-02"
}
```

## Proposed tier

**B ($49).** Single official-quality source (GeoNames) normalised in
place — real work (ISO code derivation, admin-tier cleanup) but no second
authoritative provider consolidated onto it. Same shape as AT/IT/PH.

## What was already live before this rebuild

The prior `lu/lu.csv` on R2 (381,661 bytes, dated 2026-07-30) was NOT the
"100-row sample, contact sales" placeholder the old `datapackage.yml`/
`README.md` claimed — it was the full 4,519-row GeoNames extract, just with
the standard legacy corruption: literal `"nan"` strings in every row's
`admin_name3` (round-tripped through pandas from an empty upstream field),
and float-formatted accuracy (`"4.0"`/`"6.0"` instead of `"4"`/`"6"`). No
`.licensing-notes.md`, no `licence_status`, no `ATTRIBUTION.txt` existed
before this pass — LU had never been through this project's proper rebuild.

## Verdict

**Build it.** No licensing obstacle, no coverage gap.

## Build — 2026-09-02 (local only, not published)

Built via `datasets/lu/scripts/build_postal_codes_product.py`.

| | value |
|---|---|
| Final rows | 4,519 |
| Cantons covered | 12/12 |
| Communes | 105 |
| Distinct postal codes | 4,330 |
| Rows with empty admin2 | 0 |
| Rows with empty admin3 | 4,519 (no third tier exists in the source at all) |

Frictionless validation: `valid: True`. Zero literal `"nan"` strings, zero
float-formatted accuracy values, zero duplicates on the real primary key
(postal_code, place_name, admin_name2).

**Status: built and validated locally only.** Nothing published to R2,
nothing committed to git. `datasets/lu/README.md` and `datapackage.yml`
updated in place (tier B, `premium_source_key: lu/lu.zip`, real
`sources`/`licenses`/`licence_status`, replacing the stale "100-row sample"
placeholder text).
