Python2.7(flask) Reference To Import Variable From ___init___.py Inside Module
I need to import a variable that is initialized in the __init__.py of my package. ======__init__.py====== import os from flask import Flask from flask_sqlalchemy import SQLAlchemy
Solution 1:
My answer comes from another stackoverflow answer: Python circular importing?
Essentially use import db
rather than from thermos import db
Post a Comment for "Python2.7(flask) Reference To Import Variable From ___init___.py Inside Module"