title: error installing a package " Installation failed, reverting ./composer.json and ./composer.lock to their original content. "
body: <p>i am trying to install spatie/sitemap package on my laravel package but i keep getting this error i don't know what's the problem :</p>
  <p>Your requirements could not be resolved to an installable set of packages.</p>
  <p>Problem 1</p>
  <pre class="lang-sh prettyprint-override"><code>    - spatie/crawler[5.0.2, ..., v5.x-dev] require guzzlehttp/psr7 ^1.4 -&gt; found guzzlehttp/psr7[1.4.0, ..., 1.x-dev] but the package is fixed to 2.0.0 
  (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
      - spatie/crawler[5.0.0, ..., 5.0.1] require php ^7.4 -&gt; your php version (8.0.1) does not satisfy that requirement.
      - spatie/crawler 7.0.0 requires guzzlehttp/psr7 ^1.8 -&gt; found guzzlehttp/psr7[1.8.0, 1.8.1, 1.8.2, 1.x-dev] but the package is fixed to 2.0.0 (lock 
  file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.
      - spatie/laravel-sitemap 6.0.4 requires spatie/crawler ^5.0 || ^7.0 -&gt; satisfiable by spatie/crawler[5.0.0, 5.0.1, 5.0.2, v5.x-dev, 7.0.0].
      - Root composer.json requires spatie/laravel-sitemap 6.0.4 -&gt; satisfiable by spatie/laravel-sitemap[6.0.4].
  
  Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.
  
  Installation failed, reverting ./composer.json and ./composer.lock to their original content.
  </code></pre>
  <p>i tried to specify the version of the package and used the latest one 6.0.4 but it didn't work too and i have no idea what to do !! please some help .</p>
  <p><strong>UPDATE</strong></p>
  <p>this is composer.json :</p>
  <pre><code>{
  &quot;name&quot;: &quot;laravel/laravel&quot;,
  &quot;type&quot;: &quot;project&quot;,
  &quot;description&quot;: &quot;The Laravel Framework.&quot;,
  &quot;keywords&quot;: [
      &quot;framework&quot;,
      &quot;laravel&quot;
  ],
  &quot;license&quot;: &quot;MIT&quot;,
  &quot;require&quot;: {
      &quot;php&quot;: &quot;^8.0&quot;,
      &quot;alexpechkarev/google-maps&quot;: &quot;^8.0&quot;,
      &quot;appstract/laravel-opcache&quot;: &quot;^4.0&quot;,
      &quot;cviebrock/eloquent-sluggable&quot;: &quot;^8.0&quot;,
      &quot;fideloper/proxy&quot;: &quot;^4.4&quot;,
      &quot;fruitcake/laravel-cors&quot;: &quot;^2.0&quot;,
      &quot;intervention/image&quot;: &quot;^2.5&quot;,
      &quot;laravel/framework&quot;: &quot;^8.12&quot;,
      &quot;laravel/tinker&quot;: &quot;^2.6&quot;,
      &quot;mews/captcha&quot;: &quot;^3.2&quot;,
      &quot;nesbot/carbon&quot;: &quot;^2.48&quot;,
      &quot;simplesoftwareio/simple-qrcode&quot;: &quot;~4&quot;
  },
  &quot;require-dev&quot;: {
      &quot;facade/ignition&quot;: &quot;^2.5&quot;,
      &quot;fakerphp/faker&quot;: &quot;^1.9.1&quot;,
      &quot;laravel/sail&quot;: &quot;^1.0.1&quot;,
      &quot;mockery/mockery&quot;: &quot;^1.4.2&quot;,
      &quot;nunomaduro/collision&quot;: &quot;^5.0&quot;,
      &quot;phpunit/phpunit&quot;: &quot;^9.3.3&quot;
  },
  &quot;config&quot;: {
      &quot;optimize-autoloader&quot;: true,
      &quot;preferred-install&quot;: &quot;dist&quot;,
      &quot;sort-packages&quot;: true
  },
  &quot;extra&quot;: {
      &quot;laravel&quot;: {
          &quot;dont-discover&quot;: []
      }
  },
  &quot;autoload&quot;: {
      &quot;psr-4&quot;: {
          &quot;App\\&quot;: &quot;app/&quot;,
          &quot;Database\\Factories\\&quot;: &quot;database/factories/&quot;,
          &quot;Database\\Seeders\\&quot;: &quot;database/seeders/&quot;
      }
  },
  &quot;autoload-dev&quot;: {
      &quot;psr-4&quot;: {
          &quot;Tests\\&quot;: &quot;tests/&quot;
      }
  },
  &quot;minimum-stability&quot;: &quot;dev&quot;,
  &quot;prefer-stable&quot;: true,
  &quot;scripts&quot;: {
      &quot;post-autoload-dump&quot;: [
          &quot;Illuminate\\Foundation\\ComposerScripts::postAutoloadDump&quot;,
          &quot;@php artisan package:discover --ansi&quot;
      ],
      &quot;post-root-package-install&quot;: [
          &quot;@php -r \&quot;file_exists('.env') || copy('.env.example', '.env');\&quot;&quot;
      ],
      &quot;post-create-project-cmd&quot;: [
          &quot;@php artisan key:generate --ansi&quot;
      ]
  }
  </code></pre>
  <p>}</p>