filament-fabricator icon indicating copy to clipboard operation
filament-fabricator copied to clipboard

It block all artisan commands in docker

Open EsiNakesy opened this issue 1 year ago • 4 comments

When I try to use it inside Docker and run Artisan commands, it always throws this exception: `SQLSTATE[42P01]: Undefined table: 7 ERROR: relation "pages" does not exist LINE 1: select * from "pages" ^ (Connection: pgsql, SQL: select * from "pages")

at vendor/laravel/framework/src/Illuminate/Database/Connection.php:822 818▕ $this->getName(), $query, $this->prepareBindings($bindings), $e 819▕ ); 820▕ } 821▕ ➜ 822▕ throw new QueryException( 823▕ $this->getName(), $query, $this->prepareBindings($bindings), $e 824▕ ); 825▕ } 826▕ }

1 [internal]:0 Illuminate\Foundation\Application::Illuminate\Foundation{closure}(Object(Z3d0X\FilamentFabricator\FilamentFabricatorServiceProvider)) +12 vendor frames` this error happened because of the codes inside bootingPackage()

EsiNakesy avatar Dec 15 '23 21:12 EsiNakesy

it seems there is no support for this package anymore :(

EsiNakesy avatar Dec 20 '23 20:12 EsiNakesy

@EsiNakesy did you run the migrations? It should be done via php artisan filament-fabricator:install if you followed the documentation properly.

ksimenic avatar Jan 19 '24 08:01 ksimenic

@ksimenic it's completly diffrent topic, after you installed fabricator, if you try to move it from dev to prod since it considers that the page table is already exist you can not run migration or any other artisan command, so when docker try to build and run the services you will get an error that I mentioned. To replicate the issue:

  • install fabricator
  • remove the page table manually (also from migration table)
  • try to run migration to recreate the page table

EsiNakesy avatar Jan 30 '24 14:01 EsiNakesy

Could you share complete stacktrace / which line in FilamentFabricatorServiceProvider is throwing the error?

When I try to use it inside Docker and run Artisan commands, it always throws this exception: `SQLSTATE[42P01]: Undefined table: 7 ERROR: relation "pages" does not exist LINE 1: select * from "pages" ^ (Connection: pgsql, SQL: select * from "pages")

at vendor/laravel/framework/src/Illuminate/Database/Connection.php:822 818▕ $this->getName(), $query, $this->prepareBindings($bindings), $e 819▕ ); 820▕ } 821▕ ➜ 822▕ throw new QueryException( 823▕ $this->getName(), $query, $this->prepareBindings($bindings), $e 824▕ ); 825▕ } 826▕ }

1 [internal]:0 Illuminate\Foundation\Application::Illuminate\Foundation{closure}(Object(Z3d0X\FilamentFabricator\FilamentFabricatorServiceProvider)) +12 vendor frames` this error happened because of the codes inside bootingPackage()

Z3d0X avatar Feb 06 '24 11:02 Z3d0X