From 44315643040c517f1ef7307857768917bb36b5ad Mon Sep 17 00:00:00 2001 From: viveksantayana Date: Sun, 12 Jun 2022 20:50:57 +0100 Subject: [PATCH] Created config module to avoid circular import --- ref-test/app/data.py | 2 +- ref-test/config.py | 1 + ref-test/main.py | 2 +- 3 files changed, 3 insertions(+), 2 deletions(-) create mode 100644 ref-test/config.py diff --git a/ref-test/app/data.py b/ref-test/app/data.py index ba972f9..0fb38c4 100644 --- a/ref-test/app/data.py +++ b/ref-test/app/data.py @@ -1,4 +1,4 @@ -from main import Config +from config import Config from os import path from pathlib import Path diff --git a/ref-test/config.py b/ref-test/config.py new file mode 100644 index 0000000..38a499a --- /dev/null +++ b/ref-test/config.py @@ -0,0 +1 @@ +from app.config import DevelopmentConfig as Config \ No newline at end of file diff --git a/ref-test/main.py b/ref-test/main.py index 0f84d66..29d0d00 100644 --- a/ref-test/main.py +++ b/ref-test/main.py @@ -1,5 +1,5 @@ from app.modules import bootstrap, csrf, db, login_manager, mail -from app.config import DevelopmentConfig as Config +from config import Config from flask import Flask from flask_wtf.csrf import CSRFError