onix-systems-php / hyperf-inertia

MIT License
2 stars 0 forks source link

mkdir(): No such file or directory #5

Open harryqt opened 1 month ago

harryqt commented 1 month ago
Select the development stack
  [0] vue
  [1] react
  [2] svelte
 > 2
Do you want to enable server side rendering?
  [0] yes
  [1] no
 > 0
mkdir(): No such file or directory
[ERROR] ErrorException: mkdir(): No such file or directory in /Users/harry/Projects/hyperf-project-inertia/vendor/hyperf/support/src/Filesystem/Filesystem.php:408
Stack trace:
#0 [internal function]: Hyperf\ExceptionHandler\Listener\ErrorExceptionHandler::Hyperf\ExceptionHandler\Listener\{closure}(2, 'mkdir(): No suc...', '/Users/harry/Pr...', 408)
#1 /Users/harry/Projects/hyperf-project-inertia/vendor/hyperf/support/src/Filesystem/Filesystem.php(408): mkdir('/Users/harry/Pr...', 493, false)
#2 /Users/harry/Projects/hyperf-project-inertia/vendor/onix-systems-php/hyperf-inertia/src/Commands/InertiaInitCommand.php(182): Hyperf\Support\Filesystem\Filesystem->makeDirectory('/Users/harry/Pr...')
#3 /Users/harry/Projects/hyperf-project-inertia/vendor/onix-systems-php/hyperf-inertia/src/Commands/InertiaInitCommand.php(168): OnixSystemsPHP\HyperfInertia\Commands\InertiaInitCommand->copyResource('/Users/harry/Pr...', '/Users/harry/Pr...', 'inertia.blade.p...')
#4 /Users/harry/Projects/hyperf-project-inertia/vendor/onix-systems-php/hyperf-inertia/src/Commands/InertiaInitCommand.php(89): OnixSystemsPHP\HyperfInertia\Commands\InertiaInitCommand->copyResources('/Users/harry/Pr...', Array)
#5 /Users/harry/Projects/hyperf-project-inertia/vendor/hyperf/command/src/Command.php(177): OnixSystemsPHP\HyperfInertia\Commands\InertiaInitCommand->handle()
#6 [internal function]: Hyperf\Command\Command->Hyperf\Command\{closure}()
#7 {main}
[DEBUG] Event Hyperf\Command\Event\FailToHandle handled by Hyperf\Command\Listener\FailToHandleListener listener.
[DEBUG] Event Hyperf\Command\Event\AfterExecute handled by App\Listener\ResumeExitCoordinatorListener listener.

I am new to hyperf (coming from laravel). not sure how to debug it.

vmikhav commented 1 month ago

Try to create a storage/inertia folder and rerun the command

harryqt commented 1 month ago

storage/view/layouts directory was not getting created.

harryqt commented 1 month ago

I've been trying to make this working with Hyperf for the past week, still can't make it work.

Can you provide me a Inertia + Svelte + Hyperf skeleton project?

vmikhav commented 1 month ago

What issues did you met except a missing directory?

harryqt commented 1 month ago

A lot. Even after adding missing directories, there were other errors when rendering pages.

Create a project using composer create-project hyperf/hyperf-skeleton and try to setup this package using Svelte, you will find lots of errors.

And one more thing, I think its better to keep Inertia files (css/js/components) on resources directory instead of storage (like Laravel does) as storage are meant for static assets, don't you think?

vmikhav commented 6 days ago

@harryqt we reviewed code, you can try again