mirror of
https://github.com/bellingcat/geoclustering.git
synced 2026-06-10 20:48:29 +03:00
Compare commits
3 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
de4d4689b9 | ||
|
|
484d3cb02c | ||
|
|
65366816fa |
@@ -162,3 +162,9 @@ It is assumed that you are using **Python3.9+**. It is encouraged to [setup a vi
|
||||
```
|
||||
|
||||
We use [Black](https://github.com/psf/black) as our code formatter. If you don't want to use the `pre-commit` hook, you can run the formatter manually or via an editor plugin.
|
||||
|
||||
## Release
|
||||
|
||||
1. Update [version.py](geoclustering/version.py)
|
||||
2. Run `scripts/release.sh`
|
||||
3. Confirm GH action completed successfully
|
||||
@@ -89,6 +89,7 @@ class CSVEncoder:
|
||||
self.state,
|
||||
fieldnames=["cluster_id"] + list(cluster[0].keys()),
|
||||
quoting=csv.QUOTE_NONNUMERIC,
|
||||
lineterminator="\n",
|
||||
)
|
||||
self.writer.writeheader()
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ _MAJOR = "0"
|
||||
_MINOR = "4"
|
||||
# On main and in a nightly release the patch should be one ahead of the last
|
||||
# released build.
|
||||
_PATCH = "0"
|
||||
_PATCH = "1"
|
||||
# This is mainly for nightly builds which have the suffix ".dev$DATE". See
|
||||
# https://semver.org/#is-v123-a-semantic-version for the semantics.
|
||||
_SUFFIX = ""
|
||||
|
||||
@@ -27,3 +27,4 @@ def test_encoders():
|
||||
assert res["string"] == read_fixture_content("snapshots/result.txt")
|
||||
assert res["json"] == read_fixture_content("snapshots/result.json")
|
||||
assert res["geojson"] == read_fixture_content("snapshots/result.geojson")
|
||||
assert res["csv"] == read_fixture_content("snapshots/result.csv")
|
||||
|
||||
5
tests/fixtures/snapshots/result.csv
vendored
Normal file
5
tests/fixtures/snapshots/result.csv
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
"cluster_id","id","name","lat","lon"
|
||||
0,1,"Alice",52.523955,13.442362
|
||||
0,2,"Bob",52.526659,13.448097
|
||||
1,3,"Carol",52.525626,13.419246
|
||||
1,4,"Dan",52.52443559865125,13.41261723049818
|
||||
|
Reference in New Issue
Block a user