Skip to content

Commit 88b8601

Browse files
🏎️ Add Dallara building (#85)
`CatalogSync` fails when scraping `202710` and fails on the MSPE major, and it appears that a new class is in the "Dallara" building, which seems to be Dallara Experience Hub for ([related news article?](https://www.purdue.edu/newsroom/2025/Q2/purdue-motorsports-and-dallara-celebrate-transformational-partnership)) ([short code](https://selfservice.mypurdue.purdue.edu/prod/BZWSLCSR.P_Prep_Search?term_in=202710&crn_in=27888)). The two classes that utilize this building are `MSPE 31700` and `MSPE 41700`.
1 parent ae5b6cb commit 88b8601

1 file changed

Lines changed: 10 additions & 5 deletions

File tree

src/Scraper/MyPurdueScraper.cs

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ public async Task<ICollection<Term>> GetTermsAsync()
3030
HtmlDocument document = new HtmlDocument();
3131
document.LoadHtml(termListPageContent);
3232
HtmlNode root = document.DocumentNode;
33-
HtmlNodeCollection termSelectNodes =
33+
HtmlNodeCollection termSelectNodes =
3434
root.SelectNodes("//select[@name='p_term']/option");
3535
foreach (var node in termSelectNodes)
3636
{
@@ -86,7 +86,7 @@ public async Task<ICollection<Section>> GetSectionsAsync(string termCode,
8686
// This method scrapes the relevant information from all sources into
8787
// one coherent model.
8888

89-
Dictionary<Crn, SectionListInfo> sectionList =
89+
Dictionary<Crn, SectionListInfo> sectionList =
9090
await FetchSectionListAsync(termCode, subjectCode);
9191

9292
var mergedSections = new List<Section>();
@@ -258,7 +258,7 @@ private async Task<Dictionary<Crn, SectionListInfo>> FetchSectionListAsync(strin
258258
// Parse days of week
259259
var daysOfWeek = HtmlEntity.DeEntitize(
260260
meetingNode.SelectSingleNode("td[3]").InnerText);
261-
DaysOfWeek parsedMeetingDaysOfWeek =
261+
DaysOfWeek parsedMeetingDaysOfWeek =
262262
ParsingUtilities.ParseDaysOfWeek(daysOfWeek);
263263

264264
// Parse building / room
@@ -362,7 +362,7 @@ private record SectionListInfo
362362
public string CampusName { get; init; }
363363
}
364364

365-
// The loss of authenticated APIs removed our source of information for
365+
// The loss of authenticated APIs removed our source of information for
366366
// campus short codes, so now they are hard-coded here and we just hope
367367
// new campuses are a fairly rare occurrence.
368368
// Tracked here: https://github.com/Purdue-io/PurdueApi/issues/55
@@ -389,7 +389,7 @@ private record SectionListInfo
389389
{ "Indiana Univ Indianapolis Campus", "IUI" },
390390
};
391391

392-
// The loss of authenticated APIs removed our source of information for
392+
// The loss of authenticated APIs removed our source of information for
393393
// building short codes, so now they are hard-coded here and we just hope
394394
// new buildings are a fairly rare occurrence.
395395
// Tracked here: https://github.com/Purdue-io/PurdueApi/issues/54
@@ -643,6 +643,11 @@ private record SectionListInfo
643643
// short code found on https://www.campus-maps.com/purdue-university/moll-mollenkopf-athletic-center/
644644
// seems legit.
645645
{ "Mollenkopf Athletic Center", "MOLL" },
646+
647+
// New as of term 202710
648+
// short code found https://selfservice.mypurdue.purdue.edu/prod/BZWSLCSR.P_Prep_Search?term_in=202710&crn_in=27888
649+
// for class in Dallara Experience Hub (?)
650+
{ "Dallara", "DAL" }
646651
};
647652

648653
public (string buildingName, string buildingShortCode, string room)? ParseLocationDetails(

0 commit comments

Comments
 (0)