- The last part of the module import path is the module name. This also
becomes the Django app name. Apps names have to be unique. Hence,
there is no scope for two different modules with same name but
different load path to exist in the project.
- Most uses of list of loaded modules are dealing with app names instead
of full module load path. This is due to the fact that Django deals
with app names and not module paths.
- It is also somewhat clumsy to access a loaded module as we are
re-importing every time to get access module.
- Simplify all of the above by using app names are module identifiers
and maintaing an ordered dictionary of app names to loadded modules.
- Remove unused imports.
- Minor styling fixes.
- Add note about resetarting firewalld.
- Refactor checking for running configuration process.
- Fix error message being show as info message.
- Minor indentation fixes.
Using brand name directly from configuration means that it can't be
easily translated. Instead use the translated brand name sent in my the
context processor.
- When Deb822 formatted source files are present, error out and don't
show as enabled.
- When /etc/apt/sources.list.d/*.sources files are present, error out
and don't show as enabled.
- Handle files /etc/apt/sources.list.d/*.list.
- Workaround Augeas lens not understanding '[options]' in sources.list.
- To check whether a service is running does not require root
privileges. This can directly be done from a module without any
action.
- Since actions are allowed to be run using sudo, introducing
unnecessary sub-commands increases attack surface.
- Simple functions calls are unnecessarily being converted to command
line invocations and involve parsing response.
- There is a lot of repeated code because of this that can be
eliminated.
- To generalize this, we need to make all non-root system operations
directly from module instead of delegating to action commands.
- For each application, add ./tests directory and __init__.py file
within it.
- Modify test controllers (coverage.py, runtests.py) to find the new
test directories for testing and coverage analysis.
- Move existing application-specific test modules (test_pagekite.py) to
the newly created directories.