Updating to 3.6.2 break Kirby

Hi there,

Today I updated my local installation of Kirby using composer. An error occurred as the website can’t launch anymore displaying the following error: “This page is currently offline due to an unexpected error”

I try to set Debug Mode: same behavior!

So I spend time to update PHP, refresh Brew (yes, I am on Mac !) and install Valet. The problem still occur!

So, I download last version of Kirby, remove the local Kirby/ and Vendor/ directory: everything worked fine!
So I try a “composer update”. The website does not launch anymore.

Here is my composer.json:

{
  "require": {
    "getkirby/cms": "^3.0",
    "omz13/kirby3-xmlsitemap": "^1.2",
    "omz13/kirby3-wellknown": "^0.2.1",
    "sylvainjule/matomo": "^1.0"
  },
  "config": {
    "optimize-autoloader": true,
    "allow-plugins": {
      "getkirby/composer-installer": false
    }
  }
}

And the output of the “composer update” command:

Loading composer repositories with package information
Updating dependencies
Nothing to modify in lock file
Installing dependencies from lock file (including require-dev)
Package operations: 15 installs, 0 updates, 0 removals
  - Installing getkirby/composer-installer (1.2.1): Extracting archive
  - Installing league/color-extractor (0.3.2): Extracting archive
  - Installing claviska/simpleimage (3.6.5): Extracting archive
  - Installing psr/log (1.1.4): Extracting archive
  - Installing filp/whoops (2.14.5): Extracting archive
  - Installing laminas/laminas-escaper (2.9.0): Extracting archive
  - Installing michelf/php-smartypants (1.8.1): Extracting archive
  - Installing omz13/kirby3-wellknown (0.2.1): Extracting archive
  - Installing omz13/kirby3-xmlsitemap (1.2.1): Extracting archive
  - Installing phpmailer/phpmailer (v6.5.3): Extracting archive
  - Installing sylvainjule/matomo (1.0.7): Extracting archive
  - Installing symfony/polyfill-mbstring (v1.24.0): Extracting archive
  - Installing symfony/polyfill-intl-idn (v1.24.0): Extracting archive
  - Installing getkirby/cms (3.6.2): Extracting archive
  - Installing symfony/polyfill-intl-normalizer (v1.24.0): Extracting archive
Generating optimized autoload files
Class omz13\K3WellKnown located in ./vendor/omz13/kirby3-wellknown/src/wellknown.php does not comply with psr-4 autoloading standard. Skipping.
Class omz13\XMLSitemap located in ./vendor/omz13/kirby3-xmlsitemap/src/xmlsitemap.php does not comply with psr-4 autoloading standard. Skipping.
9 packages you are using are looking for funding.
Use the `composer fund` command to find out more!

Any idea???

Make sure you don’t have two kirby folders.

I have only one Kirby folder!

But I noticed removing the Vendor directory make the website works again !
Is Kirby is looking for something in vendor???

It shouldn’t.

This is weird…

Here is the directory. The weird thing is Vendor directory is now in Kirby!


r

If you install Kirby via Composer, you should end up with a vendor folder inside your project root and no vendor folder inside the /kirby folder.

But in any case, depending on your setup (Kirby meets Composer | Kirby CMS), the kirby folder can also live inside the vendor folder (Kirby meets Composer | Kirby CMS)

Maybe remove the kirby folder again, check your composer.json and re-install.

This is what the structure looks like if you make a fresh composer install of the Starterkit:

.
├── README.md
├── assets
│   ├── css
│   ├── icons
│   └── js
├── composer.json
├── composer.lock
├── content
│   ├── 1_photography
│   ├── 2_notes
│   ├── 3_about
│   ├── error
│   ├── home
│   ├── sandbox
│   └── site.txt
├── favicon.ico
├── index.php
├── kirby
│   ├── SECURITY.md
│   ├── assets
│   ├── bootstrap.php
│   ├── cacert.pem
│   ├── composer.json
│   ├── composer.lock
│   ├── config
│   ├── dependencies
│   ├── i18n
│   ├── kirby.pub
│   ├── panel
│   ├── router.php
│   ├── src
│   └── views
├── site
│   ├── blueprints
│   ├── cache
│   ├── collections
│   ├── config
│   ├── controllers
│   ├── models
│   ├── snippets
│   └── templates
└── vendor
    ├── autoload.php
    ├── claviska
    ├── composer
    ├── filp
    ├── getkirby
    ├── laminas
    ├── league
    ├── michelf
    ├── phpmailer
    ├── psr
    └── symfony

So I removed both kirby and vendor folders, replace them by ones from a freshly downloaded version of Kirby. Then I replace composer.json by the one from Kirby meets Composer | Kirby CMS. I took care to copy the section related to plugins on a safe place!

I then run composer update. And answered yes –because I’m a YES man!– to the question:

Do you trust “getkirby/composer-installer” to execute code and wish to enable it now? (writes “allow-plugins” to composer.json) [y,n,d,?]

Everything ran fine on the terminal. Then CTRLed R the website… And everything was fine.
So I added the section related to plugins on the composer.json file.
Ran again composer update. Everything ran fine on the terminal. Then CTRLed R the website… And everything was fine.

So it’s OK, thank you!