refactor: make compatibility exports ruff clean
This commit is contained in:
@@ -1,11 +1,21 @@
|
||||
from . import (
|
||||
accounts_gateway,
|
||||
assets_gateway,
|
||||
categorization_gateway,
|
||||
imports_gateway,
|
||||
overview_gateway,
|
||||
reconciliation_gateway,
|
||||
service_gateway,
|
||||
transactions_gateway,
|
||||
transfers_gateway,
|
||||
)
|
||||
from . import accounts_gateway as accounts_gateway
|
||||
from . import assets_gateway as assets_gateway
|
||||
from . import categorization_gateway as categorization_gateway
|
||||
from . import imports_gateway as imports_gateway
|
||||
from . import overview_gateway as overview_gateway
|
||||
from . import reconciliation_gateway as reconciliation_gateway
|
||||
from . import service_gateway as service_gateway
|
||||
from . import transactions_gateway as transactions_gateway
|
||||
from . import transfers_gateway as transfers_gateway
|
||||
|
||||
__all__ = [
|
||||
"accounts_gateway",
|
||||
"assets_gateway",
|
||||
"categorization_gateway",
|
||||
"imports_gateway",
|
||||
"overview_gateway",
|
||||
"reconciliation_gateway",
|
||||
"service_gateway",
|
||||
"transactions_gateway",
|
||||
"transfers_gateway",
|
||||
]
|
||||
|
||||
@@ -1,6 +1,11 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import (
|
||||
list_ledger_accounts,
|
||||
update_ledger_account,
|
||||
list_ledger_accounts as list_ledger_accounts,
|
||||
update_ledger_account as update_ledger_account,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"list_ledger_accounts",
|
||||
"update_ledger_account",
|
||||
]
|
||||
|
||||
@@ -1,10 +1,19 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import (
|
||||
close_asset_snapshot,
|
||||
create_manual_asset,
|
||||
deactivate_manual_asset,
|
||||
list_manual_assets,
|
||||
preview_asset_snapshot_close,
|
||||
update_manual_asset,
|
||||
close_asset_snapshot as close_asset_snapshot,
|
||||
create_manual_asset as create_manual_asset,
|
||||
deactivate_manual_asset as deactivate_manual_asset,
|
||||
list_manual_assets as list_manual_assets,
|
||||
preview_asset_snapshot_close as preview_asset_snapshot_close,
|
||||
update_manual_asset as update_manual_asset,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"close_asset_snapshot",
|
||||
"create_manual_asset",
|
||||
"deactivate_manual_asset",
|
||||
"list_manual_assets",
|
||||
"preview_asset_snapshot_close",
|
||||
"update_manual_asset",
|
||||
]
|
||||
|
||||
@@ -1,20 +1,39 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import (
|
||||
apply_categorization_rules,
|
||||
apply_category_rule,
|
||||
apply_uncategorized_group_recommendation,
|
||||
apply_uncategorized_recommendation,
|
||||
create_category_rule,
|
||||
create_ledger_category,
|
||||
delete_ledger_category,
|
||||
get_uncategorized_merchant_summary,
|
||||
get_uncategorized_workbench,
|
||||
list_category_rules,
|
||||
list_ledger_categories,
|
||||
list_uncategorized_transactions,
|
||||
preview_categorization,
|
||||
preview_category_rule_matches,
|
||||
seed_default_category_rules,
|
||||
seed_default_ledger_categories,
|
||||
apply_categorization_rules as apply_categorization_rules,
|
||||
apply_category_rule as apply_category_rule,
|
||||
apply_uncategorized_group_recommendation as apply_uncategorized_group_recommendation,
|
||||
apply_uncategorized_recommendation as apply_uncategorized_recommendation,
|
||||
create_category_rule as create_category_rule,
|
||||
create_ledger_category as create_ledger_category,
|
||||
delete_ledger_category as delete_ledger_category,
|
||||
get_uncategorized_merchant_summary as get_uncategorized_merchant_summary,
|
||||
get_uncategorized_workbench as get_uncategorized_workbench,
|
||||
list_category_rules as list_category_rules,
|
||||
list_ledger_categories as list_ledger_categories,
|
||||
list_uncategorized_transactions as list_uncategorized_transactions,
|
||||
preview_categorization as preview_categorization,
|
||||
preview_category_rule_matches as preview_category_rule_matches,
|
||||
seed_default_category_rules as seed_default_category_rules,
|
||||
seed_default_ledger_categories as seed_default_ledger_categories,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"apply_categorization_rules",
|
||||
"apply_category_rule",
|
||||
"apply_uncategorized_group_recommendation",
|
||||
"apply_uncategorized_recommendation",
|
||||
"create_category_rule",
|
||||
"create_ledger_category",
|
||||
"delete_ledger_category",
|
||||
"get_uncategorized_merchant_summary",
|
||||
"get_uncategorized_workbench",
|
||||
"list_category_rules",
|
||||
"list_ledger_categories",
|
||||
"list_uncategorized_transactions",
|
||||
"preview_categorization",
|
||||
"preview_category_rule_matches",
|
||||
"seed_default_category_rules",
|
||||
"seed_default_ledger_categories",
|
||||
]
|
||||
|
||||
@@ -1,10 +1,19 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import (
|
||||
import_toss_bank_pdf,
|
||||
import_toss_securities_pdf,
|
||||
list_ledger_import_batches,
|
||||
preview_toss_bank_pdf_import,
|
||||
preview_toss_securities_pdf_import,
|
||||
rollback_ledger_import_batch,
|
||||
import_toss_bank_pdf as import_toss_bank_pdf,
|
||||
import_toss_securities_pdf as import_toss_securities_pdf,
|
||||
list_ledger_import_batches as list_ledger_import_batches,
|
||||
preview_toss_bank_pdf_import as preview_toss_bank_pdf_import,
|
||||
preview_toss_securities_pdf_import as preview_toss_securities_pdf_import,
|
||||
rollback_ledger_import_batch as rollback_ledger_import_batch,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"import_toss_bank_pdf",
|
||||
"import_toss_securities_pdf",
|
||||
"list_ledger_import_batches",
|
||||
"preview_toss_bank_pdf_import",
|
||||
"preview_toss_securities_pdf_import",
|
||||
"rollback_ledger_import_batch",
|
||||
]
|
||||
|
||||
@@ -1,13 +1,25 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import (
|
||||
get_asset_liquidity_report,
|
||||
get_balance_reconciliation_report,
|
||||
get_budget_vs_actual_report,
|
||||
get_monthly_cashflow_report,
|
||||
health_check,
|
||||
list_cross_transfer_review_queue,
|
||||
list_ledger_backups,
|
||||
list_ledger_import_batches,
|
||||
list_uncategorized_transactions,
|
||||
get_asset_liquidity_report as get_asset_liquidity_report,
|
||||
get_balance_reconciliation_report as get_balance_reconciliation_report,
|
||||
get_budget_vs_actual_report as get_budget_vs_actual_report,
|
||||
get_monthly_cashflow_report as get_monthly_cashflow_report,
|
||||
health_check as health_check,
|
||||
list_cross_transfer_review_queue as list_cross_transfer_review_queue,
|
||||
list_ledger_backups as list_ledger_backups,
|
||||
list_ledger_import_batches as list_ledger_import_batches,
|
||||
list_uncategorized_transactions as list_uncategorized_transactions,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"get_asset_liquidity_report",
|
||||
"get_balance_reconciliation_report",
|
||||
"get_budget_vs_actual_report",
|
||||
"get_monthly_cashflow_report",
|
||||
"health_check",
|
||||
"list_cross_transfer_review_queue",
|
||||
"list_ledger_backups",
|
||||
"list_ledger_import_batches",
|
||||
"list_uncategorized_transactions",
|
||||
]
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import get_balance_reconciliation_report
|
||||
from ...service import get_balance_reconciliation_report as get_balance_reconciliation_report
|
||||
|
||||
__all__ = [
|
||||
"get_balance_reconciliation_report",
|
||||
]
|
||||
|
||||
@@ -1,10 +1,28 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from .accounts_gateway import *
|
||||
from .assets_gateway import *
|
||||
from .categorization_gateway import *
|
||||
from .imports_gateway import *
|
||||
from .overview_gateway import *
|
||||
from .reconciliation_gateway import *
|
||||
from .transactions_gateway import *
|
||||
from .transfers_gateway import *
|
||||
from . import accounts_gateway as _accounts_gateway
|
||||
from . import assets_gateway as _assets_gateway
|
||||
from . import categorization_gateway as _categorization_gateway
|
||||
from . import imports_gateway as _imports_gateway
|
||||
from . import overview_gateway as _overview_gateway
|
||||
from . import reconciliation_gateway as _reconciliation_gateway
|
||||
from . import transactions_gateway as _transactions_gateway
|
||||
from . import transfers_gateway as _transfers_gateway
|
||||
|
||||
_GATEWAY_MODULES = (
|
||||
_accounts_gateway,
|
||||
_assets_gateway,
|
||||
_categorization_gateway,
|
||||
_imports_gateway,
|
||||
_overview_gateway,
|
||||
_reconciliation_gateway,
|
||||
_transactions_gateway,
|
||||
_transfers_gateway,
|
||||
)
|
||||
|
||||
__all__: list[str] = []
|
||||
for _module in _GATEWAY_MODULES:
|
||||
for _name in getattr(_module, "__all__", []):
|
||||
globals().setdefault(_name, getattr(_module, _name))
|
||||
if _name not in __all__:
|
||||
__all__.append(_name)
|
||||
|
||||
@@ -1,3 +1,7 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import update_ledger_transaction
|
||||
from ...service import update_ledger_transaction as update_ledger_transaction
|
||||
|
||||
__all__ = [
|
||||
"update_ledger_transaction",
|
||||
]
|
||||
|
||||
@@ -1,11 +1,21 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from ...service import (
|
||||
find_cancel_original_candidates,
|
||||
find_self_transfer_candidates,
|
||||
link_cancel_to_original,
|
||||
link_self_transfer_pair,
|
||||
list_cross_transfer_review_queue,
|
||||
preview_cross_account_transfers,
|
||||
run_cross_account_transfer_match,
|
||||
find_cancel_original_candidates as find_cancel_original_candidates,
|
||||
find_self_transfer_candidates as find_self_transfer_candidates,
|
||||
link_cancel_to_original as link_cancel_to_original,
|
||||
link_self_transfer_pair as link_self_transfer_pair,
|
||||
list_cross_transfer_review_queue as list_cross_transfer_review_queue,
|
||||
preview_cross_account_transfers as preview_cross_account_transfers,
|
||||
run_cross_account_transfer_match as run_cross_account_transfer_match,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"find_cancel_original_candidates",
|
||||
"find_self_transfer_candidates",
|
||||
"link_cancel_to_original",
|
||||
"link_self_transfer_pair",
|
||||
"list_cross_transfer_review_queue",
|
||||
"preview_cross_account_transfers",
|
||||
"run_cross_account_transfer_match",
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user