DOMjudge / domjudge

DOMjudge programming contest jury system
https://www.domjudge.org
GNU General Public License v2.0
717 stars 253 forks source link

No scoreboard for balloon runners (non-public) #1289

Closed iMylene closed 1 year ago

iMylene commented 2 years ago

For a non-public contest, the scoreboard does not show up in the header for at least balloon runners.

nickygerritsen commented 2 years ago

If you go to the page directly, can the balloon runners access it?

iMylene commented 2 years ago

No, it's forbidden: image

nickygerritsen commented 2 years ago

OK so this raises the question: should balloon runners have access to the jury scoreboard?

vmcj commented 2 years ago

OK so this raises the question: should balloon runners have access to the jury scoreboard?

I think there should be 2 roles: _intrapublic_scoreboard _jury_scoreboard

and the balloon runner should get all semi-public info which is intrapublic, so not the unfrozen standing during the contest but more information than the outside world gets, similar to teams.

iMylene commented 2 years ago

I prefer that balloon runners see the same scoreboard as participants. So when the contest is frozen, runners won't see the real scoreboard

nickygerritsen commented 2 years ago

Wouldn’t the solution then not just be to make a hidden team for the balloon user?

iMylene commented 2 years ago

Maybe, but shouldn't the scoreboard not always be visible for runners, without having to put them in a team? Since runners do see them with a public contest

nickygerritsen commented 2 years ago

Yeah good question. We could maybe make /jury/scoreboard return the 'public' scoreboard for balloon users. What do others think?

nickygerritsen commented 2 years ago

For the roles: I don't like adding all these roles...

vmcj commented 2 years ago

For the roles: I don't like adding all these roles...

I meant an internal role not one in the GUI, so instead of check for ROLE_JURY we check for which scoreboard can actually be accessed, similar to how the ROLE_ADMIN also has ROLE_JURY.

nickygerritsen commented 2 years ago

For the roles: I don't like adding all these roles...

I meant an internal role not one in the GUI, so instead of check for ROLE_JURY we check for which scoreboard can actually be accessed, similar to how the ROLE_ADMIN also has ROLE_JURY.

Ah so you actually want the same idea I have? Allow both ballon and jury to view the scoreboard but when you are not jury, only show the 'public' one?

vmcj commented 2 years ago

For the roles: I don't like adding all these roles...

I meant an internal role not one in the GUI, so instead of check for ROLE_JURY we check for which scoreboard can actually be accessed, similar to how the ROLE_ADMIN also has ROLE_JURY.

Ah so you actually want the same idea I have? Allow both ballon and jury to view the scoreboard but when you are not jury, only show the 'public' one?

I want something where it doesn't become If ROLE_BALLOON or ROLE_TEAM

And there are 3 scoreboards in this case: public (outside world) team-public (their view on other teams) jury (all information)

The problem here is that the balloon runner cannot see the public scoreboard as thats not available (contest was not public) so should get the team-public one. Which I would call intrapublic as its public, but only internally...

Because the same can be said about what the clarification reader should see (I thought of the role seeing only team-public)

nickygerritsen commented 2 years ago

That is not what I'm suggesting. What I want to do is in this method: http://github.com/DOMjudge/domjudge/blob/main/webapp/src/Controller/Jury/ScoreboardController.php#L42-L42 set the $jury param only to true if you have the ROLE_JURY, otherwise set it to false. Then in that same controller change the security to also have balloon in it. That should be all to make balloon users see the 'public' (what you call intrapublic...) scoreboard.

vmcj commented 2 years ago

That is not what I'm suggesting. What I want to do is in this method: http://github.com/DOMjudge/domjudge/blob/main/webapp/src/Controller/Jury/ScoreboardController.php#L42-L42 set the $jury param only to true if you have the ROLE_JURY, otherwise set it to false. Then in that same controller change the security to also have balloon in it. That should be all to make balloon users see the 'public' (what you call intrapublic...) scoreboard.

Yes, thats much more elegant than what I wanted to do.

eldering commented 2 years ago

That is not what I'm suggesting. What I want to do is in this method: http://github.com/DOMjudge/domjudge/blob/main/webapp/src/Controller/Jury/ScoreboardController.php#L42-L42 set the $jury param only to true if you have the ROLE_JURY, otherwise set it to false. Then in that same controller change the security to also have balloon in it. That should be all to make balloon users see the 'public' (what you call intrapublic...) scoreboard.

I think that makes it confusing whether you're looking at the real jury scoreboard, or the public scoreboard within the jury interface, both in the UI and in the jury controller code. I think it would be cleaner to instead if you're in the jury interface and don't have the right to view the jury scoreboard (as in this case balloon runners), we show a link in the menu to the public scoreboard (just like we show a link to the team UI if you're a jury member with a team associated to it).

nickygerritsen commented 2 years ago

That is not what I'm suggesting. What I want to do is in this method: http://github.com/DOMjudge/domjudge/blob/main/webapp/src/Controller/Jury/ScoreboardController.php#L42-L42 set the $jury param only to true if you have the ROLE_JURY, otherwise set it to false. Then in that same controller change the security to also have balloon in it. That should be all to make balloon users see the 'public' (what you call intrapublic...) scoreboard.

I think that makes it confusing whether you're looking at the real jury scoreboard, or the public scoreboard within the jury interface, both in the UI and in the jury controller code. I think it would be cleaner to instead if you're in the jury interface and don't have the right to view the jury scoreboard (as in this case balloon runners), we show a link in the menu to the public scoreboard (just like we show a link to the team UI if you're a jury member with a team associated to it).

The problem is/was if you make the contest non public. Then there IS no public scoreboard. Or are you suggesting that we do allow that for balloon users? That could also work.

Note that I don't fully agree with your statement btw: balloon users never see the jury scoreboard on that page, so is it really confusing? But I can live with adding the link if we show non-public contests there for balloon users.

eldering commented 2 years ago

The problem is/was if you make the contest non public. Then there IS no public scoreboard. Or are you suggesting that we do allow that for balloon users? That could also work.

Hmm, right, I overlooked that.

Note that I don't fully agree with your statement btw: balloon users never see the jury scoreboard on that page, so is it really confusing? But I can live with adding the link if we show non-public contests there for balloon users.

Well, I think it's confusing that you're in the jury interface but see a non-jury scoreboard, also in the code.

I'm thinking what the cleanest option is. One would be to give balloon runners an interface completely separate from the jury. There's actually no overlap: the balloon runners only need the balloons page, and the jury doesn't but needs all other pages.

Alternatively, it might be reasonable to give balloon users access to the public scoreboard, even for non-public contests. Actually, jury users should also have access to it, to see what it looks like.

@meisterT @thijskh what do you think?

nickygerritsen commented 2 years ago

A separate interface would also be fine. But I agree with that the jury should probably also see the public scoreboard. We even link to it from the jury scoreboard during freeze

nickygerritsen commented 2 years ago

What is the actual usecase for seeing the scoreboard as a balloon runner? Just wondering.

iMylene commented 2 years ago

What is the actual usecase for seeing the scoreboard as a balloon runner? Just wondering.

In practice, the runners like to see the main scoreboard for fun to see how their favorite team is doing overall.

So we do a split-screen in the balloon room with the balloon handout interface and the scoreboard.

nickygerritsen commented 2 years ago

Depending on how we do it (the clean way or the fast way) this is non trivial. I wonder if 'for fun' is a good argument, but I'm also not opposed to the idea.

vmcj commented 1 year ago

So I was looking at what should be moved outside and depending on how you use the system there are some more features which should probably be moved outside:

So the question is, should there be a /staff which can link to jury only features (80% of what lives under /jury)

For now I think the easiest way to close this issue is to make /staff/scoreboard which basically is a copy of /jury/scoreboard but has a warning on that this is "public" instead of unthawed information.