26
from flask import Flask

app = Flask(__name__)

@app.route("/")
def hello():
    return "Hello, World!"
0

1 Answer 1

99

I have removed the error by just not saving the file as "flask.py"

Sign up to request clarification or add additional context in comments.

1 Comment

Yes the issue is that flask.py naming convention and Import flask command are causing this issue whereas if youu run this code in jupyter notebook without saving the notebook or keeping some other name will work .

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.