laravel-morph-map-generator icon indicating copy to clipboard operation
laravel-morph-map-generator copied to clipboard

Consider using value of "dont-discover" auto-discovery settings from composer.json

Open ChrisHardie opened this issue 11 months ago • 0 comments

I ran in to a weird error on a production deploy today where Laravel's telescope application service provider was attempting to be loaded even though it was only called in my AppServiceProvider in local environments, and was excluded from auto-discovery in composer.json.

I tracked it down to my recent use of this package, which was scanning all of app_path(). The fix was switching to app_path('Models') so not a big deal in my case, but I thought I'd mention it as the use of Telescope may be a common potential gotcha for the default config.

I wonder if there's a way to make use of auto-discovery settings so that this package doesn't try to scan those paths, or if that would even make sense as a distinction to build in.

ChrisHardie avatar Mar 25 '24 13:03 ChrisHardie