knuckleswtf / scribe

Generate API documentation for humans from your Laravel codebase.✍
https://scribe.knuckles.wtf/laravel/
MIT License
1.59k stars 281 forks source link

Why composer return error code 2 when trying to generate docs? #704

Closed throcha-aiq closed 10 months ago

throcha-aiq commented 11 months ago

Scribe version

4.0

Your question

The scribe:generate has some errors, but dispite that, the docs are generated just fine, but for composer it returns with a error code 2.

Is there a way to pass that? Because my pipeline won't allow errors.

Generated docs, but encountered some errors while processing routes. ⚠ Check the output above for details. Script php artisan config:clear && touch database/database.sqlite && php artisan --env=docs migrate && php artisan scribe:generate -n --no-upgrade-check --force --env=docs && rm -rf database/database.sqlite handling the docs event returned with error code 2

Docs

throcha-aiq commented 11 months ago

Error example: ✖ Failed processing route: [GET] api/activity/{activity} - Exception encountered. ✖ ErrorException in /home/thiago/projetos/painel-core/vendor/laravel/framework/src/Illuminate/Foundation/Bootstrap/HandleExceptions.php at line 254: Attempt to read property "storesAsMain" on null

throcha-aiq commented 11 months ago

Another observations is that in version 3 it also had a few errors but composer used to return 0