Originally reported here: T188291#8279218
The relevant code can be seen in https://github.com/nyurik/wd-type-parser/blob/master/src/wikidataTypeParser.js#L49. It returns undefined. This currently ends in the final GeoJSON object as { coordinates: undefined }, which will be stringyfied to "geometry": { "type": "Point" }, which is not valid GeoJSON. All this happens after the sanitize-mapdata API was called.
Example page with this issue: https://www.wikidata.org/w/index.php?title=User:Ayack/Draft&oldid=1741989429