Skip to content

Commit

Permalink
🏫 Add new Indianapolis campus and buildings (#64)
Browse files Browse the repository at this point in the history
IUPUI recently split, resulting in a new Purdue Indianapolis Campus and
associated buildings.

Due to #54 and #55, these entities need to be added manually. This was
previously blocking sync of the latest term, as noted in #63

This change adds the new buildings and allows Fall 2024 to sync
successfully.
  • Loading branch information
haydenmc authored Mar 21, 2024
1 parent 09328f8 commit 64334c7
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion src/Scraper/MyPurdueScraper.cs
Original file line number Diff line number Diff line change
Expand Up @@ -383,6 +383,7 @@ private record SectionListInfo
{ "Greensburg Campus", "TGB" },
{ "Concurrent Credit Campus", "CC" },
{ "Dual Campus Campus", "TDC" },
{ "West Lafayette at Indianapolis Campus", "PIN" },
};

// The loss of authenticated APIs removed our source of information for
Expand Down Expand Up @@ -550,13 +551,18 @@ private record SectionListInfo
{ "Muncie Central", "MCHS" }, // I made this short code up since this is a dual-credit
// course at Muncie Central High School, presumably
// doesn't have a real short code.
{ "Engineering/Technology", "ET"},
{ "Engr/Science & Tech", "SL" },
{ "Science & Engineering Lab", "EL" },
{ "Innovation Hall", "IO" },

};

public (string buildingName, string buildingShortCode, string room)? ParseLocationDetails(
string locationString)
{
// Handle special case
if (locationString == "TBA")
if ((locationString == "TBA") || locationString.StartsWith("Temp-"))
{
return (buildingName: "TBA", buildingShortCode: "TBA", room: "TBA");
}
Expand Down

0 comments on commit 64334c7

Please sign in to comment.