Refactor `generic` and `facades` modules with better names
ff137 opened this issue · comments
Mourits de Beer commented
We want to standardise naming/organisation convention such that all route definitions are defined in a module routes
, with custom model definitions in models
; utility methods moved to utils
; etc.
This can be followed up with another PR to simplify any methods that are too complicated. Ideally, route logic should only define routes - any complex logic should be moved into its own module. It seems like this was the intent of facades
, but I think that's a very unclear name. I suggest services
, which can then contain a .py module for the route logic.
In summary:
generic
->routes
(stripping code to only contain route logic)facades
->services
(moving all route logic to appropriate modules here)- custom models, exceptions, and helper methods, should be moved to
models
,exceptions
, andutil
, respectively.