amranidev / laracombee

:bar_chart: A Recombee integration for Laravel
MIT License
114 stars 7 forks source link

Class 'Amranidev\Laracombee\facades\LaracombeeFacade' not found #47

Closed maidul98 closed 5 years ago

maidul98 commented 5 years ago

I have my Laravel on Heroku and when I push it out to Heroku it gives me this. However, it works fine on localhost. Any ideas?

In AliasLoader.php line 80:

  Class 'Amranidev\Laracombee\facades\LaracombeeFacade' not found 
amranidev commented 5 years ago

Can you provide more details?

maidul98 commented 5 years ago

Can you provide more details?

In the terminal I run the following command to push updates to Heroku:

PS C:\Users\coolm\Desktop\want_api> git push heroku master
Enumerating objects: 18, done.
Counting objects: 100% (18/18), done.
Delta compression using up to 4 threads
Compressing objects: 100% (10/10), done.
Writing objects: 100% (10/10), 1.65 KiB | 337.00 KiB/s, done.
Total 10 (delta 7), reused 0 (delta 0)
remote: Compressing source files... done.
remote: Building source:
remote:
remote: -----> PHP app detected
remote: -----> Bootstrapping...
remote: -----> Installing platform packages...
remote:        - php (7.3.6)
remote:        - ext-gd (bundled with php)
remote:        - ext-mbstring (bundled with php)
remote:        - apache (2.4.39)
remote:        - nginx (1.16.0)
remote: -----> Installing dependencies...
remote:        Composer version 1.8.5 2019-04-09 17:46:47
remote:        Loading composer repositories with package information
remote:        Installing dependencies from lock file
remote:        Package operations: 87 installs, 0 updates, 0 removals
remote:          - Installing psr/simple-cache (1.0.1): Loading from cache
remote:          - Installing psr/log (1.1.0): Loading from cache
remote:          - Installing psr/http-message (1.0.1): Loading from cache
remote:          - Installing algolia/algoliasearch-client-php (2.2.0): Loading from cache
remote:          - Installing rmccue/requests (v1.7.0): Loading from cache
remote:          - Installing recombee/php-api-client (v2.4.0): Loading from cache
remote:          - Installing guzzlehttp/promises (v1.3.1): Loading from cache
remote:          - Installing amranidev/laracombee (v0.1.37): Loading from cache
remote:          - Installing symfony/polyfill-ctype (v1.11.0): Loading from cache
remote:          - Installing vlucas/phpdotenv (v2.6.1): Loading from cache
remote:          - Installing symfony/css-selector (v4.3.0): Loading from cache
remote:          - Installing tijsverkoyen/css-to-inline-styles (2.2.1): Loading from cache
remote:          - Installing symfony/polyfill-php72 (v1.11.0): Loading from cache
remote:          - Installing symfony/polyfill-mbstring (v1.11.0): Loading from cache
remote:          - Installing symfony/var-dumper (v4.3.0): Loading from cache
remote:          - Installing symfony/routing (v4.3.0): Loading from cache
remote:          - Installing symfony/process (v4.3.0): Loading from cache
remote:          - Installing symfony/polyfill-php73 (v1.11.0): Loading from cache
remote:          - Installing symfony/polyfill-intl-idn (v1.11.0): Loading from cache
remote:          - Installing symfony/mime (v4.3.0): Loading from cache
remote:          - Installing symfony/http-foundation (v4.3.0): Loading from cache
remote:          - Installing symfony/event-dispatcher-contracts (v1.1.1): Loading from cache
remote:          - Installing symfony/event-dispatcher (v4.3.0): Loading from cache
remote:          - Installing symfony/debug (v4.3.0): Loading from cache
remote:          - Installing symfony/http-kernel (v4.3.0): Loading from cache
remote:          - Installing symfony/finder (v4.3.0): Loading from cache
remote:          - Installing symfony/service-contracts (v1.1.2): Loading from cache
remote:          - Installing symfony/console (v4.3.0): Loading from cache
remote:          - Installing symfony/polyfill-iconv (v1.11.0): Loading from cache
remote:          - Installing doctrine/lexer (v1.0.1): Loading from cache
remote:          - Installing egulias/email-validator (2.1.8): Loading from cache
remote:          - Installing swiftmailer/swiftmailer (v6.2.1): Loading from cache
remote:          - Installing paragonie/random_compat (v9.99.99): Loading from cache
remote:          - Installing ramsey/uuid (3.8.0): Loading from cache
remote:          - Installing psr/container (1.0.0): Loading from cache
remote:          - Installing opis/closure (3.3.0): Loading from cache
remote:          - Installing symfony/translation-contracts (v1.1.2): Loading from cache
remote:          - Installing symfony/translation (v4.3.0): Loading from cache
remote:          - Installing nesbot/carbon (1.32.0): Loading from cache
remote:          - Installing monolog/monolog (1.24.0): Loading from cache
remote:          - Installing league/flysystem (1.0.52): Loading from cache
remote:          - Installing ralouphie/getallheaders (2.0.5): Loading from cache
remote:          - Installing guzzlehttp/psr7 (1.5.2): Loading from cache
remote:          - Installing guzzlehttp/guzzle (6.3.3): Loading from cache
remote:          - Installing laravel/slack-notification-channel (v1.0.3): Loading from cache
remote:          - Installing psr/http-factory (1.0.1): Loading from cache
remote:          - Installing zendframework/zend-diactoros (2.1.2): Loading from cache
remote:          - Installing php-http/promise (v1.0.0): Loading from cache
remote:          - Installing php-http/httplug (v1.1.0): Loading from cache
remote:          - Installing php-http/guzzle6-adapter (v1.1.1): Loading from cache
remote:          - Installing lcobucci/jwt (3.3.1): Loading from cache
remote:          - Installing nexmo/client (1.8.1): Loading from cache
remote:          - Installing laravel/nexmo-notification-channel (v1.0.1): Loading from cache
remote:          - Installing erusev/parsedown (1.7.3): Loading from cache
remote:          - Installing dragonmantank/cron-expression (v2.3.0): Loading from cache
remote:          - Installing doctrine/inflector (v1.3.0): Loading from cache
remote:          - Installing laravel/framework (v5.7.28): Loading from cache
remote:          - Installing awobaz/compoships (1.1.13): Loading from cache
remote:          - Installing asm89/stack-cors (1.2.0): Loading from cache
remote:          - Installing barryvdh/laravel-cors (v0.11.3): Loading from cache
remote:          - Installing fideloper/proxy (4.1.0): Loading from cache
remote:          - Installing intervention/image (dev-master a8fca2a): Loading from cache
remote:          - Installing jakub-onderka/php-console-color (v0.2): Loading from cache
remote:          - Installing symfony/psr-http-message-bridge (v1.2.0): Loading from cache
remote:          - Installing phpseclib/phpseclib (2.0.17): Loading from cache
remote:          - Installing league/event (2.2.0): Loading from cache
remote:          - Installing defuse/php-encryption (v2.2.1): Loading from cache
remote:          - Installing league/oauth2-server (7.4.0): Loading from cache
remote:          - Installing firebase/php-jwt (v5.0.0): Loading from cache
remote:          - Installing laravel/passport (v7.3.0): Loading from cache
remote:          - Installing laravel/scout (v7.1.2): Loading from cache
remote:          - Installing league/oauth1-client (1.7.0): Loading from cache
remote:          - Installing laravel/socialite (v4.1.3): Loading from cache
remote:          - Installing nikic/php-parser (v4.2.2): Loading from cache
remote:          - Installing jakub-onderka/php-console-highlighter (v0.4): Loading from cache
remote:          - Installing dnoegel/php-xdg-base-dir (0.1): Loading from cache
remote:          - Installing psy/psysh (v0.9.9): Loading from cache
remote:          - Installing laravel/tinker (v1.0.8): Loading from cache
remote:          - Installing mtdowling/jmespath.php (2.4.0): Loading from cache
remote:          - Installing aws/aws-sdk-php (3.99.2): Loading from cache
remote:          - Installing league/flysystem-aws-s3-v3 (1.0.23): Loading from cache
remote:          - Installing liliom/laravel-firebase (v1.0.1): Loading from cache
remote:          - Installing paralleldots/apis (dev-master 6c66ca4): Loading from cache
remote:          - Installing paragonie/sodium_compat (v1.10.0): Loading from cache
remote:          - Installing pusher/pusher-php-server (v3.4.1): Loading from cache
remote:          - Installing staudenmeir/eloquent-eager-limit (v1.0): Loading from cache
remote:          - Installing stripe/stripe-php (v6.37.0): Loading from cache
remote:        Generating optimized autoload files
remote:        > Illuminate\Foundation\ComposerScripts::postAutoloadDump
remote:        > @php artisan package:discover
remote:        Discovered Package: amranidev/laracombee
remote:        Discovered Package: awobaz/compoships
remote:        Discovered Package: barryvdh/laravel-cors
remote:        Discovered Package: fideloper/proxy
remote:        Discovered Package: intervention/image
remote:        Discovered Package: laravel/nexmo-notification-channel
remote:        Discovered Package: laravel/passport
remote:        Discovered Package: laravel/scout
remote:        Discovered Package: laravel/slack-notification-channel
remote:        Discovered Package: laravel/socialite
remote:        Discovered Package: laravel/tinker
remote:        Discovered Package: liliom/laravel-firebase
remote:        Discovered Package: nesbot/carbon
remote:        Package manifest generated successfully.
remote:        > php artisan clear-compiled
remote:        Compiled services and packages files removed!
remote:        > chmod -R 777 storage
remote:        > php artisan passport:keys
remote:        Encryption keys generated successfully.
remote: -----> Preparing runtime environment...
remote: -----> Checking for additional extensions to install...
remote: -----> Discovering process types
remote:        Procfile declares types -> web
remote:
remote: -----> Compressing...
remote:        Done: 22.3M
remote: -----> Launching...
remote:        Released v278
remote:        https://dry-mesa-87903.herokuapp.com/ deployed to Heroku
remote:
remote: Verifying deploy... done.
To https://git.heroku.com/XX-XX-87903.git
   785cf4b..0544ee2  master -> master

Then I run this to migrate the users: heroku run php artisan laracombee:migrate user

Once I run this, I get this error:

In AliasLoader.php line 80:

  [ErrorException]                                                 
  Class 'Amranidev\Laracombee\facades\LaracombeeFacade' not found  

Exception trace:
 () at /app/vendor/laravel/framework/src/Illuminate/Foundation/AliasLoader.php:80
 Illuminate\Foundation\Bootstrap\HandleExceptions->handleError() at n/a:n/a
 class_alias() at /app/vendor/laravel/framework/src/Illuminate/Foundation/AliasLoader.php:80
 Illuminate\Foundation\AliasLoader->load() at n/a:n/a
 spl_autoload_call() at /app/vendor/amranidev/laracombee/src/Console/LaracombeeCommand.php:32
 Amranidev\Laracombee\Console\LaracombeeCommand->addUserProperty() at /app/vendor/amranidev/laracombee/src/Console/Commands/MigrateCommand.php:66
 Amranidev\Laracombee\Console\Commands\MigrateCommand->Amranidev\Laracombee\Console\Commands\{closure}() at n/a:n/a
 array_map() at /app/vendor/laravel/framework/src/Illuminate/Support/Collection.php:1034
 Illuminate\Support\Collection->map() at /app/vendor/amranidev/laracombee/src/Console/Commands/MigrateCommand.php:67
 Amranidev\Laracombee\Console\Commands\MigrateCommand->prepareScope() at /app/vendor/amranidev/laracombee/src/Console/Commands/MigrateCommand.php:42
 Amranidev\Laracombee\Console\Commands\MigrateCommand->handle() at n/a:n/a
 call_user_func_array() at /app/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:29
 Illuminate\Container\BoundMethod::Illuminate\Container\{closure}() at /app/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:87
 Illuminate\Container\BoundMethod::callBoundMethod() at /app/vendor/laravel/framework/src/Illuminate/Container/BoundMethod.php:31
 Illuminate\Container\BoundMethod::call() at /app/vendor/laravel/framework/src/Illuminate/Container/Container.php:572
 Illuminate\Container\Container->call() at /app/vendor/laravel/framework/src/Illuminate/Console/Command.php:183
 Illuminate\Console\Command->execute() at /app/vendor/symfony/console/Command/Command.php:255
 Symfony\Component\Console\Command\Command->run() at /app/vendor/laravel/framework/src/Illuminate/Console/Command.php:170
 Illuminate\Console\Command->run() at /app/vendor/symfony/console/Application.php:921
 Symfony\Component\Console\Application->doRunCommand() at /app/vendor/symfony/console/Application.php:273
 Symfony\Component\Console\Application->doRun() at /app/vendor/symfony/console/Application.php:149
 Symfony\Component\Console\Application->run() at /app/vendor/laravel/framework/src/Illuminate/Console/Application.php:89
 Illuminate\Console\Application->run() at /app/vendor/laravel/framework/src/Illuminate/Foundation/Console/Kernel.php:122
 Illuminate\Foundation\Console\Kernel->handle() at /app/artisan:37

Note: Everything has been installed on the servicer and everything works locally, just not online.

I did some digging and this might be caused by case sensitiveness since Heroku runs on Linux which is case sensitive while windows is not case sensitive. In this case, I'm not sure which file this issue lies in.

amranidev commented 5 years ago

48