Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

First Valet needed Brew, now it has Brew but still returns an error #154

Closed
LourensThalen opened this issue Sep 19, 2016 · 4 comments
Closed

Comments

@LourensThalen
Copy link

LourensThalen commented Sep 19, 2016

Hi there,

Love Valet. Great job.
Had some problems with my $PATH on OSX, so I removed most of it.

Valet stopped working and I can't get it to work again. It throws an error and still says it works, but in the browser it shows a Valet - Not found 404 error.

This is the message I get when using the valet start command:

Warning: array_filter() expects at most 2 parameters, 3 given in /Users/lourens/.composer/vendor/tightenco/collect/src/Illuminate/Support/Arr.php on line 504

Warning: array_filter() expects at most 2 parameters, 3 given in /Users/lourens/.composer/vendor/tightenco/collect/src/Illuminate/Support/Arr.php on line 504

Warning: array_filter() expects at most 2 parameters, 3 given in /Users/lourens/.composer/vendor/tightenco/collect/src/Illuminate/Support/Arr.php on line 504

Warning: array_filter() expects at most 2 parameters, 3 given in /Users/lourens/.composer/vendor/tightenco/collect/src/Illuminate/Support/Arr.php on line 504

Warning: array_filter() expects at most 2 parameters, 3 given in /Users/lourens/.composer/vendor/tightenco/collect/src/Illuminate/Support/Arr.php on line 504

I do have ~/.composer/vendor/bin in my $PATH.

At first Valet stated I needed Brew installed (which I had) but I fixed that. Think Valet was looking for Brew in a different location.

which valet: /usr/local/bin/valet
which composer: /usr/local/bin/composer

No log files were found (valet logs), it has the latest version.

I can't view any of the websites through Valet and this is really frustrating. I hope you can show me the way.

Cheers

@adamwathan
Copy link
Contributor

It sounds like you have an old version of PHP installed. Try updating to PHP 5.6 or 7.0, that will fix that array_filter error.

@morloderex
Copy link

@adamwathan Or an old version of PHP in the path atleast.

@LourensThalen
Copy link
Author

Thanks for the input, I'm indeed running php 5.5 even though I have 7 installed.
This is my PHP version and where it's located:

Mac:~ lourens$ php -v
PHP 5.5.34 (cli) (built: Apr 22 2016 19:16:58) 
Copyright (c) 1997-2015 The PHP Group
Zend Engine v2.5.0, Copyright (c) 1998-2015 Zend Technologies
Mac:~ lourens$ which php
/usr/bin/php

But this is my $PATH:
export PATH="/usr/local:/bin:/usr/sbin/:/sbin:/usr/local/share/npm/bin:/usr/local:~/.composer/vendor/bin:$PATH"

I don't know why it would use the old PHP version? what should I change my $PATH to?

@adamwathan
Copy link
Contributor

You'll want /usr/local/bin somewhere near the front of your path, that's where Homebrew symlinks everything 👍🏻

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants