Add example projects
This commit is contained in:
33
examples/complex_project/main.py
Normal file
33
examples/complex_project/main.py
Normal file
@@ -0,0 +1,33 @@
|
||||
"""
|
||||
Main entry point for the application.
|
||||
"""
|
||||
|
||||
from typing import Dict, Any
|
||||
from .config import AppConfig
|
||||
from .core import Application
|
||||
from .utils import Logger
|
||||
|
||||
|
||||
def main() -> None:
|
||||
"""Main entry point."""
|
||||
logger = Logger("Main")
|
||||
logger.info("Starting application...")
|
||||
|
||||
config = AppConfig(
|
||||
debug=True,
|
||||
max_retries=5,
|
||||
timeout=60
|
||||
)
|
||||
|
||||
app = Application(config)
|
||||
|
||||
try:
|
||||
app.run()
|
||||
logger.info("Application completed successfully")
|
||||
except Exception as e:
|
||||
logger.error(f"Application failed: {e}")
|
||||
raise
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
Reference in New Issue
Block a user