mirror of
https://github.com/pezkuwichain/pezkuwi-mobile-app.git
synced 2026-06-12 22:51:01 +00:00
auto-commit for a3e83bcc-c363-4edf-8cd4-5be996b104ab
This commit is contained in:
+7
-7
@@ -15,6 +15,13 @@ from substrateinterface import SubstrateInterface
|
||||
ROOT_DIR = Path(__file__).parent
|
||||
load_dotenv(ROOT_DIR / '.env')
|
||||
|
||||
# Configure logging FIRST
|
||||
logging.basicConfig(
|
||||
level=logging.INFO,
|
||||
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s'
|
||||
)
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
# MongoDB connection
|
||||
mongo_url = os.environ['MONGO_URL']
|
||||
client = AsyncIOMotorClient(mongo_url)
|
||||
@@ -37,13 +44,6 @@ def get_substrate():
|
||||
substrate = None
|
||||
return substrate
|
||||
|
||||
# Configure logging
|
||||
logging.basicConfig(
|
||||
level=logging.INFO,
|
||||
format='%(asctime)s - %(name)s - %(levelname)s - %(message)s'
|
||||
)
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
# Create the main app without a prefix
|
||||
app = FastAPI()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user