8855f1155b
Add custom exceptions and add error handling to the engine's module loading logic. I.e. when a non-existent module is loaded, an exception is thrown now. see #23
25 lines
550 B
Python
Executable file
25 lines
550 B
Python
Executable file
#!/usr/bin/env python
|
|
|
|
import sys
|
|
import bumblebee.engine
|
|
import bumblebee.config
|
|
import bumblebee.output
|
|
|
|
def main():
|
|
config = bumblebee.config.Config(sys.argv[1:])
|
|
output = bumblebee.output.I3BarOutput()
|
|
engine = bumblebee.engine.Engine(
|
|
config=config,
|
|
output=output,
|
|
)
|
|
|
|
engine.run()
|
|
|
|
if __name__ == "__main__":
|
|
try:
|
|
main()
|
|
except bumblebee.error.BaseError as error:
|
|
sys.stderr.write("fatal: {}\n".format(error))
|
|
sys.exit(1)
|
|
|
|
# vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4
|