code style
This commit is contained in:
parent
1c4543b7bf
commit
dc44c9ed61
11
server.py
11
server.py
@ -1,15 +1,17 @@
|
||||
from http.server import HTTPServer
|
||||
from owrx.http import RequestHandler
|
||||
from owrx.config import PropertyManager, FeatureDetector, RequirementMissingException
|
||||
from owrx.config import PropertyManager, FeatureDetector
|
||||
from owrx.source import SdrService
|
||||
from socketserver import ThreadingMixIn
|
||||
|
||||
import logging
|
||||
logging.basicConfig(level = logging.DEBUG, format = "%(asctime)s - %(name)s - %(levelname)s - %(message)s")
|
||||
|
||||
|
||||
class ThreadedHttpServer(ThreadingMixIn, HTTPServer):
|
||||
pass
|
||||
|
||||
|
||||
def main():
|
||||
print()
|
||||
print("OpenWebRX - Open Source SDR Web App for Everyone! | for license see LICENSE file in the package")
|
||||
@ -18,10 +20,11 @@ def main():
|
||||
print("Author contact info: Andras Retzler, HA7ILM <randras@sdr.hu>")
|
||||
print()
|
||||
|
||||
cfg=__import__("config_webrx")
|
||||
cfg = __import__("config_webrx")
|
||||
pm = PropertyManager.getSharedInstance()
|
||||
for name, value in cfg.__dict__.items():
|
||||
if (name.startswith("__")): continue
|
||||
if name.startswith("__"):
|
||||
continue
|
||||
pm[name] = value
|
||||
|
||||
featureDetector = FeatureDetector()
|
||||
@ -38,5 +41,5 @@ def main():
|
||||
server.serve_forever()
|
||||
|
||||
|
||||
if __name__=="__main__":
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
Loading…
Reference in New Issue
Block a user