fix: move imports to local __init__.py files to make less noise on the routers

This commit is contained in:
AlanSilvaaa
2026-05-26 12:18:52 -04:00
parent c2613cb35e
commit 6329f9c06d
3 changed files with 46 additions and 12 deletions

View File

@@ -0,0 +1,15 @@
from app.problems.grade_1.compose_and_decompose_numbers import (
compose_and_decompose_numbers,
)
from app.problems.grade_1.join_pictures_with_quantity import (
join_pictures_with_quantity,
)
from app.problems.grade_1.sum_with_image_reference import sum_with_image_reference
from app.problems.grade_1.where_are_more_items import where_are_more_items
__all__ = [
"compose_and_decompose_numbers",
"join_pictures_with_quantity",
"sum_with_image_reference",
"where_are_more_items",
]

View File

@@ -1,26 +1,18 @@
from fastapi import APIRouter, HTTPException from fastapi import APIRouter, HTTPException
from app.problems.grade_1.compose_and_decompose_numbers import ( from app.problems.grade_1 import (
compose_and_decompose_numbers, compose_and_decompose_numbers,
)
from app.problems.grade_1.join_pictures_with_quantity import (
join_pictures_with_quantity, join_pictures_with_quantity,
sum_with_image_reference,
where_are_more_items,
) )
from app.problems.grade_1.sum_with_image_reference import sum_with_image_reference from app.schemas.grade_1 import (
from app.problems.grade_1.where_are_more_items import where_are_more_items
from app.schemas.grade_1.compose_and_decompose_numbers import (
ComposeAndDecomposeNumbersProblem, ComposeAndDecomposeNumbersProblem,
ComposeAndDecomposeNumbersRequest, ComposeAndDecomposeNumbersRequest,
)
from app.schemas.grade_1.join_pictures_with_quantity import (
JoinPicturesWithQuantityProblem, JoinPicturesWithQuantityProblem,
JoinPicturesWithQuantityRequest, JoinPicturesWithQuantityRequest,
)
from app.schemas.grade_1.sum_with_image_reference import (
SumWithImageReferenceProblem, SumWithImageReferenceProblem,
SumWithImageReferenceRequest, SumWithImageReferenceRequest,
)
from app.schemas.grade_1.where_are_more_items import (
WhereAreMoreItemsProblem, WhereAreMoreItemsProblem,
WhereAreMoreItemsRequest, WhereAreMoreItemsRequest,
) )

View File

@@ -0,0 +1,27 @@
from app.schemas.grade_1.compose_and_decompose_numbers import (
ComposeAndDecomposeNumbersProblem,
ComposeAndDecomposeNumbersRequest,
)
from app.schemas.grade_1.join_pictures_with_quantity import (
JoinPicturesWithQuantityProblem,
JoinPicturesWithQuantityRequest,
)
from app.schemas.grade_1.sum_with_image_reference import (
SumWithImageReferenceProblem,
SumWithImageReferenceRequest,
)
from app.schemas.grade_1.where_are_more_items import (
WhereAreMoreItemsProblem,
WhereAreMoreItemsRequest,
)
__all__ = [
"ComposeAndDecomposeNumbersProblem",
"ComposeAndDecomposeNumbersRequest",
"JoinPicturesWithQuantityProblem",
"JoinPicturesWithQuantityRequest",
"SumWithImageReferenceProblem",
"SumWithImageReferenceRequest",
"WhereAreMoreItemsProblem",
"WhereAreMoreItemsRequest",
]