<commit_before>import os.path as op

from molb.views.accounts import list_account
from molb.views.accounts import delete_account
from molb.views.auth import login
from molb.views.auth import logout
from molb.views.auth.email import confirm as confirm_email
from molb.views.auth.email import handler as email
from molb.views.auth.password import confirm as confirm_password
from molb.views.auth.password import handler as password
from molb.views.auth.profile import delete_profile
from molb.views.auth.profile import edit_profile
from molb.views.auth.register import confirm as confirm_register
from molb.views.auth.register import handler as register
from molb.views.batch import create_batch
from molb.views.batch import edit_batch
from molb.views.batch import delete_batch
from molb.views.batch import list_batch
from molb.views.home import home
from molb.views.order import create_order
from molb.views.order import edit_order
from molb.views.order import delete_order
from molb.views.order import list_order
from molb.views.payment import invoice
from molb.views.payment import list_payment
from molb.views.payment import edit_payment
from molb.views.payment import show_payment
from molb.views.plan import plan
from molb.views.product import create_product
from molb.views.product import edit_product
from molb.views.product import delete_product
from molb.views.product import list_product
from molb.views.repository import create_repository
from molb.views.repository import edit_repository
from molb.views.repository import delete_repository
from molb.views.repository import list_repository
from molb.views.start import start

def setup_routes(app):
    static_dir = op.join(op.dirname(op.abspath(__file__)), "static")
    app.router.add_static("/static", static_dir)

    # starting page
    app.router.add_get("/", start, name="start")

    # accounts
    app.router.add_get("/account/list/", list_account, name="list_account")
    app.router.add_get("/account/delete/{id:\d+}/", delete_account, name="delete_account")

    # auth
    app.router.add_route('*', "/login", login, name="login")
    app.router.add_route('*', "/logout/", logout, name="logout")
    app.router.add_route('*', "/email/", email, name="email")
    app.router.add_get("/email/{token}/", confirm_email, name="confirm_email")
    app.router.add_route('*', "/password/", password, name="password")
    app.router.add_route('*', "/password/{token}/", confirm_password, name="confirm_password")
    app.router.add_route('*', "/profile/delete/", delete_profile, name="delete_profile")
    app.router.add_route('*', "/profile/edit/", edit_profile, name="edit_profile")<commit_msg>add missing trailing '/' at  end of route<commit_after>import os.path as op

from molb.views.accounts import list_account
from molb.views.accounts import delete_account
from molb.views.auth import login
from molb.views.auth import logout
from molb.views.auth.email import confirm as confirm_email
from molb.views.auth.email import handler as email
from molb.views.auth.password import confirm as confirm_password
from molb.views.auth.password import handler as password
from molb.views.auth.profile import delete_profile
from molb.views.auth.profile import edit_profile
from molb.views.auth.register import confirm as confirm_register
from molb.views.auth.register import handler as register
from molb.views.batch import create_batch
from molb.views.batch import edit_batch
from molb.views.batch import delete_batch
from molb.views.batch import list_batch
from molb.views.home import home
from molb.views.order import create_order
from molb.views.order import edit_order
from molb.views.order import delete_order
from molb.views.order import list_order
from molb.views.payment import invoice
from molb.views.payment import list_payment
from molb.views.payment import edit_payment
from molb.views.payment import show_payment
from molb.views.plan import plan
from molb.views.product import create_product
from molb.views.product import edit_product
from molb.views.product import delete_product
from molb.views.product import list_product
from molb.views.repository import create_repository
from molb.views.repository import edit_repository
from molb.views.repository import delete_repository
from molb.views.repository import list_repository
from molb.views.start import start

def setup_routes(app):
    static_dir = op.join(op.dirname(op.abspath(__file__)), "static")
    app.router.add_static("/static", static_dir)

    # starting page
    app.router.add_get("/", start, name="start")

    # accounts
    app.router.add_get("/account/list/", list_account, name="list_account")
    app.router.add_get("/account/delete/{id:\d+}/", delete_account, name="delete_account")

    # auth
    app.router.add_route('*', "/login/", login, name="login")
    app.router.add_route('*', "/logout/", logout, name="logout")
    app.router.add_route('*', "/email/", email, name="email")
    app.router.add_get("/email/{token}/", confirm_email, name="confirm_email")
    app.router.add_route('*', "/password/", password, name="password")
    app.router.add_route('*', "/password/{token}/", confirm_password, name="confirm_password")
    app.router.add_route('*', "/profile/delete/", delete_profile, name="delete_profile")
    app.router.add_route('*', "/profile/edit/", edit_profile, name="edit_profile")
{'fraction_non_alphanumeric': 0.1107162895081354, 'fraction_numerical': 0.0, 'mean_word_length': 5.374255065554231, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7007399', 'n_tokens_mistral': 1585, 'n_tokens_neox': 1578, 'n_words': 419}