Tippecanoe metadata file ignoring columns with only null values
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 3.1k
- Forks
- 430
- PR merge metrics
- No merged PRs in 30d
Description
@ericfischer I'm not sure if this is a feature or a bug, but I've been automating the process of converting geojson to tiles using real life (ie, messy) datasets. One thing I've found is that when a field contains only null values for all features, Tippecanoe adds the field to each feature, but ignores the data for the metadata file.
This is a problem for me, as I use the metadata file to format the information from each feature when a feature is selected. I tried using the -pe tag to see if it would retain the column in the metadata, but that didn't seem to do what I was hoping.
I've attached an example zip file which contains two JSON files--an example input JSON and an output metadata file--so that you can try it for yourself. You'll note that a few of the fields are ignored in the metadata but still show up for each feature.
Example input JSON & metadata:
example.zip
Here's the exact command I'm using if that helps:
tippecanoe -f --tile-stats-values-limit=100 -Z9 -Q -z14 -M 2500000 -aN -aD -pS -rg -e <OUTPUT DIR> -ag <INPUT FILE>
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the behavior with the attached example.zip, using the exact tippecanoe command in the issue. Trace the metadata generation path and compare its handling of all-null columns with the feature properties. Done means those columns remain represented in the metadata while preserving the existing feature output.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- data
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100