diff --git a/.gitignore b/.gitignore index f895aff..2f0c8e5 100644 --- a/.gitignore +++ b/.gitignore @@ -7,5 +7,4 @@ data/ .env .vscode .pytest_cache -app/assets/ -screenshots/ \ No newline at end of file +app/assets/ \ No newline at end of file diff --git a/README.md b/README.md index fabf918..999187f 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ app/ │ └── MatchAnalytics.py │ └── UserAnalytics.py -├── analytics/ # Contains image files copied from the media folder in the export +├── assets/ # Contains image files copied from the media folder in the export ├── pages/ # Visualization rendering and user interface │ ├── __init__.py @@ -23,10 +23,6 @@ app/ │ └── MatchPage.py │ └── UserPage.py -├── tools/ # Misc. tools -│ ├── __init__.py -│ └── Logger.py - ├── utilities/ # Helper functions, constants, config, and utilities │ ├── __init__.py │ └── DataUtility.py @@ -39,7 +35,7 @@ tests/ # Unit and integration tests │ └── test_UserAnalytics.py data/ # Local storage for raw data from the personal export -└── export +└── export/ │ ├── media/ # Images that were uploaded to Hinge │ └── matches.json │ └── user.json @@ -50,7 +46,7 @@ data/ # Local storage for raw data from the personal export README.md # Project overview and instructions requirements.txt # Python dependencies -.env # Environment variables (e.g., MATCH_FILE_PATH) +.env # Environment variables Dockerfile # Dockerfile docker-compose.yml # Docker Compose configuration LICENSE # Project license diff --git a/app/tools/Logger.py b/app/tools/Logger.py deleted file mode 100644 index 4002e57..0000000 --- a/app/tools/Logger.py +++ /dev/null @@ -1,10 +0,0 @@ -from loguru import logger -import sys - -# remove default loguru logger -logger.remove() - -logger.add( - sys.stderr, - format="{time} | {level} | {message} | {file}:{line} | {function}", - level="DEBUG") diff --git a/app/tools/__init__.py b/app/tools/__init__.py deleted file mode 100644 index e69de29..0000000 diff --git a/mock_screenshots/com_bet_user_and_prefs.png b/mock_screenshots/com_bet_user_and_prefs.png new file mode 100644 index 0000000..0320ace Binary files /dev/null and b/mock_screenshots/com_bet_user_and_prefs.png differ diff --git a/mock_screenshots/dating_prefs.png b/mock_screenshots/dating_prefs.png new file mode 100644 index 0000000..e7e7857 Binary files /dev/null and b/mock_screenshots/dating_prefs.png differ diff --git a/mock_screenshots/duration_match_rm.png b/mock_screenshots/duration_match_rm.png new file mode 100644 index 0000000..dc9f7f8 Binary files /dev/null and b/mock_screenshots/duration_match_rm.png differ diff --git a/mock_screenshots/duration_v_count.png b/mock_screenshots/duration_v_count.png new file mode 100644 index 0000000..0f7c0c4 Binary files /dev/null and b/mock_screenshots/duration_v_count.png differ diff --git a/mock_screenshots/msg_count_boxplot.png b/mock_screenshots/msg_count_boxplot.png new file mode 100644 index 0000000..f84fdb8 Binary files /dev/null and b/mock_screenshots/msg_count_boxplot.png differ diff --git a/mock_screenshots/profile_info_vis.png b/mock_screenshots/profile_info_vis.png new file mode 100644 index 0000000..6721e70 Binary files /dev/null and b/mock_screenshots/profile_info_vis.png differ diff --git a/mock_screenshots/resp_latency.png b/mock_screenshots/resp_latency.png new file mode 100644 index 0000000..79965a6 Binary files /dev/null and b/mock_screenshots/resp_latency.png differ diff --git a/mock_screenshots/user_slides.png b/mock_screenshots/user_slides.png new file mode 100644 index 0000000..64a28ac Binary files /dev/null and b/mock_screenshots/user_slides.png differ diff --git a/tests/analytics/test_UserAnalytics.py b/tests/analytics/test_UserAnalytics.py index 4504080..701893e 100644 --- a/tests/analytics/test_UserAnalytics.py +++ b/tests/analytics/test_UserAnalytics.py @@ -132,10 +132,11 @@ def user_analytics(monkeypatch): monkeypatch.setenv("ASSETS_PATH", ASSETS_PATH) monkeypatch.setenv("MEDIA_PATH", MEDIA_PATH) - with patch("builtins.open", mock_open(read_data=USER_DATA)) as mock_file, \ - patch("json.load", return_value=json.loads(USER_DATA)) as mock_json_load, \ + with patch("builtins.open", mock_open(read_data=USER_DATA)), \ + patch("json.load", return_value=json.loads(USER_DATA)), \ patch("os.makedirs"), \ - patch("os.listdir", return_value=[]): # prevent actual file ops + patch("os.listdir", return_value=[]), \ + patch("shutil.copy2"): user_analytics = UserAnalytics() return user_analytics