This pull request includes significant updates to improve logging, error handling, and code organization in the access_amherst_backend project. The most important changes include enhancing logging in the email_parser.py, updating the test coverage threshold, and consolidating management commands.
This pull request includes significant updates to improve logging, error handling, and code organization in the
access_amherst_backend
project. The most important changes include enhancing logging in theemail_parser.py
, updating the test coverage threshold, and consolidating management commands.Enhancements to Logging and Error Handling:
access_amherst_backend/access_amherst_algo/email_scraper/email_parser.py
: Added logging configuration and replaced print statements with logging for better error tracking and debugging. [1] [2] [3] [4] [5]Updates to Test Coverage:
.github/workflows/django.yml
: Increased the coverage threshold for tests from 85% to 90%.access_amherst_backend/.coveragerc
: Addedurls.py
to the omit list for coverage reports.Consolidation of Management Commands:
daily_mammoth_parser.py
,daily_mammoth_saver.py
,db_saver.py
,events_list_creator.py
,hub_data_cleaner.py
,json_saver.py
,rss_fetcher.py
) and combined their functionalities into new workflow commands (daily_mammoth_workflow.py
,hub_workflow.py
). [1] [2] [3] [4] [5] [6] [7] [8] [9]Code Cleanup and Refactoring:
access_amherst_backend/access_amherst_algo/parse_database.py
: Added checks for null values in event times to prevent errors during processing. [1] [2]