Conversation
This commit is an incomplete solution. While it does set the ranks according to the number of problems solved for "obeyFreeze" scoreboards, it does not maintain individual ranks for medalists. In addition, the teams within a number solved grouping should be sorted alphabetically by institution - they are not. This is a WIP.
In the case of the final public scoreboard using WF honors ranking (that is, obeyFreeze, unfrozen and finalized), we generate the XML standings report slightly differently. We use honors grouping logic so all teams in an honors group have the same rank (except for medalists - they all have their own rank, unless really tied). CI: Add Utilities method to return a default FinalizeData object (4g/4s/4b). Also charge ResultsFile to use the new method and remove its copy of the code. CI: In NSA, there was a bug where it wasn't properly counting Judged runs (CE's don't count as judged runs if CE's are set to be ignored). CI: Add code to the index.xsl to generate the HTML page for the public final scoreboard with "HM" as the rank for Honorable Mention teams, rather than putting a bogus rank there.
Changes to support public final scoreboard for WF Honors rules.
|
@JoeTerlizzi reports teams within an honors group not sorted properly. Should be sorted by # solved, then alphabetical univ name. Currently sorted by # solved, #points, alphabetical univ. name. |
There was a problem hiding this comment.
I reviewed all the changed files; I added a few minor comments/questions but there's nothing in the code that would stop me from approving the PR.
However, when I pull the code from the branch, build a distribution on my machine, and run the "Test Steps" listed in the PR, I do not get the expected scoreboard. Rather, I get a scoreboard that has all the teams with separate ranks, as follows:
I used the procedure of changing (both) the public and private scoreboard URLs via the PC2 admin; it generated HTML files in both my secret and my public locations -- but both scoreboards have ranks for all teams (as shown above; that one is the "secret" scoreboard).
Is it possible there's a missing step in the Test Steps?
| finalizeData.setBronzeRank(12); | ||
| finalizeData.setCertified(false); | ||
| finalizeData.setComment("Preliminary Results - Contest not Finalized"); | ||
| finalizeData.setUseWFGroupRanking(true); |
There was a problem hiding this comment.
Is it really the case that we want the default for useWFGroupRanking to be true? It seems like we ONLY use that value for WF contests... in which case false might be a more logical default?
There was a problem hiding this comment.
I agree, but I think that is out of scope for this issue and PR. I will open a new issue for changing the default ranking to non-WF Group Ranking. Issue #1219 created.
| if (finalizeData.getHonorSolvedCount() != 0) { | ||
| medianSolved = finalizeData.getHonorSolvedCount(); |
There was a problem hiding this comment.
The new static method getDefaultFinalizeData() (in src/edu/csus/ecs/pc2/core/model/FinalizeData.java) doesn't set a default value for honorSolvedCount. (I realize that it's an int, and that it's initialized to zero in its declaration... but still, it seems like that method should explicitly set it -- just like it's already explicitly setting certified to false and useWFGroupRanking to true even though those are the values
There was a problem hiding this comment.
Changed. Also as a CI, created static final int's for gold, silver and bronze default last ranks.
Next push.
| private void createStandingXML (TreeMap<StandingsRecord, StandingsRecord> treeMap, XMLMemento mementoRoot, | ||
| AccountList accountList, Problem[] problems, Hashtable<ElementId, Integer> problemsIndexHash, Group[] groups, | ||
| IInternalContest theContest, IMemento summaryMememento, boolean excludedGroups) { | ||
| IInternalContest theContest, IMemento summaryMememento, boolean excludedGroups, boolean isWFStandings, int medianSolved) { |
There was a problem hiding this comment.
Trivial, but it would be nice if the misspelling summaryMememento was fixed (to be summaryMemento).
There was a problem hiding this comment.
Changed.
Next push.
| <xsl:value-of select="@rank"/> | ||
| </xsl:otherwise> | ||
| </xsl:choose> | ||
| </td> |
There was a problem hiding this comment.
I reviewed the file data/xsl/index.xsl. I do not know very much about XSL; it "looks right" to me but that's all I can say.
There was a problem hiding this comment.
It does work... so, that's something.
|
Ok, adding the step "Unfreeze the Scoreboard" solves the problem outlined above; I can now see the expected scoreboard. |
clevengr
left a comment
There was a problem hiding this comment.
Once I added the step of unfreezing the scoreboard to the Test Steps, I was able to see the intended scoreboard.
I agree with the comment attributed to @JoeTerlizzi : I think the HM category shouldn't be strictly in alphabetical order; I think it should be sorted first by "Number Solved" and then in alphabetical order within teams solving the same number of problems. (This is not strictly speaking the "Bill Rule" -- but if we were going to strictly implement that rule then we should not be showing ANY details for the HM category -- no number solved, no score, no run details; just a list of team names. In THAT case, alphabetical by team would make sense... but I think it's better to show those details. So, I'd request a change so that HM teams with the same number solved are grouped together...
This is evidently a bug with the Settings tab. Apparently, when you FIRST changed the paths to something other than what I had them set to, it CLEARED the thawed state in the contest. (Which, by the way, is a neat trick.) Anyway, in order for it to work properly, you had to RE-Unfreeze it. If you hadn't changed the paths, it would have worked fine. By the way, I added a note in the test procedure saying that if you change the settings, then you have to also re-Unfreeze the contest. Created new issue #1213 |












Description of what the PR does
In the case of the final public scoreboard using WF honors ranking (that is, obeyFreeze, contest is unfrozen and finalized), we generate the XML standings report slightly differently. We use honors grouping logic so all teams in an honors group have the same rank (except for medalists - they all have their own rank, unless really tied).
CI: Add Utilities method to return a default
FinalizeDataobject (4g/4s/4b). Also chargeResultsFileto use the new method and remove its copy of the code.CI: In the New Scoring Algorithm, there was a bug where it wasn't properly counting judged runs (CE's don't count as judged runs if CE's are set to be ignored).
CI: Add code to the
index.xslto generate the HTML page for the public final scoreboard with "HM" as the rank for Honorable Mention teams, rather than putting a bogus rank there.Issue which the PR addresses
Fixes #1175
Environment in which the PR was developed (OS,IDE, Java version, etc.)
Windows 11
java version "1.8.0_321"
Java(TM) SE Runtime Environment (build 1.8.0_321-b07)
Java HotSpot(TM) 64-Bit Server VM (build 25.321-b07, mixed mode)
Precise steps for testing the PR (i.e., how to demonstrate that it works correctly)
WF49BakuFinalized.zipfile from the SysOps GDrive>CCS>PC2>profiles>passFailContests folder into a separate folder.The following steps presume that you've chosen to use the
WF49Baku Finalizedcontest./home/icpc/pc2This is where PC2 will place the generated scoreboards. If you want, you can change this by running a PC2 Admin after starting the server (below) and changing the path on the Settings tab. If you do change the scoreboard paths, be sure to also Unfreeze the scoreboard again. Apparently, changing any setting clears the thawed status of the contest (Bug?)./bin/pc2server --login s1 --contestpassword contest. This will automatically load the WF49Baku (finalized) contest into PC2../bin/pc2admin --login b1./home/icpc/pc2/wf49_finals_public. Look for "index.html" and double-click it to bring up a browser to view it. Note that the contest image (logo) will not appear at the top - there will be a blank place-holder since the contest header is not included by default.Notes
I would like to have this in 9.11, or at least available for NAC2026 since it is possible they may decide to rank the teams using WF style ranking rather then normal ranking. We do not have to merge this into develop, however, I'd ilke to get it approved PRIOR to NAC2026 and I will make up a special "
pc2board" that can be used in a pinch at NAC.Sample Images
...