GuavaCZ / filament-knowledge-base

MIT License
144 stars 21 forks source link

Installation issue #51

Closed dharen008 closed 3 months ago

dharen008 commented 3 months ago

What happened?

After using composer require guava/filament-knowledge-base

There is a error upon installation:

- guava/filament-knowledge-base[1.0.0, ..., 1.0.1] require symfony/yaml ^6.4 -> found symfony/yaml[v6.4.0, v6.4.3, v6.4.7, v6.4.8] but the package is fixed to v7.1.1 (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.
- calebporzio/sushi[v2.5.0, ..., v2.5.2] require ext-sqlite3 * -> it is missing from your system. Install or enable PHP's sqlite3 extension.
- Root composer.json requires guava/filament-knowledge-base * -> satisfiable by guava/filament-knowledge-base[1.0.0, ..., 1.9.5].

To enable extensions, verify that they are enabled in your .ini files:

Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions. You can also try re-running composer require with an explicit version constraint, e.g. "composer require guava/filament-knowledge-base:*" to figure out if any version is installable, or "composer require guava/filament-knowledge-base:^2.1" if you know which you need.

Installation failed, reverting ./composer.json and ./composer.lock to their original content.

How to reproduce the bug

After using composer require guava/filament-knowledge-base

Package Version

3.1

PHP Version

8.2

Laravel Version

11

Which operating systems does with happen with?

Windows

Notes

No response

Alezx6 commented 3 months ago

Hola. Lograste instalar.

dharen008 commented 3 months ago

@lukas-frey Hi is there any update on this please? thank you

lukas-frey commented 3 months ago

Hi, as it says in the error message, install and enable the sqlite extension for your PHP installation.

dharen008 commented 3 months ago

Yes, I actually got it working by following those steps. If possible, please add them to the documentation.

These are the points that confused me but might also be helpful for others:

  1. Ensure the server has the ext-sqlite3 extension enabled.
  2. Install calebporzio/sushi version ^2.5.
  3. Make sure to include the Filament custom theme in vite.config.js.
  4. Clarify this part: Initially, I added it inside the boot function, even though the documentation says to place it in the register function:
    
    use Guava\FilamentKnowledgeBase\Filament\Panels\KnowledgeBasePanel;

public function register(): void { KnowledgeBasePanel::configureUsing( fn(KnowledgeBasePanel $panel) => $panel ->viteTheme('resources/css/filament/admin/theme.css') ); }


I encountered the same error as this post: https://github.com/GuavaCZ/filament-knowledge-base/issues/41#issuecomment-2265186878.

I'll reply there with my demo repo.
anyway thanks for your hard work on this!
lukas-frey commented 3 months ago
  1. I can add that to the docs. Since laravel by default uses sqlite, I assumed everyone would have sqlite installed.
  2. sushi is a dependency and is installed automatically when you install the package.
  3. This has nothing to do with the installation of the package, but with the installation of the custom theme and it's already described in the linked filament documentation + you get a warning with instructions what to do each time you install a custom theme.
  4. I'll emphasise this part better.