AIOHTTP: web.run_app(app,port=9090) ^ SyntaxError: invalid syntax

665 Views Asked by At

whenever i try to integrate templates in aiohttp im facing this issue i dont know where exactly the issue is from here is my code

from aiohttp import web
from routes import setup_routes
import aiohttp_jinja2
import jinja2

app = web.Application()
# app.add_routes([web.get('/', hello),
# web.get('verification/',email_verification)
# ])


setup_routes(app)
# aiohttp_jinja2.setup(app,loader=jinja2.FileSystemLoader(('C:\Users\madhumani\workspace\project-master\drfc\mxion\aiohttp\templates'))
aiohttp_jinja2.setup(app,loader=jinja2.FileSystemLoader('templates')

web.run_app(app,port=9090)

if i remove that aiohttp_jinja2.setup line everything works fine
i have followed everything mentioned in the docs for setting up templates but cant figure out the issue

0

There are 0 best solutions below