=== Checking Pengawas Data === SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) (Connection: mysql, SQL: select * from `settings` where `key` = tahun_ajaran_aktif limit 1) (500 Internal Server Error)

Symfony Exception

PDOException QueryException

HTTP 500 Internal Server Error

SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) (Connection: mysql, SQL: select * from `settings` where `key` = tahun_ajaran_aktif limit 1)

Exceptions 2

Illuminate\Database\ QueryException

Show exception properties
Illuminate\Database\QueryException {#1765
  +errorInfo: array:3 [
    0 => "HY000"
    1 => 1045
    2 => "Access denied for user 'root'@'localhost' (using password: NO)"
  ]
  +connectionName: "mysql"
  #sql: "select * from `settings` where `key` = ? limit 1"
  #bindings: array:1 [
    0 => "tahun_ajaran_aktif"
  ]
}
  1.                 throw new UniqueConstraintViolationException(
  2.                     $this->getName(), $query$this->prepareBindings($bindings), $e
  3.                 );
  4.             }
  5.             throw new QueryException(
  6.                 $this->getName(), $query$this->prepareBindings($bindings), $e
  7.             );
  8.         }
  9.     }
  1.     protected function tryAgainIfCausedByLostConnection(QueryException $e$query$bindingsClosure $callback)
  2.     {
  3.         if ($this->causedByLostConnection($e->getPrevious())) {
  4.             $this->reconnect();
  5.             return $this->runQueryCallback($query$bindings$callback);
  6.         }
  7.         throw $e;
  8.     }
  1.     {
  2.         if ($this->transactions >= 1) {
  3.             throw $e;
  4.         }
  5.         return $this->tryAgainIfCausedByLostConnection(
  6.             $e$query$bindings$callback
  7.         );
  8.     }
  9.     /**
  1.         // caused by a connection that has been lost. If that is the cause, we'll try
  2.         // to re-establish connection and re-run the query with a fresh connection.
  3.         try {
  4.             $result $this->runQueryCallback($query$bindings$callback);
  5.         } catch (QueryException $e) {
  6.             $result $this->handleQueryException(
  7.                 $e$query$bindings$callback
  8.             );
  9.         }
  10.         // Once we have run the query we will calculate the time that it took to run and
  1.      * @param  bool  $useReadPdo
  2.      * @return array
  3.      */
  4.     public function select($query$bindings = [], $useReadPdo true)
  5.     {
  6.         return $this->run($query$bindings, function ($query$bindings) use ($useReadPdo) {
  7.             if ($this->pretending()) {
  8.                 return [];
  9.             }
  10.             // For select statements, we'll simply execute the query and return an array
  1.      *
  2.      * @return array
  3.      */
  4.     protected function runSelect()
  5.     {
  6.         return $this->connection->select(
  7.             $this->toSql(), $this->getBindings(), ! $this->useWritePdo
  8.         );
  9.     }
  10.     /**
  1.      * @return \Illuminate\Support\Collection<int, \stdClass>
  2.      */
  3.     public function get($columns = ['*'])
  4.     {
  5.         $items = new Collection($this->onceWithColumns(Arr::wrap($columns), function () {
  6.             return $this->processor->processSelect($this$this->runSelect());
  7.         }));
  8.         return $this->applyAfterQueryCallbacks(
  9.             isset($this->groupLimit) ? $this->withoutGroupLimitKeys($items) : $items
  10.         );
  1.         if (is_null($original)) {
  2.             $this->columns $columns;
  3.         }
  4.         $result $callback();
  5.         $this->columns $original;
  6.         return $result;
  7.     }
  1.      * @param  string|\Illuminate\Contracts\Database\Query\Expression|array<string|\Illuminate\Contracts\Database\Query\Expression>  $columns
  2.      * @return \Illuminate\Support\Collection<int, \stdClass>
  3.      */
  4.     public function get($columns = ['*'])
  5.     {
  6.         $items = new Collection($this->onceWithColumns(Arr::wrap($columns), function () {
  7.             return $this->processor->processSelect($this$this->runSelect());
  8.         }));
  9.         return $this->applyAfterQueryCallbacks(
  10.             isset($this->groupLimit) ? $this->withoutGroupLimitKeys($items) : $items
  1.      * @return array<int, TModel>
  2.      */
  3.     public function getModels($columns = ['*'])
  4.     {
  5.         return $this->model->hydrate(
  6.             $this->query->get($columns)->all()
  7.         )->all();
  8.     }
  9.     /**
  10.      * Eager load the relationships for the models.
  1.         $builder $this->applyScopes();
  2.         // If we actually found models we will also eager load any relationships that
  3.         // have been specified as needing to be eager loaded, which will solve the
  4.         // n+1 query issue for the developers to avoid running a lot of queries.
  5.         if (count($models $builder->getModels($columns)) > 0) {
  6.             $models $builder->eagerLoadRelations($models);
  7.         }
  8.         return $this->applyAfterQueryCallbacks(
  9.             $builder->getModel()->newCollection($models)
  1.      * @param  array|string  $columns
  2.      * @return TValue|null
  3.      */
  4.     public function first($columns = ['*'])
  5.     {
  6.         return $this->limit(1)->get($columns)->first();
  7.     }
  8.     /**
  9.      * Execute the query and get the first result or throw an exception.
  10.      *
  1.     /**
  2.      * Get setting by key
  3.      */
  4.     public static function get($key$default null)
  5.     {
  6.         $setting self::where('key'$key)->first();
  7.         return $setting $setting->value $default;
  8.     }
  9.     /**
  10.      * Set setting value
Setting::get('tahun_ajaran_aktif', '2025/2026') in /home/dataslbm/sip.web.id/app/Providers/AppServiceProvider.php (line 37)
  1.             } else {
  2.                 $tahunAjaranAktif = ($currentYear 1) . '/' $currentYear;
  3.             }
  4.             
  5.             // Try to get from settings, fallback to calculated value
  6.             $tahunAjaranAktif Setting::get('tahun_ajaran_aktif'$tahunAjaranAktif);
  7.             
  8.             $view->with('tahunAjaranAktif'$tahunAjaranAktif);
  9.         });
  10.     }
  11. }
  1.      */
  2.     protected function addEventListener($name$callback)
  3.     {
  4.         if (str_contains($name'*')) {
  5.             $callback = function ($name, array $data) use ($callback) {
  6.                 return $callback($data[0]);
  7.             };
  8.         }
  9.         $this->events->listen($name$callback);
  10.     }
  1.             return $this->createClassListener($listener$wildcard);
  2.         }
  3.         return function ($event$payload) use ($listener$wildcard) {
  4.             if ($wildcard) {
  5.                 return $listener($event$payload);
  6.             }
  7.             return $listener(...array_values($payload));
  8.         };
  9.     }
  1.         }
  2.         $responses = [];
  3.         foreach ($this->getListeners($event) as $listener) {
  4.             $response $listener($event$payload);
  5.             // If a response is returned from the listener and event halting is enabled
  6.             // we will just return this response, and not call the rest of the event
  7.             // listeners. Otherwise we will add the response on the response list.
  8.             if ($halt && ! is_null($response)) {
  1.             );
  2.             return null;
  3.         }
  4.         return $this->invokeListeners($parsedEvent$parsedPayload$halt);
  5.     }
  6.     /**
  7.      * Broadcast an event and call its listeners.
  8.      *
  1.      * @return void
  2.      */
  3.     public function callComposer(ViewContract $view)
  4.     {
  5.         if ($this->events->hasListeners($event 'composing: '.$view->name())) {
  6.             $this->events->dispatch($event, [$view]);
  7.         }
  8.     }
  9.     /**
  10.      * Call the creator for a given view.
  1.         // We will keep track of the number of views being rendered so we can flush
  2.         // the section after the complete rendering operation is done. This will
  3.         // clear out the sections for any separate views that may be rendered.
  4.         $this->factory->incrementRender();
  5.         $this->factory->callComposer($this);
  6.         $contents $this->getContents();
  7.         // Once we've finished rendering the view, we'll decrement the render count
  8.         // so that each section gets flushed out next time a view is created and
  1.      * @throws \Throwable
  2.      */
  3.     public function render(?callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         $exception = new Exception($flattenException$request$this->listener$this->basePath);
  2.         $exceptionAsMarkdown $this->viewFactory->make('laravel-exceptions-renderer::markdown', [
  3.             'exception' => $exception,
  4.         ])->render();
  5.         return $this->viewFactory->make('laravel-exceptions-renderer::show', [
  6.             'exception' => $exception,
  7.             'exceptionAsMarkdown' => $exceptionAsMarkdown,
  8.         ])->render();
  1.         try {
  2.             if (config('app.debug')) {
  3.                 if (app()->has(ExceptionRenderer::class)) {
  4.                     return $this->renderExceptionWithCustomRenderer($e);
  5.                 } elseif ($this->container->bound(Renderer::class)) {
  6.                     return $this->container->make(Renderer::class)->render(request(), $e);
  7.                 }
  8.             }
  9.             return $this->renderExceptionWithSymfony($econfig('app.debug'));
  10.         } catch (Throwable $e) {
  1.      * @return \Symfony\Component\HttpFoundation\Response
  2.      */
  3.     protected function convertExceptionToResponse(Throwable $e)
  4.     {
  5.         return new SymfonyResponse(
  6.             $this->renderExceptionContent($e),
  7.             $this->isHttpException($e) ? $e->getStatusCode() : 500,
  8.             $this->isHttpException($e) ? $e->getHeaders() : []
  9.         );
  10.     }
  1.      * @return \Illuminate\Http\Response|\Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse
  2.      */
  3.     protected function prepareResponse($requestThrowable $e)
  4.     {
  5.         if (! $this->isHttpException($e) && config('app.debug')) {
  6.             return $this->toIlluminateResponse($this->convertExceptionToResponse($e), $e)->prepare($request);
  7.         }
  8.         if (! $this->isHttpException($e)) {
  9.             $e = new HttpException(500$e->getMessage(), $e);
  10.         }
  1.      */
  2.     protected function renderExceptionResponse($requestThrowable $e)
  3.     {
  4.         return $this->shouldReturnJson($request$e)
  5.             ? $this->prepareJsonResponse($request$e)
  6.             : $this->prepareResponse($request$e);
  7.     }
  8.     /**
  9.      * Convert an authentication exception into a response.
  10.      *
  1.         return $this->finalizeRenderedResponse($request, match (true) {
  2.             $e instanceof HttpResponseException => $e->getResponse(),
  3.             $e instanceof AuthenticationException => $this->unauthenticated($request$e),
  4.             $e instanceof ValidationException => $this->convertValidationExceptionToResponse($e$request),
  5.             default => $this->renderExceptionResponse($request$e),
  6.         }, $e);
  7.     }
  8.     /**
  9.      * Prepare the final, rendered response to be returned to the browser.
  1.      * @param  \Throwable  $e
  2.      * @return void
  3.      */
  4.     protected function renderHttpResponse(Throwable $e)
  5.     {
  6.         $this->getExceptionHandler()->render(static::$app['request'], $e)->send();
  7.     }
  8.     /**
  9.      * Handle the PHP shutdown event.
  10.      *
  1.             if ($exceptionHandlerFailed ?? false) {
  2.                 exit(1);
  3.             }
  4.         } else {
  5.             $this->renderHttpResponse($e);
  6.         }
  7.     }
  8.     /**
  9.      * Render an exception to the console.
  1.      * @return callable
  2.      */
  3.     protected function forwardsTo($method)
  4.     {
  5.         return fn (...$arguments) => static::$app
  6.             $this->{$method}(...$arguments)
  7.             : false;
  8.     }
  9.     /**
  10.      * Determine if the error level is a deprecation.
HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}(object(QueryException))

PDOException

SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO)

  1.      * @return \PDO
  2.      */
  3.     protected function createPdoConnection($dsn$username, #[\SensitiveParameter$password$options)
  4.     {
  5.         return version_compare(phpversion(), '8.4.0''<')
  6.             ? new PDO($dsn$username$password$options)
  7.             : PDO::connect($dsn$username$password$options); /** @phpstan-ignore staticMethod.notFound (PHP 8.4) */
  8.     }
  9.     /**
  10.      * Handle an exception that occurred during connect execution.
  1.      * @return \PDO
  2.      */
  3.     protected function createPdoConnection($dsn$username, #[\SensitiveParameter$password$options)
  4.     {
  5.         return version_compare(phpversion(), '8.4.0''<')
  6.             ? new PDO($dsn$username$password$options)
  7.             : PDO::connect($dsn$username$password$options); /** @phpstan-ignore staticMethod.notFound (PHP 8.4) */
  8.     }
  9.     /**
  10.      * Handle an exception that occurred during connect execution.
  1.      * @throws \Throwable
  2.      */
  3.     protected function tryAgainIfCausedByLostConnection(Throwable $e$dsn$username, #[\SensitiveParameter$password$options)
  4.     {
  5.         if ($this->causedByLostConnection($e)) {
  6.             return $this->createPdoConnection($dsn$username$password$options);
  7.         }
  8.         throw $e;
  9.     }
  1.         try {
  2.             return $this->createPdoConnection(
  3.                 $dsn$username$password$options
  4.             );
  5.         } catch (Exception $e) {
  6.             return $this->tryAgainIfCausedByLostConnection(
  7.                 $e$dsn$username$password$options
  8.             );
  9.         }
  10.     }
  1.         $options $this->getOptions($config);
  2.         // We need to grab the PDO options that should be used while making the brand
  3.         // new connection instance. The PDO options control various aspects of the
  4.         // connection's behavior, and some might be specified by the developers.
  5.         $connection $this->createConnection($dsn$config$options);
  6.         if (! empty($config['database']) &&
  7.             (! isset($config['use_db_after_connecting']) ||
  8.              $config['use_db_after_connecting'])) {
  9.             $connection->exec("use `{$config['database']}`;");
  1.         return function () use ($config) {
  2.             foreach (Arr::shuffle($this->parseHosts($config)) as $host) {
  3.                 $config['host'] = $host;
  4.                 try {
  5.                     return $this->createConnector($config)->connect($config);
  6.                 } catch (PDOException $e) {
  7.                     continue;
  8.                 }
  9.             }
ConnectionFactory->Illuminate\Database\Connectors\{closure}()
  1.      * @return \PDO
  2.      */
  3.     public function getPdo()
  4.     {
  5.         if ($this->pdo instanceof Closure) {
  6.             return $this->pdo call_user_func($this->pdo);
  7.         }
  8.         return $this->pdo;
  9.     }
  1.         if ($this->readPdo instanceof Closure) {
  2.             return $this->readPdo call_user_func($this->readPdo);
  3.         }
  4.         return $this->readPdo ?: $this->getPdo();
  5.     }
  6.     /**
  7.      * Get the current read PDO connection parameter without executing any reconnect logic.
  8.      *
  1.      * @param  bool  $useReadPdo
  2.      * @return \PDO
  3.      */
  4.     protected function getPdoForSelect($useReadPdo true)
  5.     {
  6.         return $useReadPdo $this->getReadPdo() : $this->getPdo();
  7.     }
  8.     /**
  9.      * Run an insert statement against the database.
  10.      *
  1.             // For select statements, we'll simply execute the query and return an array
  2.             // of the database result set. Each element in the array will be a single
  3.             // row from the database table, and will either be an array or objects.
  4.             $statement $this->prepared(
  5.                 $this->getPdoForSelect($useReadPdo)->prepare($query)
  6.             );
  7.             $this->bindValues($statement$this->prepareBindings($bindings));
  8.             $statement->execute();
  1.     {
  2.         // To execute the statement, we'll simply call the callback, which will actually
  3.         // run the SQL against the PDO connection. Then we can calculate the time it
  4.         // took to execute and log the query SQL, bindings and time in our memory.
  5.         try {
  6.             return $callback($query$bindings);
  7.         }
  8.         // If an exception occurs when attempting to run a query, we'll format the error
  9.         // message to include the bindings with SQL, which will make this exception a
  10.         // lot more helpful to the developer instead of just the database's errors.
  1.     protected function tryAgainIfCausedByLostConnection(QueryException $e$query$bindingsClosure $callback)
  2.     {
  3.         if ($this->causedByLostConnection($e->getPrevious())) {
  4.             $this->reconnect();
  5.             return $this->runQueryCallback($query$bindings$callback);
  6.         }
  7.         throw $e;
  8.     }
  1.     {
  2.         if ($this->transactions >= 1) {
  3.             throw $e;
  4.         }
  5.         return $this->tryAgainIfCausedByLostConnection(
  6.             $e$query$bindings$callback
  7.         );
  8.     }
  9.     /**
  1.         // caused by a connection that has been lost. If that is the cause, we'll try
  2.         // to re-establish connection and re-run the query with a fresh connection.
  3.         try {
  4.             $result $this->runQueryCallback($query$bindings$callback);
  5.         } catch (QueryException $e) {
  6.             $result $this->handleQueryException(
  7.                 $e$query$bindings$callback
  8.             );
  9.         }
  10.         // Once we have run the query we will calculate the time that it took to run and
  1.      * @param  bool  $useReadPdo
  2.      * @return array
  3.      */
  4.     public function select($query$bindings = [], $useReadPdo true)
  5.     {
  6.         return $this->run($query$bindings, function ($query$bindings) use ($useReadPdo) {
  7.             if ($this->pretending()) {
  8.                 return [];
  9.             }
  10.             // For select statements, we'll simply execute the query and return an array
  1.      *
  2.      * @return array
  3.      */
  4.     protected function runSelect()
  5.     {
  6.         return $this->connection->select(
  7.             $this->toSql(), $this->getBindings(), ! $this->useWritePdo
  8.         );
  9.     }
  10.     /**
  1.      * @return \Illuminate\Support\Collection<int, \stdClass>
  2.      */
  3.     public function get($columns = ['*'])
  4.     {
  5.         $items = new Collection($this->onceWithColumns(Arr::wrap($columns), function () {
  6.             return $this->processor->processSelect($this$this->runSelect());
  7.         }));
  8.         return $this->applyAfterQueryCallbacks(
  9.             isset($this->groupLimit) ? $this->withoutGroupLimitKeys($items) : $items
  10.         );
  1.         if (is_null($original)) {
  2.             $this->columns $columns;
  3.         }
  4.         $result $callback();
  5.         $this->columns $original;
  6.         return $result;
  7.     }
  1.      * @param  string|\Illuminate\Contracts\Database\Query\Expression|array<string|\Illuminate\Contracts\Database\Query\Expression>  $columns
  2.      * @return \Illuminate\Support\Collection<int, \stdClass>
  3.      */
  4.     public function get($columns = ['*'])
  5.     {
  6.         $items = new Collection($this->onceWithColumns(Arr::wrap($columns), function () {
  7.             return $this->processor->processSelect($this$this->runSelect());
  8.         }));
  9.         return $this->applyAfterQueryCallbacks(
  10.             isset($this->groupLimit) ? $this->withoutGroupLimitKeys($items) : $items
  1.      * @return array<int, TModel>
  2.      */
  3.     public function getModels($columns = ['*'])
  4.     {
  5.         return $this->model->hydrate(
  6.             $this->query->get($columns)->all()
  7.         )->all();
  8.     }
  9.     /**
  10.      * Eager load the relationships for the models.
  1.         $builder $this->applyScopes();
  2.         // If we actually found models we will also eager load any relationships that
  3.         // have been specified as needing to be eager loaded, which will solve the
  4.         // n+1 query issue for the developers to avoid running a lot of queries.
  5.         if (count($models $builder->getModels($columns)) > 0) {
  6.             $models $builder->eagerLoadRelations($models);
  7.         }
  8.         return $this->applyAfterQueryCallbacks(
  9.             $builder->getModel()->newCollection($models)
  1.      * @param  array|string  $columns
  2.      * @return TValue|null
  3.      */
  4.     public function first($columns = ['*'])
  5.     {
  6.         return $this->limit(1)->get($columns)->first();
  7.     }
  8.     /**
  9.      * Execute the query and get the first result or throw an exception.
  10.      *
  1.     /**
  2.      * Get setting by key
  3.      */
  4.     public static function get($key$default null)
  5.     {
  6.         $setting self::where('key'$key)->first();
  7.         return $setting $setting->value $default;
  8.     }
  9.     /**
  10.      * Set setting value
Setting::get('tahun_ajaran_aktif', '2025/2026') in /home/dataslbm/sip.web.id/app/Providers/AppServiceProvider.php (line 37)
  1.             } else {
  2.                 $tahunAjaranAktif = ($currentYear 1) . '/' $currentYear;
  3.             }
  4.             
  5.             // Try to get from settings, fallback to calculated value
  6.             $tahunAjaranAktif Setting::get('tahun_ajaran_aktif'$tahunAjaranAktif);
  7.             
  8.             $view->with('tahunAjaranAktif'$tahunAjaranAktif);
  9.         });
  10.     }
  11. }
  1.      */
  2.     protected function addEventListener($name$callback)
  3.     {
  4.         if (str_contains($name'*')) {
  5.             $callback = function ($name, array $data) use ($callback) {
  6.                 return $callback($data[0]);
  7.             };
  8.         }
  9.         $this->events->listen($name$callback);
  10.     }
  1.             return $this->createClassListener($listener$wildcard);
  2.         }
  3.         return function ($event$payload) use ($listener$wildcard) {
  4.             if ($wildcard) {
  5.                 return $listener($event$payload);
  6.             }
  7.             return $listener(...array_values($payload));
  8.         };
  9.     }
  1.         }
  2.         $responses = [];
  3.         foreach ($this->getListeners($event) as $listener) {
  4.             $response $listener($event$payload);
  5.             // If a response is returned from the listener and event halting is enabled
  6.             // we will just return this response, and not call the rest of the event
  7.             // listeners. Otherwise we will add the response on the response list.
  8.             if ($halt && ! is_null($response)) {
  1.             );
  2.             return null;
  3.         }
  4.         return $this->invokeListeners($parsedEvent$parsedPayload$halt);
  5.     }
  6.     /**
  7.      * Broadcast an event and call its listeners.
  8.      *
  1.      * @return void
  2.      */
  3.     public function callComposer(ViewContract $view)
  4.     {
  5.         if ($this->events->hasListeners($event 'composing: '.$view->name())) {
  6.             $this->events->dispatch($event, [$view]);
  7.         }
  8.     }
  9.     /**
  10.      * Call the creator for a given view.
  1.         // We will keep track of the number of views being rendered so we can flush
  2.         // the section after the complete rendering operation is done. This will
  3.         // clear out the sections for any separate views that may be rendered.
  4.         $this->factory->incrementRender();
  5.         $this->factory->callComposer($this);
  6.         $contents $this->getContents();
  7.         // Once we've finished rendering the view, we'll decrement the render count
  8.         // so that each section gets flushed out next time a view is created and
  1.      * @throws \Throwable
  2.      */
  3.     public function render(?callable $callback null)
  4.     {
  5.         try {
  6.             $contents $this->renderContents();
  7.             $response = isset($callback) ? $callback($this$contents) : null;
  8.             // Once we have the contents of the view, we will flush the sections if we are
  9.             // done rendering all views so that there is nothing left hanging over when
  1.         $exception = new Exception($flattenException$request$this->listener$this->basePath);
  2.         $exceptionAsMarkdown $this->viewFactory->make('laravel-exceptions-renderer::markdown', [
  3.             'exception' => $exception,
  4.         ])->render();
  5.         return $this->viewFactory->make('laravel-exceptions-renderer::show', [
  6.             'exception' => $exception,
  7.             'exceptionAsMarkdown' => $exceptionAsMarkdown,
  8.         ])->render();
  1.         try {
  2.             if (config('app.debug')) {
  3.                 if (app()->has(ExceptionRenderer::class)) {
  4.                     return $this->renderExceptionWithCustomRenderer($e);
  5.                 } elseif ($this->container->bound(Renderer::class)) {
  6.                     return $this->container->make(Renderer::class)->render(request(), $e);
  7.                 }
  8.             }
  9.             return $this->renderExceptionWithSymfony($econfig('app.debug'));
  10.         } catch (Throwable $e) {
  1.      * @return \Symfony\Component\HttpFoundation\Response
  2.      */
  3.     protected function convertExceptionToResponse(Throwable $e)
  4.     {
  5.         return new SymfonyResponse(
  6.             $this->renderExceptionContent($e),
  7.             $this->isHttpException($e) ? $e->getStatusCode() : 500,
  8.             $this->isHttpException($e) ? $e->getHeaders() : []
  9.         );
  10.     }
  1.      * @return \Illuminate\Http\Response|\Illuminate\Http\JsonResponse|\Illuminate\Http\RedirectResponse
  2.      */
  3.     protected function prepareResponse($requestThrowable $e)
  4.     {
  5.         if (! $this->isHttpException($e) && config('app.debug')) {
  6.             return $this->toIlluminateResponse($this->convertExceptionToResponse($e), $e)->prepare($request);
  7.         }
  8.         if (! $this->isHttpException($e)) {
  9.             $e = new HttpException(500$e->getMessage(), $e);
  10.         }
  1.      */
  2.     protected function renderExceptionResponse($requestThrowable $e)
  3.     {
  4.         return $this->shouldReturnJson($request$e)
  5.             ? $this->prepareJsonResponse($request$e)
  6.             : $this->prepareResponse($request$e);
  7.     }
  8.     /**
  9.      * Convert an authentication exception into a response.
  10.      *
  1.         return $this->finalizeRenderedResponse($request, match (true) {
  2.             $e instanceof HttpResponseException => $e->getResponse(),
  3.             $e instanceof AuthenticationException => $this->unauthenticated($request$e),
  4.             $e instanceof ValidationException => $this->convertValidationExceptionToResponse($e$request),
  5.             default => $this->renderExceptionResponse($request$e),
  6.         }, $e);
  7.     }
  8.     /**
  9.      * Prepare the final, rendered response to be returned to the browser.
  1.      * @param  \Throwable  $e
  2.      * @return void
  3.      */
  4.     protected function renderHttpResponse(Throwable $e)
  5.     {
  6.         $this->getExceptionHandler()->render(static::$app['request'], $e)->send();
  7.     }
  8.     /**
  9.      * Handle the PHP shutdown event.
  10.      *
  1.             if ($exceptionHandlerFailed ?? false) {
  2.                 exit(1);
  3.             }
  4.         } else {
  5.             $this->renderHttpResponse($e);
  6.         }
  7.     }
  8.     /**
  9.      * Render an exception to the console.
  1.      * @return callable
  2.      */
  3.     protected function forwardsTo($method)
  4.     {
  5.         return fn (...$arguments) => static::$app
  6.             $this->{$method}(...$arguments)
  7.             : false;
  8.     }
  9.     /**
  10.      * Determine if the error level is a deprecation.
HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}(object(QueryException))

Stack Traces 2

[2/2] QueryException
Illuminate\Database\QueryException:
SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO) (Connection: mysql, SQL: select * from `settings` where `key` = tahun_ajaran_aktif limit 1)

  at /home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:824
  at Illuminate\Database\Connection->runQueryCallback('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:978)
  at Illuminate\Database\Connection->tryAgainIfCausedByLostConnection(object(QueryException), 'select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:957)
  at Illuminate\Database\Connection->handleQueryException(object(QueryException), 'select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:780)
  at Illuminate\Database\Connection->run('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:397)
  at Illuminate\Database\Connection->select('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), true)
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3188)
  at Illuminate\Database\Query\Builder->runSelect()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3173)
  at Illuminate\Database\Query\Builder->Illuminate\Database\Query\{closure}()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3763)
  at Illuminate\Database\Query\Builder->onceWithColumns(array('*'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3172)
  at Illuminate\Database\Query\Builder->get(array('*'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php:902)
  at Illuminate\Database\Eloquent\Builder->getModels(array('*'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php:884)
  at Illuminate\Database\Eloquent\Builder->get(array('*'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php:366)
  at Illuminate\Database\Eloquent\Builder->first()
     (/home/dataslbm/sip.web.id/app/Models/Setting.php:17)
  at App\Models\Setting::get('tahun_ajaran_aktif', '2025/2026')
     (/home/dataslbm/sip.web.id/app/Providers/AppServiceProvider.php:37)
  at App\Providers\AppServiceProvider->App\Providers\{closure}(object(View))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/Concerns/ManagesEvents.php:162)
  at Illuminate\View\Factory->Illuminate\View\Concerns\{closure}('composing: laravel-exceptions-renderer::markdown', array(object(View)))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php:485)
  at Illuminate\Events\Dispatcher->Illuminate\Events\{closure}('composing: laravel-exceptions-renderer::markdown', array(object(View)))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php:315)
  at Illuminate\Events\Dispatcher->invokeListeners('composing: laravel-exceptions-renderer::markdown', array(object(View)), false)
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php:295)
  at Illuminate\Events\Dispatcher->dispatch('composing: laravel-exceptions-renderer::markdown', array(object(View)))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/Concerns/ManagesEvents.php:178)
  at Illuminate\View\Factory->callComposer(object(View))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/View.php:189)
  at Illuminate\View\View->renderContents()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/View.php:160)
  at Illuminate\View\View->render()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Renderer/Renderer.php:95)
  at Illuminate\Foundation\Exceptions\Renderer\Renderer->render(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:879)
  at Illuminate\Foundation\Exceptions\Handler->renderExceptionContent(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:860)
  at Illuminate\Foundation\Exceptions\Handler->convertExceptionToResponse(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:839)
  at Illuminate\Foundation\Exceptions\Handler->prepareResponse(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:738)
  at Illuminate\Foundation\Exceptions\Handler->renderExceptionResponse(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:626)
  at Illuminate\Foundation\Exceptions\Handler->render(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:221)
  at Illuminate\Foundation\Bootstrap\HandleExceptions->renderHttpResponse(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:198)
  at Illuminate\Foundation\Bootstrap\HandleExceptions->handleException(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:258)
  at Illuminate\Foundation\Bootstrap\HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}(object(QueryException))                
[1/2] PDOException
PDOException:
SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: NO)

  at /home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:66
  at PDO->__construct('mysql:host=127.0.0.1;port=3306;dbname=appsuper', 'root', object(SensitiveParameterValue), array(0, 2, 0, false, false))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:66)
  at Illuminate\Database\Connectors\Connector->createPdoConnection('mysql:host=127.0.0.1;port=3306;dbname=appsuper', 'root', object(SensitiveParameterValue), array(0, 2, 0, false, false))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:85)
  at Illuminate\Database\Connectors\Connector->tryAgainIfCausedByLostConnection(object(PDOException), 'mysql:host=127.0.0.1;port=3306;dbname=appsuper', 'root', object(SensitiveParameterValue), array(0, 2, 0, false, false))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connectors/Connector.php:48)
  at Illuminate\Database\Connectors\Connector->createConnection('mysql:host=127.0.0.1;port=3306;dbname=appsuper', array('driver' => 'mysql', 'host' => '127.0.0.1', 'port' => '3306', 'database' => 'appsuper', 'username' => 'root', 'password' => '', 'unix_socket' => '', 'charset' => 'utf8mb4', 'collation' => 'utf8mb4_unicode_ci', 'prefix' => '', 'prefix_indexes' => true, 'strict' => true, 'engine' => null, 'options' => array(), 'name' => 'mysql'), array(0, 2, 0, false, false))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connectors/MySqlConnector.php:24)
  at Illuminate\Database\Connectors\MySqlConnector->connect(array('driver' => 'mysql', 'host' => '127.0.0.1', 'port' => '3306', 'database' => 'appsuper', 'username' => 'root', 'password' => '', 'unix_socket' => '', 'charset' => 'utf8mb4', 'collation' => 'utf8mb4_unicode_ci', 'prefix' => '', 'prefix_indexes' => true, 'strict' => true, 'engine' => null, 'options' => array(), 'name' => 'mysql'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connectors/ConnectionFactory.php:184)
  at Illuminate\Database\Connectors\ConnectionFactory->Illuminate\Database\Connectors\{closure}()
  at call_user_func(object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:1234)
  at Illuminate\Database\Connection->getPdo()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:1270)
  at Illuminate\Database\Connection->getReadPdo()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:511)
  at Illuminate\Database\Connection->getPdoForSelect(true)
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:406)
  at Illuminate\Database\Connection->Illuminate\Database\{closure}('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:811)
  at Illuminate\Database\Connection->runQueryCallback('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:978)
  at Illuminate\Database\Connection->tryAgainIfCausedByLostConnection(object(QueryException), 'select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:957)
  at Illuminate\Database\Connection->handleQueryException(object(QueryException), 'select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:780)
  at Illuminate\Database\Connection->run('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Connection.php:397)
  at Illuminate\Database\Connection->select('select * from `settings` where `key` = ? limit 1', array('tahun_ajaran_aktif'), true)
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3188)
  at Illuminate\Database\Query\Builder->runSelect()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3173)
  at Illuminate\Database\Query\Builder->Illuminate\Database\Query\{closure}()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3763)
  at Illuminate\Database\Query\Builder->onceWithColumns(array('*'), object(Closure))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Query/Builder.php:3172)
  at Illuminate\Database\Query\Builder->get(array('*'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php:902)
  at Illuminate\Database\Eloquent\Builder->getModels(array('*'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Eloquent/Builder.php:884)
  at Illuminate\Database\Eloquent\Builder->get(array('*'))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Database/Concerns/BuildsQueries.php:366)
  at Illuminate\Database\Eloquent\Builder->first()
     (/home/dataslbm/sip.web.id/app/Models/Setting.php:17)
  at App\Models\Setting::get('tahun_ajaran_aktif', '2025/2026')
     (/home/dataslbm/sip.web.id/app/Providers/AppServiceProvider.php:37)
  at App\Providers\AppServiceProvider->App\Providers\{closure}(object(View))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/Concerns/ManagesEvents.php:162)
  at Illuminate\View\Factory->Illuminate\View\Concerns\{closure}('composing: laravel-exceptions-renderer::markdown', array(object(View)))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php:485)
  at Illuminate\Events\Dispatcher->Illuminate\Events\{closure}('composing: laravel-exceptions-renderer::markdown', array(object(View)))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php:315)
  at Illuminate\Events\Dispatcher->invokeListeners('composing: laravel-exceptions-renderer::markdown', array(object(View)), false)
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Events/Dispatcher.php:295)
  at Illuminate\Events\Dispatcher->dispatch('composing: laravel-exceptions-renderer::markdown', array(object(View)))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/Concerns/ManagesEvents.php:178)
  at Illuminate\View\Factory->callComposer(object(View))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/View.php:189)
  at Illuminate\View\View->renderContents()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/View/View.php:160)
  at Illuminate\View\View->render()
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Renderer/Renderer.php:95)
  at Illuminate\Foundation\Exceptions\Renderer\Renderer->render(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:879)
  at Illuminate\Foundation\Exceptions\Handler->renderExceptionContent(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:860)
  at Illuminate\Foundation\Exceptions\Handler->convertExceptionToResponse(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:839)
  at Illuminate\Foundation\Exceptions\Handler->prepareResponse(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:738)
  at Illuminate\Foundation\Exceptions\Handler->renderExceptionResponse(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Exceptions/Handler.php:626)
  at Illuminate\Foundation\Exceptions\Handler->render(object(Request), object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:221)
  at Illuminate\Foundation\Bootstrap\HandleExceptions->renderHttpResponse(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:198)
  at Illuminate\Foundation\Bootstrap\HandleExceptions->handleException(object(QueryException))
     (/home/dataslbm/sip.web.id/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php:258)
  at Illuminate\Foundation\Bootstrap\HandleExceptions->Illuminate\Foundation\Bootstrap\{closure}(object(QueryException))