everypolitician / compare_with_wikidata

Library for diffing Wikidata and CSVs
MIT License
2 stars 0 forks source link

Don't show unchanged values changing to themselves #133

Closed tmtmtmtm closed 6 years ago

tmtmtmtm commented 6 years ago

https://github.com/everypolitician/compare_with_wikidata/pull/120 introduced a subtle regression, where, when one or more cells in a row have changed (and thus the row itself is marked as 'modified', a cell that was unchanged showed up as changing to itself.

Rather than showing an id, say, changing from "2->2", we should simply show the unchanged "2" as the value.

Closes https://github.com/everypolitician/compare_with_wikidata/issues/132

Tested on live data with https://www.wikidata.org/w/index.php?title=User%3AOravrattas%2Fprompts%2FScottish_Parliament%2Fcomparison&type=revision&diff=686716807&oldid=674024357:

Before: screen shot 2018-05-29 at 11 54 34

After: screen shot 2018-05-29 at 11 54 41

tmtmtmtm commented 6 years ago

Currently failing due to #134, which I've opened a separate PR for as #136

tmtmtmtm commented 6 years ago

@chrismytton / @mhl apologies for marking this for review whilst travis is failing, but as far as I can tell, that's entirely because of #134 rather than anything specific to this PR. I've also opened #136 for fixing that, and have assigned both in case you want to look at them together, rather than having to context switch twice.