Skip to content

Commit

Permalink
chore: update package name to turbobus
Browse files Browse the repository at this point in the history
  • Loading branch information
cafadev committed Oct 11, 2023
1 parent 1994380 commit 72fef0b
Show file tree
Hide file tree
Showing 9 changed files with 6 additions and 8 deletions.
Empty file added README.md
Empty file.
4 changes: 2 additions & 2 deletions log/axioma/log.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@
from dataclasses import dataclass
from typing import TypeAlias

from bus.bus import Command, CommandHandler
from bus.decorators import command
from turbobus.bus import Command, CommandHandler
from turbobus.decorators import command


LogHandlerType: TypeAlias = "ILogHandler"
Expand Down
2 changes: 1 addition & 1 deletion log/capabilities/log.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
from dataclasses import dataclass
from bus.decorators import command, injectable, injecting
from turbobus.decorators import command, injectable, injecting
from ..axioma.log import ILogger, LogCommand


Expand Down
2 changes: 1 addition & 1 deletion log/capabilities/logger.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from bus.decorators import injectable
from turbobus.decorators import injectable
from log.axioma.log import ILogger


Expand Down
2 changes: 1 addition & 1 deletion main.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from log.axioma import LogCommand
# from log.capabilities.log import Logger
from bus import bus
from turbobus import bus


bus = bus.CommandBus()
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion bus/bus.py → turbobus/bus.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ def execute(self, cmd, providers: dict[Any, Any] = {}):
Handler = cmd.__handler__

if Handler is None:
from bus.exception import CommandHandlerDoesNotExistException
from turbobus.exception import CommandHandlerDoesNotExistException
raise CommandHandlerDoesNotExistException()

result = Handler(**providers).execute(cmd)
Expand Down
2 changes: 0 additions & 2 deletions bus/decorators.py → turbobus/decorators.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ def wrapper(cls):
def injecting(cls: type[T]) -> T:
Provider = providers.get(cls.__name__)

print(providers)

assert Provider is not None

return Provider()
File renamed without changes.

0 comments on commit 72fef0b

Please sign in to comment.