[ https://issues.apache.org/jira/browse/COMDEV-170?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17634077#comment-17634077 ]
Jan Høydahl commented on COMDEV-170: ------------------------------------ We noticed that projects lucene-core, lucene-pylucene are not listed on this page either, and found the bug. Here is a patch which fixes a bug where project-id (e.g. lucene-core) was used to lookup unixGroup. Now the list becomes much longer. I agree this page may be misleading for the reasons above, and e.g. the Commons projects would better be listed as one project instead of 43 separate ones? {code:java} Index: site/js/projects.js IDEA additional info: Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP <+>UTF-8 =================================================================== diff --git a/site/js/projects.js b/site/js/projects.js --- a/site/js/projects.js (revision 1905309) +++ b/site/js/projects.js (date 1668463359422) @@ -263,6 +263,24 @@ return appendElementWithInnerHTML(ul,'li',html); } +function projectIdToUnixGroup(projectId, pmcName) { + // Rerig the unix name and committee id + var unixgroup = projectId.split("-")[0]; + /* + Temp hack for podling names. TODO need to sort out generated names + */ + if (projectId.indexOf("incubator-") === 0) { + unixgroup = projectId.split("-")[1] + } + // special cases + if (unixgroup === "empire") unixgroup = "empire-db"; + if (unixgroup === "community") unixgroup = "comdev"; + if (pmcName === "attic") { + unixgroup = "attic"; + } + return unixgroup; +} + function renderProjectPage(project, projectId) { var obj = document.getElementById('contents'); @@ -278,20 +296,7 @@ fixProjectName(project); var isIncubating = project && (project.podling || (project.pmc == 'incubator')); - // Rerig the unix name and committee id - var unixgroup = projectId.split("-")[0]; - /* - Temp hack for podling names. TODO need to sort out generated names - */ - if (projectId.indexOf("incubator-") == 0) { - unixgroup = projectId.split("-")[1] - } - // special cases - if (unixgroup == "empire") unixgroup = "empire-db"; - if (unixgroup == "community") unixgroup = "comdev"; - if (project && project.pmc == "attic") { - unixgroup = "attic"; - } + var unixgroup = projectIdToUnixGroup(projectId, project && project.pmc); var committeeId = isIncubating ? 'incubator' : unixgroup; if (!committees[unixgroup]) { @@ -825,9 +830,10 @@ var lens = []; var lcount = {}; - for (i in projects) { - if (unixgroups[i] && i != 'incubator') { - var len = unixgroups[i].length; + for (projectId in projects) { + let unixGroup = projectIdToUnixGroup(projectId); + if (unixgroups[unixGroup] && projectId !== 'incubator') { + let len = unixgroups[unixGroup].length; if (lens.indexOf(len) < 0) { lens.push(len); lcount[len] = 0; @@ -842,15 +848,16 @@ for (l in lens) { var len = lens[l]; - var i; - for (i in projectsSorted) { - i = projectsSorted[i]; - if (unixgroups[i]) { - var xlen = unixgroups[i].length; + var projectId; + for (projectId in projectsSorted) { + projectId = projectsSorted[projectId]; + let unixGroup = projectIdToUnixGroup(projectId); + if (unixgroups[unixGroup]) { + var xlen = unixgroups[unixGroup].length; if (xlen == len) { - var html = projectIcon(projects[i].name) + projectLink(i) + ": " + len + " committers"; - if (unixgroups[i+'-pmc']) { - html += ", " + unixgroups[i+'-pmc'].length + " PMC members"; + var html = projectIcon(projects[projectId].name) + projectLink(projectId) + ": " + len + " committers"; + if (unixgroups[unixGroup+'-pmc']) { + html += ", " + unixgroups[unixGroup+'-pmc'].length + " PMC members"; } appendLiInnerHTML(ul,html); } {code} > issues in "Projects list by Number of Committers" > ------------------------------------------------- > > Key: COMDEV-170 > URL: https://issues.apache.org/jira/browse/COMDEV-170 > Project: Community Development > Issue Type: Bug > Components: Projects Tool > Reporter: Herve Boutemy > Priority: Major > > https://projects.apache.org/projects.html?number > misc issues: > - commons does not appear, neither any Creadur project > - list seems more related to committees than projects: only incubator is seen > by its projects instead of the Incubator PMC > perhaps we should move this list to "Committees by Number of Committers", and > incorporating Incubator as each of its podlings with committers = IPMC of > each podling -- This message was sent by Atlassian Jira (v8.20.10#820010) --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscr...@community.apache.org For additional commands, e-mail: dev-h...@community.apache.org