title: Why npm installs different version of dependency from what is specified in package-lock.json?
body: <p><strong>node -v</strong><br />
  v17.2.0</p>
  <p><strong>npm -v</strong><br />
  8.1.4</p>
  <p><strong>package.json</strong></p>
  <pre class="lang-js prettyprint-override"><code>{
    &quot;name&quot;: &quot;untitled&quot;,
    &quot;version&quot;: &quot;0.0.0&quot;,
    &quot;private&quot;: true,
    &quot;devDependencies&quot;: {
      &quot;stylelint&quot;: &quot;^14.1.0&quot;
    }
  }
  </code></pre>
  <p><strong>npm i</strong><br />
  <strong>npm list postcss</strong></p>
  <pre><code>/* Output:
  └─┬ stylelint@14.1.0
    ├─┬ postcss-safe-parser@6.0.0
    │ └── postcss@8.4.4 deduped
    └── postcss@8.4.4 (why is here version 8.4.4 ???)
  */
  </code></pre>
  <p>Stylelint repository main branch release 14.1.0
  package.json postcss dependency:
  <a href="https://github.com/stylelint/stylelint/blob/fcd5ac1ffa4f2ad1f06cb2277aad035ffe309ccc/package.json#L135" rel="nofollow noreferrer">https://github.com/stylelint/stylelint/blob/fcd5ac1ffa4f2ad1f06cb2277aad035ffe309ccc/package.json#L135</a>
  is 8.3.11</p>
  <p>So, the question is: why npm is installing version 8.4.4 when it should install 8.3.11? Am I missing something?</p>