dingo / dingo/api

Router not loading on Travis CI

Open
#1,529 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
9.4k
Forks
1.3k
PR merge metrics
No merged PRs in 30d

Description

| Q | A
| ----------------- | ---
| Bug? |yes
| New Feature? | no
| Framework | Laravel
| Framework version | 5.4
| Package version | 1.0.0-beta8
| PHP version |5.6.32

#### Actual Behaviour
Ps: I'm using `Laravel 5.4` and `"dingo/api": "1.0.0-beta8",`
On Travis the router is not registered in the service container.

Describe the behaviour you're experiencing. Do not just copy and paste a random error message and expect help.

```
PHP Fatal error: Uncaught exception 'Illuminate\Contracts\Container\BindingResolutionException' with message 'Target [Dingo\Api\Contract\Routing\Adapter] is not instantiable while building [Dingo\Api\Routing\Router].' in /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php:895
Stack trace:
#0 /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php(735): Illuminate\Container\Container->notInstantiable('Dingo\\Api\\Contr...')
#1 /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php(608): Illuminate\Container\Container->build('Dingo\\Api\\Contr...')
#2 /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php(575): Illuminate\Container\Container->resolve('Dingo\\Api\\Contr...')
#3 /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container in /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 895
Fatal error: Uncaught exception 'Illuminate\Contracts\Container\BindingResolutionException' with message 'Target [Dingo\Api\Contract\Routing\Adapter] is not instantiable while building [Dingo\Api\Routing\Router].' in /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 895
Illuminate\Contracts\Container\BindingResolutionException: Target [Dingo\Api\Contract\Routing\Adapter] is not instantiable while building [Dingo\Api\Routing\Router]. in /home/travis/build/andela-tolotin/inventory-manager/vendor/laravel/framework/src/Illuminate/Container/Container.php on line 895

```

#### Expected Behaviour

Describe the behaviour you're expecting.
The router should work in the test environment like the way it's working on the local and prod environments.
#### Steps to Reproduce

List all the steps needed to reproduce the issue you're having. Make sure to include code (affected models, configurations),
any screenshots and/or other resources that may help us understand what's going on.

#### Possible Solutions

If you have any ideas on how to solve the issue, add them here, otherwise you can omit this part.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.