mirror of
https://github.com/bellingcat/geoclustering.git
synced 2026-06-09 20:18:30 +03:00
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
e9b7680263 | ||
|
|
de4d4689b9 | ||
|
|
484d3cb02c | ||
|
|
65366816fa |
12
.github/workflows/main.yml
vendored
12
.github/workflows/main.yml
vendored
@@ -44,11 +44,11 @@ jobs:
|
||||
- python: "3.10"
|
||||
task:
|
||||
name: "Test"
|
||||
run: pytest --exitfirst --failed-first
|
||||
- python: "3.7"
|
||||
run: pytest --exitfirst --failed-first --assert=plain
|
||||
- python: "3.8"
|
||||
task:
|
||||
name: "Test (3.7)"
|
||||
run: pytest --exitfirst --failed-first
|
||||
name: "Test (3.8)"
|
||||
run: pytest --exitfirst --failed-first --assert=plain
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
@@ -65,7 +65,7 @@ jobs:
|
||||
|
||||
- name: Upload package distribution files
|
||||
if: matrix.task.name == 'Build'
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: package
|
||||
path: dist
|
||||
@@ -99,7 +99,7 @@ jobs:
|
||||
echo "TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
|
||||
|
||||
- name: Download package distribution files
|
||||
uses: actions/download-artifact@v3
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: package
|
||||
path: dist
|
||||
|
||||
2904
Pipfile.lock
generated
2904
Pipfile.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -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