Error uploading points with no altitude
I have a logging job in PhoneTrack (Samsung S5, LineageOS) which logs points to Nextcloud Maps. This job has stopped being able to upload any more points, to the server, with error "Uploading failed: Server response error". Looking at nextcloud.log, it seems to have collected a point or points with no altitude associated.
{
"reqId": "XatwKtxl-MGLhcVnel3ceQAAAIE",
"level": 3,
"time": "2019-10-19T20:20:59+00:00",
"remoteAddr": "192.168.0.191",
"user": "russ",
"app": "index",
"method": "POST",
"url": "/nextcloud/index.php/apps/maps/api/1.0/devices?altitude=&lng=0.0449479&accuracy=1399.9990234375&battery=60.0&lat=0.9480927&user_agent=SM-G900F+%28PhoneTrack%2FAndroid%29×tamp=1571330229",
"message": {
"Exception": "Doctrine\\DBAL\\Exception\\DriverException",
"Message": "An exception occurred while executing 'INSERT INTO `oc_maps_device_points` (`device_id`, `lat`, `lng`, `timestamp`, `altitude`, `battery`, `accuracy`) VALUES(?, ?, ?, ?, ?, ?, ?)' with params [7, \"0.9480927\", \"0.0449479\", \"1571330229\", \"\", \"60.0\", \"1399.9990234375\"]:\n\nSQLSTATE[22007]: Invalid datetime format: 1366 Incorrect double value: '' for column `nextcloud`.`oc_maps_device_points`.`altitude` at row 1",
"Code": 0,
"Trace": [
{
"file": "/var/www/html/3rdparty/doctrine/dbal/lib/Doctrine/DBAL/DBALException.php",
"line": 169,
"function": "convertException",
"class": "Doctrine\\DBAL\\Driver\\AbstractMySQLDriver",
"type": "->",
"args": [
"An exception occurred while executing 'INSERT INTO `oc_maps_device_points` (`device_id`, `lat`, `lng`, `timestamp`, `altitude`, `battery`, `accuracy`) VALUES(?, ?, ?, ?, ?, ?, ?)' with params [7, \"0.9480927\", \"0.0449479\", \"1571330229\", \"\", \"60.0\", \"1399.9990234375\"]:\n\nSQLSTATE[22007]: Invalid datetime format: 1366 Incorrect double value: '' for column `nextcloud`.`oc_maps_device_points`.`altitude` at row 1",
{
"errorInfo": [
"22007",
1366,
"Incorrect double value: '' for column `nextcloud`.`oc_maps_device_points`.`altitude` at row 1"
],
"__class__": "Doctrine\\DBAL\\Driver\\PDOException"
}
]
}
...snip...
]
},
"userAgent": "Mozilla/5.0 (Android) Nextcloud-android/3.8.1",
"version": "17.0.0.9"
}
Looking at the accuracy
I wonder if this is a location from the network rather than GPS.
Edited by Russ