1

When running composer install to get elastic search I get the below error:

  Problem 1
    - Installation request for tamayo/laravel-scout-elastic 1.0.1 -> satisfiable by tamayo/laravel-scout-elastic[1.0.1].
    - tamayo/laravel-scout-elastic 1.0.1 requires elasticsearch/elasticsearch ^2.2 -> no matching package found.

Potential causes:
 - A typo in the package name
 - The package is not available in a stable-enough version according to your minimum-stability setting
   see <https://getcomposer.org/doc/04-schema.md#minimum-stability> for more details.

I have this in the require section of my composer file:

  "laravel/scout": "^1.1",
  "elasticsearch/elasticsearch": "^2.2",
  "tamayo/laravel-scout-elastic": "^1.0",

How do I get these packages to install together?

1 Answer 1

1

Try to clean Composer's cache.

Your deps (at least 3 that are posted) work fine, just installed them on my machine.

$ composer show
doctrine/inflector           v1.1.0  Common String Manipulations with regard to casing and singular/plural rules.
elasticsearch/elasticsearch  v2.3.0  PHP Client for Elasticsearch
guzzlehttp/ringphp           1.1.0   Provides a simple API and specification that abstracts away the details of HTTP into a single PHP function.
guzzlehttp/streams           3.0.0   Provides a simple abstraction over streams of data
illuminate/bus               v5.3.23 The Illuminate Bus package.
illuminate/console           v5.3.23 The Illuminate Console package.
illuminate/container         v5.3.23 The Illuminate Container package.
illuminate/contracts         v5.3.23 The Illuminate Contracts package.
illuminate/database          v5.3.23 The Illuminate Database package.
illuminate/pagination        v5.3.23 The Illuminate Pagination package.
illuminate/pipeline          v5.3.23 The Illuminate Pipeline package.
illuminate/queue             v5.3.23 The Illuminate Queue package.
illuminate/support           v5.3.23 The Illuminate Support package.
laravel/scout                v1.1.12 Laravel Scout provides a driver based solution to searching your Eloquent models.
nesbot/carbon                1.21.0  A simple API extension for DateTime.
paragonie/random_compat      v2.0.4  PHP 5.x polyfill for random_bytes() and random_int() from PHP 7
psr/log                      1.0.2   Common interface for logging libraries
react/promise                v2.4.1  A lightweight implementation of CommonJS Promises/A for PHP
symfony/console              v3.1.8  Symfony Console Component
symfony/debug                v3.1.8  Symfony Debug Component
symfony/polyfill-mbstring    v1.3.0  Symfony polyfill for the Mbstring extension
symfony/process              v3.1.8  Symfony Process Component
symfony/translation          v3.2.1  Symfony Translation Component
tamayo/laravel-scout-elastic 1.0.1   Elastic Driver for Laravel Scout

And my composer.json

{
  "require": {
    "laravel/scout": "^1.1",
    "elasticsearch/elasticsearch": "^2.2",
    "tamayo/laravel-scout-elastic": "^1.0"
  }
}
Sign up to request clarification or add additional context in comments.

9 Comments

So I tried that and it still is not working. They install fine when I run composer require one by one. The problem is on new deployments when composer install is run
As I said in the answer, I cannot reproduce the problem. Let's define steps to reproduce it first. My deployment is new, and I hit composer install too.
So starting from scratch with no vendor folder. With those three things in composer.json running composer install is what gives me the error. It fails on my local machine and on semaphore.
No errors for me. composer.json from the answer. Composer installed packages.
so I ran composer clearcache, anything else I need to do to clear it
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.