第145行的流明错误照亮/支持/ Arr.php

In my local development environment its works fine, but when i deploy the lumen(5.2) project in server and when it's try to execute this line app('db')->select($sql, array($email)); then it's throw this exception

protected 'message' => string 'array_key_exists(): The first argument  should be either a string or an integer' (length=78)
private 'string' (Exception) => string '' (length=0)
protected 'code' => int 0
protected 'file' => string 
'/usr/src/app/api/vendor/illuminate/support/Arr.php' (length=50)
protected 'line' => int 145
private 'trace' (Exception) => 
array (size=32)
  0 => 
    array (size=4)
      'function' => string 'Laravel\Lumen\Concerns\{closure}' (length=32)
      'class' => string 'Laravel\Lumen\Application' (length=25)
      'type' => string '->' (length=2)
      'args' => 
        array (size=5)
          ...
  1 => 
    array (size=4)
      'file' => string '/usr/src/app/api/vendor/illuminate/support/Arr.php' (length=50)
      'line' => int 145
      'function' => string 'array_key_exists' (length=16)
      'args' => 
        array (size=2)
          ...
  2 => 
    array (size=6)
      'file' => string '/usr/src/app/api/vendor/illuminate/support/Arr.php' (length=50)
      'line' => int 280
      'function' => string 'exists' (length=6)
      'class' => string 'Illuminate\Support\Arr' (length=22)
      'type' => string '::' (length=2)
      'args' => 
        array (size=2)
          ...
  3 => 
    array (size=6)
      'file' => string '/usr/src/app/api/vendor/illuminate/database/DatabaseManager.php' (length=63)
      'line' => int 238
      'function' => string 'get' (length=3)
      'class' => string 'Illuminate\Support\Arr' (length=22)
      'type' => string '::' (length=2)
      'args' => 
        array (size=2)
          ...
  4 => 
    array (size=6)
      'file' => string '/usr/src/app/api/vendor/illuminate/database/DatabaseManager.php' (length=63)
      'line' => int 158
      'function' => string 'getConfig' (length=9)
      'class' => string 'Illuminate\Database\DatabaseManager' (length=35)
      'type' => string '->' (length=2)
      'args' => 
        array (size=1)
          ...
  5 => 
    array (size=6)
      'file' => string '/usr/src/app/api/vendor/illuminate/database/DatabaseManager.php' (length=63)
      'line' => int 68
      'function' => string 'makeConnection' (length=14)
      'class' => string 'Illuminate\Database\DatabaseManager' (length=35)
      'type' => string '->' (length=2)
      'args' => 
        array (size=1)
          ...
  6 => 
    array (size=6)
      'file' => string '/usr/src/app/api/vendor/illuminate/database/DatabaseManager.php' (length=63)
      'line' => int 317
      'function' => string 'connection' (length=10)
      'class' => string 'Illuminate\Database\DatabaseManager' (length=35)
      'type' => string '->' (length=2)
      'args' => 
        array (size=0)
          ...

I think its happen for set up environment in server , Please suggest me what i have to do..

Did you enable error logging on your development machine?

Share your code which one is you're using with array_key_exists function.

Also share your current php version of development & server machine.

I had the same problem right now. I've received an error max_memory_limit, but because of nothing. In that case WAMP/LAMP/XAMP restart should help. Mye be helpful for somebody... :)