akvo / akvo-flow

A data collection and monitoring tool that works anywhere.
http://akvo.org/products/akvoflow/
GNU Affero General Public License v3.0
65 stars 31 forks source link

Broken validation of the GEOLON and GEOLAT headers when importing reports #3554

Closed muloem closed 4 years ago

muloem commented 4 years ago

Context

When exporting data cleaning reports, GEO questions are split into three columns corresponding to the latitude, longitude and elevation. The headers for these columns are generated as show in the code snippet below. https://github.com/akvo/akvo-flow/blob/37a7787b23fd3de0d2c3a88808ef475455933f80/GAE/src/org/waterforpeople/mapping/dataexport/GraphicalSurveySummaryExporter.java#L1605-L1609

Problem or idea

The corresponding import for data cleaning does not match with the above generated format, so a report with a valid GEO header fails in the import with the error Cannot import data from Column X - "--GEOLON--|Longitude". Please check and/or fix the header cell https://github.com/akvo/akvo-flow/blob/37a7787b23fd3de0d2c3a88808ef475455933f80/GAE/src/org/waterforpeople/mapping/dataexport/RawDataSpreadsheetImporter.java#L87

Solution or next step

Given that reports are constantly being generated, either we need to ensure that both the newly specified format and the old format are supported, or revert the import format to match the existing header GEO column header format.

muloem commented 4 years ago

The issue is verified to exist on test environments

iperdomo commented 4 years ago

Tested import in UAT2 and Flow services in test cluster

iperdomo commented 4 years ago

The fix has been promoted to production service:

https://travis-ci.org/github/akvo/akvo-flow-services/builds/681971560

iperdomo commented 4 years ago

The fix was also tested in beta1 instance (using production Flow services)