feat: serving "off"/closed dining periods#338
Draft
matt-franklin225 wants to merge 5 commits intomainfrom
Draft
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
UCI dining provides data on when various schedules are "off", which occurs when no regular schedule takes place on a certain day. Since the dining halls are closed on these days, we did not previously provide data for these days, meaning that all "off" days were skipped over. However, as mentioned in #332, PeterPlate's Figma is calling for such closed periods to be served.
To do this, the
parseOpeningHoursfunction inutil.tsinapps/data-pipeline/dining-scraperhas been adjusted such that, instead of skipping "off" periods, they are instead returned with a startTime and endTime of null (which is a breaking change, as these fields were previously not nullable and now are). Invalidly formatted date/time entries will still be filtered out.Related Issue
This will close #332
Motivation and Context
As previously mentioned, PeterPlate wants our API to return data on which days are closed, and these days are represented by the "off" periods.
How Has This Been Tested?
The changes were initially tested locally to efficiently run through test cases, then was used for a standard run-through of the dining scraper to make sure it didn't break any previously working code.
Screenshots (if appropriate):
Types of changes
Checklist: