Uploaded image for project: 'Maven Dependency Plugin'
  1. Maven Dependency Plugin
  2. MDEP-679

mvn dependency:analyze detected wrong transitive dependency

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 3.1.1
    • 3.3.0
    • analyze

    Description

      To illustrate this issue, I created a sample project here: https://github.com/johnlinp/misc-demo/tree/master/maven-dependency-analyze-dnsjava

      The dependency tree is like this:

      My app ---> ApacheJMeter_http ---> dnsjava
      

      I didn't use any code directly from the artifact dnsjava in my app. I only used ApacheJMeter_http. However, the command mvn dependency:analyze will report a used undeclared dependency: dnsjava.

      [INFO] --- maven-dependency-plugin:3.1.1:analyze (default-cli) @ maven-dependency-analyze-dnsjava ---
      [WARNING] Used undeclared dependencies found:
      [WARNING]    dnsjava:dnsjava:jar:2.1.9:runtime 

      It seems that the problem came from the line:

      map.put("update", null);
      

      If I change it into map.put("create", null); or even map.put("UPDATE", null);, the problem will disappear. Therefore, I think there might be something to do with the string "update".

      Note that this issue is not reproducible in maven-dependency-plugin:2.8.

      Attachments

        Issue Links

          Activity

            People

              sjaranowski Slawomir Jaranowski
              johnlinp John Lin
              Votes:
              1 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 10m
                  10m