atlas-checks icon indicating copy to clipboard operation
atlas-checks copied to clipboard

SCRIPTS: Add script to merge geojson files and format them in a MapRoulette tag fix friendly way

Open tsmock opened this issue 5 years ago • 2 comments

Description:

This is a script I wrote awhile back to convert multiple geojson files into a single geojson file. To help with uploading to MapRoulette, there is also a command line flag that converts the geojson files into RFC7464 compliant line-by-line geojson. As a followup on #361 , I modified the script to also convert basic fix_suggestions into MapRoulette cooperative challenges when outputting RFC7464 compliant geojson in order to help me validate the fix suggestion changes I made to the InvalidTagsCheck class.

There are a couple of TODO comments scattered throughout the file, mostly to do with investigating some edge cases (will Polygons always be a way, or may they occasionally be a relation? -- looking at identifiers would probably work for this as well).

This is partially related to #365 .

Potential Impact:

N/A

Unit Test Approach:

N/A

Test Results:

N/A

tsmock avatar Sep 30 '20 13:09 tsmock

Kudos, SonarCloud Quality Gate passed!

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities (and Security Hotspot 0 Security Hotspots to review)
Code Smell A 0 Code Smells

No Coverage information No Coverage information
No Duplication information No Duplication information

sonarqubecloud[bot] avatar Sep 30 '20 13:09 sonarqubecloud[bot]

Is there any reason why you're using the geojson output as opposed to the .log files that are already line-delimited? I know the log files unfortunately aren't separated by check and take some work to get the files organized that way.

Mostly because it was easier to work with organized checks to create MapRoulette tasks (when I first made the script, all I wanted to do was merge a specific check's files together -- I often run multiple checks instead of just the one I'm working on, to make certain I didn't accidentally break something). It eventually grew into what it is now, step by step. I added the write_feature_rfc7464 function when I had some issues uploading rather large files to MapRoulette, and then I added the fix_suggestions_to_cooperativeWork function when I wanted to ensure that the fixes I was working on would "just work (tm)".

I didn't know we had a python client repository (but I didn't look either -- I wrongly assumed that everything related to atlas-checks would be in this repo).

tsmock avatar Oct 02 '20 13:10 tsmock