thedevdojo / voyager

Voyager - The Missing Laravel Admin
https://voyager.devdojo.com
MIT License
11.8k stars 2.67k forks source link

Can't install any hooks, even test-hook #5138

Closed BaktiQilan closed 3 years ago

BaktiQilan commented 4 years ago

Version information

Description

im cant install any hooks, even test-hook. i want to install voyager-excel, but always error. then i try to install test-hook, but the same error showing.

Steps To Reproduce

Steps to reproduce the behavior:

  1. make a new project laravel
  2. install voyager
  3. then try to install any hooks. like 'php artisan hook:install test-hook'
  4. See error

PS C:\Users\Bakti Qilan\Documents\Magang\laravel-voyager> php artisan hook:install test-hook

RuntimeException

require.test-hook is invalid, it should have a vendor name, a forward slash, and a package name. The vendor and package name can be words separated by -, . or . The complete name should match "^[a-z0-9]([.-]?[a-z0-9]+)/a-z0-9$".

at C:\Users\Bakti Qilan\Documents\Magang\laravel-voyager\vendor\composer\composer\src\Composer\Package\Loader\RootPackageLoader.php:149 145▕ foreach (array_keys(BasePackage::$supportedLinkTypes) as $linkType) { 146▕ if (isset($config[$linkType])) { 147▕ foreach ($config[$linkType] as $linkName => $constraint) { 148▕ if ($err = ValidatingArrayLoader::hasPackageNamingError($linkName, true)) { ➜ 149▕ throw new \RuntimeException($linkType.'.'.$err); 150▕ } 151▕ } 152▕ } 153▕ }

1 C:\Users\Bakti Qilan\Documents\Magang\laravel-voyager\vendor\composer\composer\src\Composer\Factory.php:363 Composer\Package\Loader\RootPackageLoader::load("Composer\Package\RootPackage", "C:\Users\Bakti Qilan\Documents\Magang\laravel-voyager")

2 C:\Users\Bakti Qilan\Documents\Magang\laravel-voyager\vendor\composer\composer\src\Composer\Factory.php:590 Composer\Factory::createComposer(Object(Composer\IO\ConsoleIO))

Screenshots

image

saefr commented 4 years ago

Hi, i have exactly the same problem on a Debian fresh install of Voyager. I used the same process than 3 months ago in a previous installation, and everything worked fine. On this new install, i have the "require.test-hook is invalid" for every hook i try to add.

Laravel v7.29.3 / Voyager v1.4.2

emptynick commented 4 years ago

Are you guys both using composer 2?

saefr commented 4 years ago

I use Composer version 1.8.4 on all my Voyager installation, never had the problem before.

BaktiQilan commented 4 years ago

Are you guys both using composer 2?

i am using composer 1.10.13, should i update the composer ?

mrpk-dev commented 3 years ago

I am removed composer exception ! work for me this fork composer require mrpk-dev/voyager:v1.4.7

xabacase commented 3 years ago

This fork only comment the function which fire the error, its not working on the root cause of the problem.

if ($err = ValidatingArrayLoader::hasPackageNamingError($linkName, true)) { throw new \RuntimeException($linkType.'.'.$err); /* throw new \RuntimeException($linkType.'.'.$err); */ }

sanchezpablo commented 3 years ago

I am using composer 2.0.4 and obtaining the same error for any hook... any ideas?

kvedak commented 3 years ago

Same problem composer 2.0.8 laravel hooks 1.0.12 Laravel Voyager hooks 1.2.3 Laravel installer 4.1.1

MrCrayon commented 3 years ago

The install command is not part of Voyager repo, it should be reported in https://github.com/larapack/hooks

Diego-dev-star commented 3 years ago

have same problem wtf voyager i loving u ?! ))

github-actions[bot] commented 2 years ago

This issue has been automatically locked since there has not been any recent activity after it was closed. If you have further questions please ask in our Slack group.