code: def _warnCount(self, warnings, warningCount=None):
          
          if not warningCount:
              warningCount = {}
  
          for warning in warnings:
              wID = warning["warning_id"]
              if not warningCount.get(wID):
                  warningCount[wID] = {}
                  warningCount[wID]["count"] = 1
                  warningCount[wID]["message"] = warning.get("warning_message")
              else:
                  warningCount[wID]["count"] += 1
  
          return warningCount
docs: Calculate the count of each warning, being given a list of them.
  
          @param warnings: L{list} of L{dict}s that come from
              L{tools.parsePyLintWarnings}.
          @param warningCount: A L{dict} produced by this method previously, if
              you are adding to the warnings.
  
          @return: L{dict} of L{dict}s for the warnings.