scouting: Add an endpoint for populating the match schedule
This patch combines the scraping library with the scouting webserver.
There's now also a new end point for the web page (or debug CLI tool)
to ask the server to fetch the match list. The end point is
`/requests/refresh_match_list`.
All the tests are updated. The `cli_test` downloads a 2016 ny_tr match
list that I downloaded from TBA. It should be a decent integration
test as it uses representative data.
Signed-off-by: Philipp Schrader <philipp.schrader@gmail.com>
Change-Id: I6c540590521b00887eb2ddde2a9369875c659551
diff --git a/scouting/webserver/requests/messages/BUILD b/scouting/webserver/requests/messages/BUILD
index 53ceab2..c27f730 100644
--- a/scouting/webserver/requests/messages/BUILD
+++ b/scouting/webserver/requests/messages/BUILD
@@ -10,6 +10,8 @@
"request_matches_for_team_response",
"request_data_scouting",
"request_data_scouting_response",
+ "refresh_match_list",
+ "refresh_match_list_response",
)
filegroup(
diff --git a/scouting/webserver/requests/messages/refresh_match_list.fbs b/scouting/webserver/requests/messages/refresh_match_list.fbs
new file mode 100644
index 0000000..c4384c7
--- /dev/null
+++ b/scouting/webserver/requests/messages/refresh_match_list.fbs
@@ -0,0 +1,8 @@
+namespace scouting.webserver.requests;
+
+table RefreshMatchList {
+ year: int (id: 0);
+ event_code: string (id: 1);
+}
+
+root_type RefreshMatchList;
diff --git a/scouting/webserver/requests/messages/refresh_match_list_response.fbs b/scouting/webserver/requests/messages/refresh_match_list_response.fbs
new file mode 100644
index 0000000..ba80272
--- /dev/null
+++ b/scouting/webserver/requests/messages/refresh_match_list_response.fbs
@@ -0,0 +1,6 @@
+namespace scouting.webserver.requests;
+
+table RefreshMatchListResponse {
+}
+
+root_type RefreshMatchListResponse;