title: Pytesseract on AWS Lambda: tesseract is not installed or it's not in your PATH
body: <p>Lambda AWS: python 3.8</p>
  <p>ARN tested:</p>
  <ul>
  <li>arn:aws:lambda:eu-west-3:770693421928:layer:Klayers-python38-pytesseract:15</li>
  <li>arn:aws:lambda:eu-west-3:770693421928:layer:Klayers-python38-pytesseract:16</li>
  <li>arn:aws:lambda:eu-west-3:770693421928:layer:Klayers-python38-pytesseract:17</li>
  </ul>
  <p>Lambda AWS: python 3.7</p>
  <p>ARN tested:</p>
  <ul>
  <li>arn:aws:lambda:eu-west-3:113088814899:layer:Klayers-python37-pytesseract:13</li>
  </ul>
  <p><code>lambda_function.py</code>:</p>
  <pre><code>import json
  import pytesseract
  from PIL import Image
  
  
  def lambda_handler(event, context):
      try:
          body = {
              &quot;text&quot;: pytesseract.image_to_string(Image.open('random_text.png')),
          }
      except Exception as e:
          body = str(e)
  
      response = {
          &quot;statusCode&quot;: 200,
          &quot;body&quot;: json.dumps(body)
      }
  
  
      return response
  </code></pre>
  <p>No error when I import everything, the error come when I try to do an action with <code>pytesseract.image_to_string()</code></p>
  <p>Because import in python 3.7/3.8 with corresponding ARN work, I suppose that the error is really particular and concern <code>pytesseract</code>.
  But why isn't it handle by the ARN ?
  I saw other post talking about tutorials but I'm always stuck on this precise error: <code>tesseract is not installed or it's not in your PATH</code></p>