Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion Contest_API.md
Original file line number Diff line number Diff line change
Expand Up @@ -772,6 +772,7 @@ Properties of contest objects:
| scoreboard\_freeze\_duration | RELTIME ? | How long the scoreboard is frozen before the end of the contest. Defaults to `0:00:00`.
| scoreboard\_thaw\_time | TIME ? | The scheduled thaw time of the contest, may be `null` if the thaw time is unknown or not set.
| scoreboard\_type | string | What type of scoreboard is used for the contest. Must be either `pass-fail` or `score`.
| default_scoreboard_group | ID ? | Identifier of the group that represents the default scoreboard. If `null`, the default scoreboard contains all teams (even if there is no group containing all teams).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't love the name (kinda long), but should also end in _id to match other fields like this. And I guess we should use backslashes in markup too?

Maybe just scoreboard\_group\_id to match the others? In one sense it is the default, but it's also overriding the default (all teams) behaviour too, so I'd lean more toward matching other property names.

I think the term 'default scoreboard' is potentially confusing too. I've never thought of the current scoreboard as the 'default' one - it's just 'the' scoreboard, or the 'primary' scoreboard when compared to group-specific ones. So I'd lean toward replacing:
Identifier of the group that represents the default scoreboard. If null, the default scoreboard contains all teams (even if there...
with something simpler like:
Identifier of the group of teams that are on the scoreboard. If null, the scoreboard contains all teams.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We discussed this at the call on Dec 15, consensus is that main_scoreboard_group_id is a better name.

| penalty\_time | RELTIME | Penalty time for a wrong submission. Only relevant if scoreboard\_type is `pass-fail`.
| banner | array of FILE ? | Banner for this contest, intended to be an image with a large aspect ratio around 8:1. Only allowed mime types are image/\*.
| logo | array of FILE ? | Logo for this contest, intended to be an image with aspect ratio near 1:1. Only allowed mime types are image/\*.
Expand Down Expand Up @@ -1374,7 +1375,6 @@ Properties of team objects:
| display\_name | string ? | Display name of the team. If not set, a client should revert to using the name instead.
| organization\_id | ID ? | Identifier of the [ organization](#organizations) (e.g. university or other entity) that this team is affiliated to.
| group\_ids | array of ID ? | Identifiers of the [ group(s)](#groups) this team is part of (at ICPC WFs these are the super-regions). The array may be empty. Required iff groups endpoint is available.
| hidden | boolean ? | If the team is to be excluded from the [scoreboard](#scoreboard). Defaults to `false`.
| location | team location object ? | Position of team on the contest floor. See below for the specification of this object.
| photo | array of FILE ? | Registration photo of the team. Only allowed mime types are image/\*.
| video | array of FILE ? | Registration video of the team. Only allowed mime types are video/\* or application/vnd.apple.mpegurl.
Expand Down Expand Up @@ -2262,6 +2262,8 @@ By passing `group_id` with a valid group ID a scoreboard can be requested for th

`contests/<id>/scoreboard?group_id=site1`

If no `group_id` is given, the group specified by `deafault_scoreboard_group` in the contest endpoint is used, or all teams if it is `null`.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Typo in property name (and update if we change the name above).

I might be overly picky, but the current setup is that group_id is an optional parameter - you only add it when you want a specific group. To me this change makes it sound more like the user is expected to pass the group_id and we're specifying a default behaviour for when they don't. I'm ok if we want to include a mention of the default group id in the Scoreboard section, but I'd do that in the main part. The section on group_id shouldn't need to change b/c picking the same group as the default is maybe unnecessary, but isn't special in any way.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We discussed this, consensus is that it should be reworded to say that /scoreboard returns the scoreboard indicated by main_scoreboard_group_id, and /scoreboard?group_id=<group> will return the scoreboard for the indicated group. (I.e. there is no way to not specify a group or null).


Each group scoreboard is ranked independently and contains only the teams that belong to the
specified group. If a client wants to know 'local' vs 'global' rank it can query both the group and primary scoreboards.

Expand Down