Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automating TWiR ‘Event List’ section. #5720

Draft
wants to merge 36 commits into
base: master
Choose a base branch
from

Conversation

HanCotterell
Copy link

The Problem:

After speaking with Marianne, who currently manages curating the ‘Event List’ section of TWiR, it was identified that a lot of the manual work that is currently being done could be automated. The current process for each week’s issue of TWiR involves Marianne manually checking multiple sources of event information, gathering the required data for each event from these event sources to create a list of potential events to include, then filtering, sorting and formatting each event’s data. It was identified that this time-consuming process could be reduced significantly with the introduction of an automation program.

Our Solution:

Our solution to this problem was to create a program that would be able to gather the necessary data from common event sources that Marianne uses (e.g Google Calendar, Meetup.com), and export this data as a list of events. This Event list would then go through a sorting and filtering process in order to group the events by virtual or continent, identify potential duplicate events within the list, as well as order them by their date and location data. After this process, the program will output a sorted list of events, formatted correctly and with section headers. The aim of this program is to produce a result where whoever is creating the event section will only need to look at and evaluate events that have been flagged as potential duplicates, rather than completing the entire process manually.

Specifics of Our Solution:

The structure that was decided upon for this project is modular. We decided to split the work of the program into an ‘Event Sink’ module that is responsible for sorting, filtering and formatting the Event data, and different ‘Event Source’ modules that are responsible for gathering the required event data from an individual source (e.g. Google Calendar) and exporting that data into the ‘Event Sink’. We believe this structure is best suited for the aim of the program because each module works independently if an bug occurred that impacted the functioning of the program, it would be easy to identify which module contains the problem and in the event that an ‘Event Source’ module is malfunctioning, the rest of the program can still be utilized while finding a solution to the problem. Another benefit this structure offers is that, in the future, if there are other sources of event information that someone may want to add to this program, then creating another ‘Event Source’ module to integrate into the ‘Event Sink’ should be a straightforward process.

This PR contains the code of the ‘Event Sink’ module as well as an overview of the project. If this PR is accepted then we will submit further PR’s that contain ‘Event Source’ modules for Google Calendar, recent TWiR newsletters, and Meetup.com that are currently being developed to complete the automation process.

oohwooh and others added 30 commits March 13, 2024 15:17
Added sort_and_filter_events() function and helper functions for event sink.
Added to_markdown_string() function, that outputs the event details in the required markdown format.
Altered a few test event parameters to better test the sorting functions. Also changed the datetime data, so it only holds a date value rather than date and time value.
Added field 'duplicate' to help with filtering potential duplicate events.
Implemented discussed changes to output (grouping by virtual and continent), added filtering by date window, added function for identifying potential duplicate events.
Updated test event list to better test Event Sink.
Created a tool to identify the continent associated with an ISO country code.
Added location formatting function.
Adds functions for formatting state/territory alpha_2 code.
Function for formatting a country into it's alpha-2 code.
Added formatting functions for location and date data.
Added formatting function for datetime data.
Added documentation outlining Event class and Event Sink module.
Added sections on the architecture of event sink module and how to use the code.
added organizerUrl as a class variable.
Removed sort_and_filter_events() function. Created a more modular structure with individual function calls to handle each task in Event Sink.
…" bug with geopy, adds location check to potential_duplicate() function.
@nellshamrell
Copy link
Contributor

This looks super cool! @mariannegoldin, what do you think?

@mariannegoldin
Copy link
Contributor

This is great work, thank you so much @HanCotterell. I am reviewing the PR now.

@mariannegoldin
Copy link
Contributor

As a quick update, I am currently tied up in other projects but will have more bandwidth after Aug 1 to review.

@bennyvasquez
Copy link
Contributor

any objection to me converting this PR to a draft to make it more clear it shouldn't be merged yet?

@mariannegoldin
Copy link
Contributor

mariannegoldin commented Aug 8, 2024 via email

@bennyvasquez bennyvasquez marked this pull request as draft August 8, 2024 19:24
@bennyvasquez
Copy link
Contributor

done!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants