whatdidyoudo 0.1.0__tar.gz → 0.1.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of whatdidyoudo might be problematic. Click here for more details.
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/PKG-INFO +39 -27
- whatdidyoudo-0.1.1/README.md +70 -0
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/pyproject.toml +6 -1
- whatdidyoudo-0.1.1/tests/__init__.py +4 -0
- whatdidyoudo-0.1.1/tests/test_app.py +34 -0
- whatdidyoudo-0.1.1/whatdidyoudo/__init__.py +0 -0
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/whatdidyoudo/app.py +4 -0
- whatdidyoudo-0.1.0/README.md +0 -60
- whatdidyoudo-0.1.0/run_test.py +0 -8
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/.github/copilot-instructions.md +0 -0
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/.gitignore +0 -0
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/whatdidyoudo/static/style.css +0 -0
- {whatdidyoudo-0.1.0 → whatdidyoudo-0.1.1}/whatdidyoudo/templates/form.html +0 -0
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: whatdidyoudo
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.1
|
|
4
4
|
Summary: A minimal Flask app that shows the amount of OpenStreetMap changes made by a user on a day.
|
|
5
|
+
Project-URL: Homepage, https://github.com/rompe/whatdidyoudo
|
|
6
|
+
Project-URL: Issues, https://github.com/rompe/whatdidyoudo/issues
|
|
5
7
|
Author-email: Ulf Rompe <whatdidyoudo.rompe.org@rompe.org>
|
|
6
8
|
License: MIT
|
|
7
9
|
Requires-Python: >=3.11
|
|
@@ -21,12 +23,16 @@ A minimal Flask app that shows the amount of OpenStreetMap changes made by a use
|
|
|
21
23
|
|
|
22
24
|
## Background
|
|
23
25
|
|
|
24
|
-
I often ask myself after contributing many changes to OpenStreetMap,
|
|
25
|
-
while extensively using StreetComplete,
|
|
26
|
-
|
|
26
|
+
I often ask myself after contributing many changes to [OpenStreetMap](https://www.openstreetmap.org/),
|
|
27
|
+
either by walking around while extensively using [StreetComplete](https://streetcomplete.app/),
|
|
28
|
+
[MapComplete](https://mapcomplete.org/) or [Vespucci](https://vespucci.io/), or by doing some tasks
|
|
29
|
+
in [iD](https://www.openstreetmap.org/edit) or [JOSM](https://josm.openstreetmap.de/):
|
|
30
|
+
|
|
31
|
+
***How many changes did I contribute to the map today?***
|
|
27
32
|
|
|
28
33
|
I'm not the only one. I heard questions like this quite a few times:
|
|
29
|
-
|
|
34
|
+
|
|
35
|
+
***Where can I see how much I did on yesterday's mapwalk?***
|
|
30
36
|
|
|
31
37
|
Because I think that simple questions deserve simple answers, I made this tool to give exactly
|
|
32
38
|
this information and nothing else.
|
|
@@ -39,38 +45,44 @@ You don't need to self-host it, it is available for anyone at
|
|
|
39
45
|
Fun fact: of course you don't really need *uv* for this. I'm just using this project to
|
|
40
46
|
get used to it as I think it has a lot of potential.
|
|
41
47
|
|
|
42
|
-
|
|
48
|
+
### Install [uv](https://github.com/astral-sh/uv) if needed
|
|
49
|
+
|
|
50
|
+
```sh
|
|
51
|
+
pip install uv
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### Install dependencies using *uv*
|
|
43
55
|
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
56
|
+
```sh
|
|
57
|
+
uv pip install -r pyproject.toml
|
|
58
|
+
```
|
|
47
59
|
|
|
48
|
-
|
|
60
|
+
If you want to develop:
|
|
49
61
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
62
|
+
```sh
|
|
63
|
+
uv pip install -r pyproject.toml --extra dev
|
|
64
|
+
```
|
|
53
65
|
|
|
54
|
-
|
|
66
|
+
### Run tests
|
|
55
67
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
68
|
+
```sh
|
|
69
|
+
pytest
|
|
70
|
+
```
|
|
59
71
|
|
|
60
|
-
|
|
72
|
+
### Run the app in test mode
|
|
61
73
|
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
74
|
+
```sh
|
|
75
|
+
python whatdidyoudo/app.py
|
|
76
|
+
```
|
|
65
77
|
|
|
66
|
-
|
|
78
|
+
Visit [http://127.0.0.1:5000/](http://127.0.0.1:5000/) in your browser to see "hello world".
|
|
67
79
|
|
|
68
|
-
|
|
80
|
+
### Build a package and upload it to Pypi
|
|
69
81
|
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
82
|
+
```sh
|
|
83
|
+
uvx hatchling build
|
|
84
|
+
uvx twine upload dist/*
|
|
85
|
+
```
|
|
74
86
|
|
|
75
87
|
## License
|
|
76
88
|
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# whatdidyoudo
|
|
2
|
+
|
|
3
|
+
A minimal Flask app that shows the amount of OpenStreetMap changes made by a user on a day.
|
|
4
|
+
|
|
5
|
+
## Background
|
|
6
|
+
|
|
7
|
+
I often ask myself after contributing many changes to [OpenStreetMap](https://www.openstreetmap.org/),
|
|
8
|
+
either by walking around while extensively using [StreetComplete](https://streetcomplete.app/),
|
|
9
|
+
[MapComplete](https://mapcomplete.org/) or [Vespucci](https://vespucci.io/), or by doing some tasks
|
|
10
|
+
in [iD](https://www.openstreetmap.org/edit) or [JOSM](https://josm.openstreetmap.de/):
|
|
11
|
+
|
|
12
|
+
***How many changes did I contribute to the map today?***
|
|
13
|
+
|
|
14
|
+
I'm not the only one. I heard questions like this quite a few times:
|
|
15
|
+
|
|
16
|
+
***Where can I see how much I did on yesterday's mapwalk?***
|
|
17
|
+
|
|
18
|
+
Because I think that simple questions deserve simple answers, I made this tool to give exactly
|
|
19
|
+
this information and nothing else.
|
|
20
|
+
|
|
21
|
+
You don't need to self-host it, it is available for anyone at
|
|
22
|
+
[whatdidyoudo.rompe.org](https://whatdidyoudo.rompe.org).
|
|
23
|
+
|
|
24
|
+
## Setup
|
|
25
|
+
|
|
26
|
+
Fun fact: of course you don't really need *uv* for this. I'm just using this project to
|
|
27
|
+
get used to it as I think it has a lot of potential.
|
|
28
|
+
|
|
29
|
+
### Install [uv](https://github.com/astral-sh/uv) if needed
|
|
30
|
+
|
|
31
|
+
```sh
|
|
32
|
+
pip install uv
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
### Install dependencies using *uv*
|
|
36
|
+
|
|
37
|
+
```sh
|
|
38
|
+
uv pip install -r pyproject.toml
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
If you want to develop:
|
|
42
|
+
|
|
43
|
+
```sh
|
|
44
|
+
uv pip install -r pyproject.toml --extra dev
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
### Run tests
|
|
48
|
+
|
|
49
|
+
```sh
|
|
50
|
+
pytest
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### Run the app in test mode
|
|
54
|
+
|
|
55
|
+
```sh
|
|
56
|
+
python whatdidyoudo/app.py
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
Visit [http://127.0.0.1:5000/](http://127.0.0.1:5000/) in your browser to see "hello world".
|
|
60
|
+
|
|
61
|
+
### Build a package and upload it to Pypi
|
|
62
|
+
|
|
63
|
+
```sh
|
|
64
|
+
uvx hatchling build
|
|
65
|
+
uvx twine upload dist/*
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
## License
|
|
69
|
+
|
|
70
|
+
This project is licensed under the MIT License. See the `pyproject.toml` for details.
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "whatdidyoudo"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.1"
|
|
8
8
|
description = "A minimal Flask app that shows the amount of OpenStreetMap changes made by a user on a day."
|
|
9
9
|
authors = [
|
|
10
10
|
{ name = "Ulf Rompe", email = "whatdidyoudo.rompe.org@rompe.org" }
|
|
@@ -26,6 +26,11 @@ dev = [
|
|
|
26
26
|
"twine>=6.2.0",
|
|
27
27
|
]
|
|
28
28
|
|
|
29
|
+
[project.urls]
|
|
30
|
+
Homepage = "https://github.com/rompe/whatdidyoudo"
|
|
31
|
+
Issues = "https://github.com/rompe/whatdidyoudo/issues"
|
|
32
|
+
|
|
33
|
+
|
|
29
34
|
[tool.uv]
|
|
30
35
|
# uv-specific settings go here
|
|
31
36
|
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"""Unit tests for the WhatDidYouDo Flask application."""
|
|
2
|
+
import unittest
|
|
3
|
+
from whatdidyoudo.app import app
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
class WhatDidYouDoTestCase(unittest.TestCase):
|
|
7
|
+
"""Unit tests for the WhatDidYouDo Flask application."""
|
|
8
|
+
def setUp(self):
|
|
9
|
+
self.app = app.test_client()
|
|
10
|
+
self.app.testing = True # type: ignore
|
|
11
|
+
|
|
12
|
+
def test_home_status_code(self):
|
|
13
|
+
"""Test that the home page returns a 200 status code."""
|
|
14
|
+
response = self.app.get('/')
|
|
15
|
+
self.assertEqual(response.status_code, 200)
|
|
16
|
+
|
|
17
|
+
def test_form_contains_user_and_date(self):
|
|
18
|
+
"""Test that the form contains fields for user and date."""
|
|
19
|
+
response = self.app.get('/')
|
|
20
|
+
html = response.get_data(as_text=True)
|
|
21
|
+
self.assertIn('name="user"', html)
|
|
22
|
+
self.assertIn('name="date"', html)
|
|
23
|
+
|
|
24
|
+
def test_user_date_route(self):
|
|
25
|
+
"""Test that the user/date route returns a 200 status code."""
|
|
26
|
+
response = self.app.get('/rompe/2024-09-29')
|
|
27
|
+
self.assertEqual(response.status_code, 200)
|
|
28
|
+
html = response.get_data(as_text=True)
|
|
29
|
+
self.assertIn('rompe', html)
|
|
30
|
+
self.assertIn('2024-09-29', html)
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
if __name__ == '__main__':
|
|
34
|
+
unittest.main()
|
|
File without changes
|
whatdidyoudo-0.1.0/README.md
DELETED
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
# whatdidyoudo
|
|
2
|
-
|
|
3
|
-
A minimal Flask app that shows the amount of OpenStreetMap changes made by a user on a day.
|
|
4
|
-
|
|
5
|
-
## Background
|
|
6
|
-
|
|
7
|
-
I often ask myself after contributing many changes to OpenStreetMap, either by walking around
|
|
8
|
-
while extensively using StreetComplete, MapComplete or Vespucci, or by doing some tasks in iD or
|
|
9
|
-
jOSM: **How many changes did I contribute to the map today?**
|
|
10
|
-
|
|
11
|
-
I'm not the only one. I heard questions like this quite a few times:
|
|
12
|
-
**Where can I see how much I did on yesterday's mapwalk?**
|
|
13
|
-
|
|
14
|
-
Because I think that simple questions deserve simple answers, I made this tool to give exactly
|
|
15
|
-
this information and nothing else.
|
|
16
|
-
|
|
17
|
-
You don't need to self-host it, it is available for anyone at
|
|
18
|
-
[whatdidyoudo.rompe.org](https://whatdidyoudo.rompe.org).
|
|
19
|
-
|
|
20
|
-
## Setup
|
|
21
|
-
|
|
22
|
-
Fun fact: of course you don't really need *uv* for this. I'm just using this project to
|
|
23
|
-
get used to it as I think it has a lot of potential.
|
|
24
|
-
|
|
25
|
-
1. Install [uv](https://github.com/astral-sh/uv) if needed:
|
|
26
|
-
|
|
27
|
-
```sh
|
|
28
|
-
pip install uv
|
|
29
|
-
```
|
|
30
|
-
|
|
31
|
-
2. Install dependencies using *uv*:
|
|
32
|
-
|
|
33
|
-
```sh
|
|
34
|
-
uv pip install -r pyproject.toml
|
|
35
|
-
```
|
|
36
|
-
|
|
37
|
-
If you want to develop:
|
|
38
|
-
|
|
39
|
-
```sh
|
|
40
|
-
uv pip install -r pyproject.toml --extra dev
|
|
41
|
-
```
|
|
42
|
-
|
|
43
|
-
3. Run the app in test mode:
|
|
44
|
-
|
|
45
|
-
```sh
|
|
46
|
-
python run_test.py
|
|
47
|
-
```
|
|
48
|
-
|
|
49
|
-
Visit [http://127.0.0.1:5000/](http://127.0.0.1:5000/) in your browser to see "hello world".
|
|
50
|
-
|
|
51
|
-
4. Build a package and upload it to Pypi
|
|
52
|
-
|
|
53
|
-
```sh
|
|
54
|
-
uv hatchling build
|
|
55
|
-
uv twine upload dist/*
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
## License
|
|
59
|
-
|
|
60
|
-
This project is licensed under the MIT License. See the `pyproject.toml` for details.
|
whatdidyoudo-0.1.0/run_test.py
DELETED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|