Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wrong support of Laravel 6 #105

Open
alvaro-canepa opened this issue Jun 24, 2024 · 4 comments
Open

Wrong support of Laravel 6 #105

alvaro-canepa opened this issue Jun 24, 2024 · 4 comments

Comments

@alvaro-canepa
Copy link

Laravel 6 is suppored in composer.json but in \AndreasElia\PostmanGenerator\Processors\RouteProcessor::processRoute() method use \Illuminate\Support\Str::of() that has been added after Laravel 6 (I think in v7 or v8).

So when I run php artisan export:postman there is no routes in json and have many log errors like "Failed to process route: ...".
If I write dd($e->getMessage()); on catch part, when I run command get's Method Illuminate\Support\Str::of does not exist.

@andreaselia
Copy link
Owner

andreaselia commented Jun 24, 2024

Hmm, good point, apologies for that.

@tomirons thoughts on if there's a backwards compatible way to support L6 here or if we should remove that support and try to document what the last version that worked with L6 was? I assume it was 1.x before our 2.x updates?

@tomirons
Copy link
Collaborator

I suggest removing support for L6.

@alvaro-canepa
Copy link
Author

alvaro-canepa commented Jun 24, 2024

I use this library on a L10 project, it was amazing how easy is to have an entire postman collection. After that I try it on another project, that is biggest, but over L6 :(
The first error I see over L6 (PHP 7.4) is the use of $this->authentication?->toArray() that made an exception, then I see the use of Str::of.

I try another postman generators, but this is the most active and with better configurations.
So, if decide to remove L6 support, is totally understandable.

@tomirons
Copy link
Collaborator

It depends on if there would be a heavy lift in order to support L6 at this point. If not, I would be more than willing to look at a PR that adds support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants