Laravel 5.2工匠错误255例外

时间:2016-07-29 11:38:42

标签: php laravel composer-php

在Windows 10中,我使用Xampp 5.6.23安装了composer和git。

我解雇了这个命令:composer create-project pandaac/pandaac C:\xampp\dev-apolune dev-apolune

我收到此错误:

[29-Jul-2016 11:24:14 UTC] PHP Fatal error:  Uncaught exception
'ErrorException' with message 'Argument 1 passed to 
Illuminate\Foundation\Exceptions\Handler::__construct() must implement
interface Illuminate\Contracts\Container\Container, instance of
Illuminate\Log\Writer given, called in C:\xampp\dev-apolune\vendor\graham-
campbell\exceptions\src\ExceptionHandler.php on line 63 and defined' in 
C:\xampp\dev-    apolune\vendor\laravel\framework\src\Illuminate\Foundation\Exceptions\Handler.ph
p:44
Stack trace:
#0 C:\xampp\dev-apolune\vendor\laravel\framework\src\Illuminate\Foundation\Exceptions\Handler.php(44): Illuminate\Foundation\Bootstrap\HandleExceptions->handleError(4096, 'Argument 1 pass...', 'C:\\xampp\\dev-ap...', 44, Array)
#1 C:\xampp\dev-apolune\vendor\graham-campbell\exceptions\src\ExceptionHandler.php(63): Illuminate\Foundation\Exceptions\Handler->__construct(Object(Illuminate\Log\Writer))
#2 [internal function]: GrahamCampbell\Exceptions\ExceptionHandler->__construct(Object(Illuminate\Foundation\Application))
#3 C:\xampp\dev-apolune\vendor\larave in C:\xampp\dev-apolune\vendor\laravel\framework\src\Illuminate\Foundation\Exceptions\Handler.php on line 44

composer.json包含:

{
    "name": "pandaac/pandaac",
    "description": "An automatic account creator for Open Tibia servers.",
    "keywords": ["pandaac", "apolune", "laravel", "tibia", "opentibia"],
    "license": "MIT",
    "authors": [
        {
            "name": "Christopher Eklund",
            "email": "eklundchristopher@gmail.com",
            "homepage": "https://otland.net/members/chris.13882/",
            "role": "Head Developer"
        },
        {
            "name": "Kristoffer Eklund",
            "email": "kristoffereklund1@gmail.com",
            "homepage": "https://otland.net/members/cornex.10032/",
            "role": "Developer"
        }
    ],
    "type": "project",
    "require": {
        "php": ">=5.5.9",
        "apolune/core": "dev-master",
        "pandaac/theme-tibia": "dev-master"
    },
    "require-dev": {
        "barryvdh/laravel-debugbar": "~2.1",
        "fzaninotto/faker": "~1.4",
        "mockery/mockery": "0.9.*",
        "phpunit/phpunit": "~4.0",
        "phpspec/phpspec": "~2.1",
        "filp/whoops": "~2.0"
    },
    "autoload": {
        "classmap": [
            "database"
        ],
        "psr-4": {
            "App\\": "app/"
        }
    },
    "autoload-dev": {},
    "scripts": {
        "post-root-package-install": [
            "php -r \"copy('.env.example', '.env');\""
        ],
        "post-create-project-cmd": [
            "php artisan key:generate"
        ],
        "post-install-cmd": [
            "Illuminate\\Foundation\\ComposerScripts::postInstall",
            "php artisan optimize",
            "php artisan vendor:publish --tag=public",
            "php artisan vendor:publish --tag=config"
        ],
        "post-update-cmd": [
            "Illuminate\\Foundation\\ComposerScripts::postUpdate",
            "php artisan optimize"
        ]
    },
    "minimum-stability": "dev",
    "config": {
        "preferred-install": "dist"
    }
}

1 个答案:

答案 0 :(得分:2)

这是因为laravel 5.2需要。 PHP版本> = 5.6.4。更新你的php版本。