79742219

Date: 2025-08-21 11:37:08
Score: 4.5
Natty:
Report link

No se ha dicho pero una posible solución podría ser añadir en el __init__.py de la carpeta donde están los módulos (por ejemplo si es la carpeta objects que está dentro del proyecto project) lo siguiente:

# project/objects/__init__.py

import importlib

homePageLib = importlib.import_module(
    "project.objects.homePageLib"
)
calendarLib = importlib.import_module(
    "project.objects.calendarLib"
)

Después en cada módulo homePageLib y calendarLib hacer el import de la siguiente manera:

from project.objects import homePageLib

o

from project.objects import calendarLib

y para usarlo dentro:

return calendarLib.CalendarPage()

Reasons:
  • Blacklisted phrase (1): está
  • Blacklisted phrase (3): solución
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: Juanjo