GeoPackage cannot read geometries with Z ordinates

Description

Unable to use sewer dataset from the official site: http://www.geopackage.org/data/simple_sewer_features.gpkg

From Erik Merkle's initial investigation:

It appears this GeoPackage file is WKB encoded with Z data, but the JTS WKBReader used in GeoTools isn't parsing it correclty.
[cut from Slack]
I haven't found much on WKB 237, however in the WKBReader code, it looks like it tries to parse out the geometry type:
int typeInt = dis.readInt();
int geometryType = typeInt & 0xff;
the typeInt is 1005 (decimal), when masked with 0xff is 237
From here: https://en.wikipedia.org/wiki/Well-known_text, it seems like 1005 is a MultiLineString with Z data.
Seems this is a known limitation of the JTS library: https://lists.osgeo.org/pipermail/geos-devel/2013-December/006757.html
it doesn't understand 4 digit geometry codes

Environment

None

Assignee

Unassigned

Reporter

Bart van den Eijnden

Triage

Fix versions

Priority

Medium
Configure