<p dir="auto">Hi,</p>
<p dir="auto">when I start my <code class="notranslate">Flask</code> app via <code class="notranslate">python3 -m flask run</code> and there is an error in my code, <code class="notranslate">Flask</code> only returns with the following message:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Usage: python -m flask run [OPTIONS]

Error: The file/path provided (server2.run) does not appear to exist.  Please verify the path is correct.  If app is not on PYTHONPATH, ensure the extension is .py"><pre class="notranslate"><code class="notranslate">Usage: python -m flask run [OPTIONS]

Error: The file/path provided (server2.run) does not appear to exist.  Please verify the path is correct.  If app is not on PYTHONPATH, ensure the extension is .py
</code></pre></div>
<p dir="auto">Is there a way to get proper error stack messages or am I not seeing the obvious.. <g-emoji class="g-emoji" alias="thinking" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f914.png">🤔</g-emoji></p>
<p dir="auto">~ For Frodo</p>
<p dir="auto">(Observed on Python 2.7; untested on 3.x)</p>
<h2 dir="auto">Steps to reproduce:</h2>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="echo &quot;import thisisnotarealpackage&quot; &gt; error_app.py
export FLASK_APP=error_app.py
flask run"><pre class="notranslate"><code class="notranslate">echo "import thisisnotarealpackage" &gt; error_app.py
export FLASK_APP=error_app.py
flask run
</code></pre></div>
<h2 dir="auto">Expected result:</h2>
<ul dir="auto">
<li>Some indication that <code class="notranslate">thisisnotarealpackage</code> is not a real package</li>
</ul>
<h2 dir="auto">Observed result:</h2>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Usage: python -m flask run [OPTIONS]

Error: The file/path provided (error) does not appear to exist.
Please verify the path is correct.
If app is not on PYTHONPATH, ensure the extension is .py"><pre class="notranslate"><code class="notranslate">Usage: python -m flask run [OPTIONS]

Error: The file/path provided (error) does not appear to exist.
Please verify the path is correct.
If app is not on PYTHONPATH, ensure the extension is .py
</code></pre></div>
<p dir="auto">(Newlines added)</p>
<h2 dir="auto">Why Bother</h2>
<p dir="auto">This has been causing some confusion on my team because <code class="notranslate">cx_Oracle</code> can fail to import (from the bowels of SQLAlchemy) if it can't find certain Oracle support files on the host machine.</p>