CodeWithKyrian / transformersphp-background-removal

10 stars 3 forks source link

Laravel\Reverb\ConfigApplicationProvider::findById(): Argument #1 ($id) must be of type string #1

Closed pratikkuikel closed 2 months ago

pratikkuikel commented 2 months ago

Steps to reproduce :

  1. Follow the installation steps.
  2. Run the reverb, application and npm server and queue processor
  3. Open the local url in the browser upload an image
  4. Observe the error in the reverb terminal image

Stacktrace : [2024-08-31 15:23:46] local.ERROR: Laravel\Reverb\ConfigApplicationProvider::findById(): Argument #1 ($id) must be of type string, null given, called in C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\ConfigApplicationProvider.php on line 27 {"exception":"[object] (TypeError(code: 0): Laravel\Reverb\ConfigApplicationProvider::findById(): Argument #1 ($id) must be of type string, null given, called in C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\ConfigApplicationProvider.php on line 27 at C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\ConfigApplicationProvider.php:36) [stacktrace]

0 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\ConfigApplicationProvider.php(27): Laravel\Reverb\ConfigApplicationProvider->findById(NULL)

1 [internal function]: Laravel\Reverb\ConfigApplicationProvider->Laravel\Reverb\{closure}(Array, 0)

2 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Collections\Arr.php(605): array_map(Object(Closure), Array, Array)

3 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Collections\Collection.php(785): Illuminate\Support\Arr::map(Array, Object(Closure))

4 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\ConfigApplicationProvider.php(26): Illuminate\Support\Collection->map(Object(Closure))

5 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\Jobs\PruneStaleConnections.php(23): Laravel\Reverb\ConfigApplicationProvider->all()

6 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(36): Laravel\Reverb\Jobs\PruneStaleConnections->handle(Object(Laravel\Reverb\Protocols\Pusher\Managers\ArrayChannelManager))

7 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\Util.php(43): Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()

8 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(95): Illuminate\Container\Util::unwrapIfClosure(Object(Closure))

9 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(35): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))

10 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\Container.php(690): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)

11 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Bus\Dispatcher.php(128): Illuminate\Container\Container->call(Array)

12 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Pipeline\Pipeline.php(144): Illuminate\Bus\Dispatcher->Illuminate\Bus\{closure}(Object(Laravel\Reverb\Jobs\PruneStaleConnections))

13 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Pipeline\Pipeline.php(119): Illuminate\Pipeline\Pipeline->Illuminate\Pipeline\{closure}(Object(Laravel\Reverb\Jobs\PruneStaleConnections))

14 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Bus\Dispatcher.php(132): Illuminate\Pipeline\Pipeline->then(Object(Closure))

15 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Bus\Dispatcher.php(78): Illuminate\Bus\Dispatcher->dispatchNow(Object(Laravel\Reverb\Jobs\PruneStaleConnections))

16 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Foundation\Bus\PendingDispatch.php(193): Illuminate\Bus\Dispatcher->dispatch(Object(Laravel\Reverb\Jobs\PruneStaleConnections))

17 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Foundation\Bus\Dispatchable.php(19): Illuminate\Foundation\Bus\PendingDispatch->__destruct()

18 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\Servers\Reverb\Console\Commands\StartServer.php(94): Laravel\Reverb\Jobs\PruneStaleConnections::dispatch()

19 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\react\event-loop\src\Timer\Timers.php(102): Laravel\Reverb\Servers\Reverb\Console\Commands\StartServer->Laravel\Reverb\Servers\Reverb\Console\Commands\{closure}(Object(React\EventLoop\Timer\Timer))

20 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\react\event-loop\src\StreamSelectLoop.php(185): React\EventLoop\Timer\Timers->tick()

21 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\Servers\Reverb\Http\Server.php(41): React\EventLoop\StreamSelectLoop->run()

22 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\reverb\src\Servers\Reverb\Console\Commands\StartServer.php(74): Laravel\Reverb\Servers\Reverb\Http\Server->start()

23 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(36): Laravel\Reverb\Servers\Reverb\Console\Commands\StartServer->handle()

24 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\Util.php(43): Illuminate\Container\BoundMethod::Illuminate\Container\{closure}()

25 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(95): Illuminate\Container\Util::unwrapIfClosure(Object(Closure))

26 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\BoundMethod.php(35): Illuminate\Container\BoundMethod::callBoundMethod(Object(Illuminate\Foundation\Application), Array, Object(Closure))

27 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Container\Container.php(690): Illuminate\Container\BoundMethod::call(Object(Illuminate\Foundation\Application), Array, Array, NULL)

28 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Console\Command.php(213): Illuminate\Container\Container->call(Array)

29 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\symfony\console\Command\Command.php(279): Illuminate\Console\Command->execute(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))

30 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Console\Command.php(182): Symfony\Component\Console\Command\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Illuminate\Console\OutputStyle))

31 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\symfony\console\Application.php(1047): Illuminate\Console\Command->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

32 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\symfony\console\Application.php(316): Symfony\Component\Console\Application->doRunCommand(Object(Laravel\Reverb\Servers\Reverb\Console\Commands\StartServer), Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

33 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\symfony\console\Application.php(167): Symfony\Component\Console\Application->doRun(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

34 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Foundation\Console\Kernel.php(197): Symfony\Component\Console\Application->run(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

35 C:\Users\crypto\Desktop\transformersphp-background-removal\vendor\laravel\framework\src\Illuminate\Foundation\Application.php(1203): Illuminate\Foundation\Console\Kernel->handle(Object(Symfony\Component\Console\Input\ArgvInput), Object(Symfony\Component\Console\Output\ConsoleOutput))

36 C:\Users\crypto\Desktop\transformersphp-background-removal\artisan(13): Illuminate\Foundation\Application->handleCommand(Object(Symfony\Component\Console\Input\ArgvInput))

37 {main}

"}

CodeWithKyrian commented 2 months ago

Resolved?

pratikkuikel commented 2 months ago

@CodeWithKyrian This was due to missing reverb .env variables : REVERB_APP_ID=app-id REVERB_APP_KEY=app-key REVERB_APP_SECRET=app-secret REVERB_HOST=127.0.0.1 REVERB_PORT=8080 REVERB_SCHEME="http"

VITE_REVERB_APP_KEY="${REVERB_APP_KEY}" VITE_REVERB_HOST="${REVERB_HOST}" VITE_REVERB_PORT="${REVERB_PORT}" VITE_REVERB_SCHEME="${REVERB_SCHEME}"

This issue has been fixed, however there are other issues.