mirror of
https://github.com/lnbits/lnbits-legend.git
synced 2025-02-25 15:10:41 +01:00
* F541 fix remove unused workflow and combine linters into one add lnbits/static to ruff ignore remote setupnode ignore upgrades for mypy ignore F401 for __init__ files unused noqa ignore upgrades for black F821: undefine name disabled and logged webhook_listener for opennode and lnpay because they are obvisouly not working E402: module level import not at top of file fixup revert breaking changes wait for PR #1876 https://github.com/lnbits/lnbits/pull/1876 E721 fixes, only popped up for python3.9 not 3.10 [REFACTOR] core/__init__ to not have circular import issues WIP add db for backwards compat fix pyright make mypy happy again pyright did not catch those, i think mypy got confused with relative imports. maybe we should use absolute ones everywhere E402: module level import not at top of file dont forget to add core_app rebase on ruff pr f remo format * fix clnrest * ignore E402 in conftest * refactoring issues --------- Co-authored-by: jacksn <jkranawetter05@gmail.com>
20 lines
592 B
Python
20 lines
592 B
Python
from fastapi import APIRouter
|
|
|
|
from .db import core_app_extra, db
|
|
from .views.admin_api import admin_router
|
|
from .views.api import api_router
|
|
|
|
# this compat is needed for usermanager extension
|
|
from .views.generic import generic_router, update_user_extension
|
|
from .views.public_api import public_router
|
|
|
|
# backwards compatibility for extensions
|
|
core_app = APIRouter(tags=["Core"])
|
|
|
|
|
|
def init_core_routers(app):
|
|
app.include_router(core_app)
|
|
app.include_router(generic_router)
|
|
app.include_router(public_router)
|
|
app.include_router(api_router)
|
|
app.include_router(admin_router)
|