Laravel-excel: [BUG] Laravel\Lumen\Application::booted()

Created on 6 Aug 2020  ·  7Comments  ·  Source: Maatwebsite/Laravel-Excel

Prerequisites

  • [x] Checked if your Laravel Excel version is still supported: https://docs.laravel-excel.com/3.1/getting-started/support.html#supported-versions
  • [x] Able to reproduce the behaviour outside of your code, the problem is isolated to Laravel Excel.
  • [x] Checked that your issue isn't already filed.
  • [x] Checked if no PR was submitted that fixes this problem.
  • [x] Filled in the entire issue template

Versions

  • PHP version: 7.2.25
  • Laravel version: v6.18.33
  • Package version: 3.1.21

Description

After updating from 3.1.20 in lumen, started getting this error (everywhere):

In ExcelServiceProvider.php line 44:

Call to undefined method Laravel\Lumen\Application::booted()

Steps to Reproduce

  • Install the package in a lumen application

Expected behavior:

The code runs

Actual behavior:

I get an 500 error everywhere in the system pointing to the error.

Additional Information

Any additional information, configuration or data that might be necessary to reproduce the issue.

bug

Most helpful comment

When can we get the new release?

All 7 comments

We don't really support Lumen at the moment. Feel free to open a PR that makes it (more) compatible.

We don't really support Lumen at the moment. Feel free to open a PR that makes it (more) compatible.

it worked well till that update, even if not officially supported

I believe there are more things that don't work in Lumen, but as said before a PR for Lumen is welcomed.

i have installed the last release of package
it is 3.1.21
but when i go to code in ExcelServiceProvider, i get these

$this->app->booted(function () {
            $this->app->make(SettingsProvider::class)->provide();
        });

not as it is in the new release:

if ($this->app instanceof \Illuminate\Foundation\Application) {
            // Laravel
            $this->app->booted(function () {
                $this->app->make(SettingsProvider::class)->provide();
            });
        } else {
            // Lumen
            $this->app->make(SettingsProvider::class)->provide();
        }

i made
composer clearcache
composer update
composer install
but not get the right files!!!

Its not tagged yet

When can we get the new release?

It would be very cool getting this release tag.

Was this page helpful?
0 / 5 - 0 ratings