joelbutcher / socialstream

OAuth for Laravel, simplified.
https://docs.socialstream.dev
MIT License
433 stars 66 forks source link

[6.x] - [fix] install command not installing Laravel Jetstream and failing #359

Closed joelbutcher closed 5 months ago

joelbutcher commented 5 months ago

Fixes the following error:

   ErrorException

  copy(/Users/joel/Projects/blog/resources/js/Pages/Profile/Partials/ConnectedAccountsForm.vue): Failed to open stream: No such file or directory

  at /Users/joel/Projects/socialstream/src/Installer/Drivers/Jetstream/InertiaDriver.php:48
     44▕      * Copy the profile views to the app "resources" directory for the given stack.
     45▕      */
     46▕     public function copyProfileViews(InstallOptions ...$options): static
     47▕     {
  ➜  48▕         copy(__DIR__.'/../../../../stubs/jetstream/inertia/resources/js/Pages/Profile/Partials/ConnectedAccountsForm.vue', resource_path('js/Pages/Profile/Partials/ConnectedAccountsForm.vue'));
     49▕         copy(__DIR__.'/../../../../stubs/jetstream/inertia/resources/js/Pages/Profile/Partials/SetPasswordForm.vue', resource_path('js/Pages/Profile/Partials/SetPasswordForm.vue'));
     50▕         copy(__DIR__.'/../../../../stubs/jetstream/inertia/resources/js/Pages/Profile/Show.vue', resource_path('js/Pages/Profile/Show.vue'));
     51▕
     52▕         return $this;

  1   /Users/joel/Projects/socialstream/src/Installer/Drivers/Jetstream/InertiaDriver.php:48

  2   /Users/joel/Projects/socialstream/src/Installer/Drivers/Driver.php:169
      JoelButcher\Socialstream\Installer\Drivers\Jetstream\InertiaDriver::copyProfileViews(Object(JoelButcher\Socialstream\Installer\Enums\InstallOptions), Object(JoelButcher\Socialstream\Installer\Enums\InstallOptions), Object(JoelButcher\Socialstream\Installer\Enums\InstallOptions), Object(JoelButcher\Socialstream\Installer\Enums\InstallOptions), Object(JoelButcher\Socialstream\Installer\Enums\InstallOptions))

This was caused by two things:

  1. A version conflict for paragonie/constant_time_encoding between laravel/socialite(requiring v3.0) and pragmarx/google2fa (requiring v2.7).
    • fixed by overriding the requirement in our own composer.json
  2. The jetstream:install command hanging on the final prompt to run migrations.
    • fixed by adding --no-interaction to the install script for Laravel Jetstream