Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Team summary graph too aggressively switches over to grouping by days #507

Open
rbclark opened this issue Jun 24, 2020 · 1 comment
Open
Labels

Comments

@rbclark
Copy link
Contributor

rbclark commented Jun 24, 2020

We recently added in code to switch over the Game Flag Submissions and Team Flag Submissions graphs over from grouping data by hours to grouping data by days automatically. When doing this I didn't take into account how slow/fast paced the game could be. The automatic switchover is after 7 days, and on one currently running competition the graphs now look as follows:

Screen Shot 2020-06-24 at 3 11 42 PM

Screen Shot 2020-06-24 at 3 12 03 PM

Instead of switching over automatically we basically need to add something similar to the following code

[:hours, :days].each do |period|
    @team_flags_per_hour = @team.submitted_flags_per_hour(period)
    @team_solves_per_hour = @team.solved_challenges_per_hour(period)
    break unless max(@team_flags_per_hour, @team_solves_per_hour) > THRESHOLD
end

We need to figure out what a reasonable THRESHOLD is above (probably by manually testing different amounts of data).

Also we need to rename submitted_flags_per_hour and solved_challenges_per_hour since they aren't really by hour anymore, they are by the period passed into them.

@rbclark rbclark added the bug label Jun 24, 2020
@camdenmoors
Copy link
Collaborator

I've managed to fix this bug locally (by defining the dateTimeLabelFormats for xAxis), however, there is another problem (in master) that makes all hours show as 4AM (example). I'm at a loss as to how this happens but I will continue to look for what's causing this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants