import pywikibot | |
from flask import Flask | |
app = Flask(__name__) | |
DEBUG = True | |
@app.route("/") | |
def hello(): | |
return "Hello World!" | |
if __name__ == "__main__": | |
app.run() |
Event Timeline
Comment Actions
Traceback (most recent call last): File "/home/user/python/core/pywikibot/site.py", line 34, in <module> import pywikibot File "/home/user/python/core/pywikibot/__init__.py", line 30, in <module> from pywikibot.logging import ( File "/home/user/python/core/pywikibot/logging.py", line 12, in <module> import logging File "/home/user/python/core/pywikibot/logging.py", line 17, in <module> from logging import DEBUG, INFO, WARNING, ERROR, CRITICAL ImportError: cannot import name DEBUG
Comment Actions
maybe flask is not honouring absolute_imports ?
the fix is to rename logging to _logging
Comment Actions
I found out I had a problem with PyDev libraries configuration in Eclipse.
Now it should be OK.