Moved to SQLAlchemy
Finished switch to JSONRPC commit 9cf6dd9a0e03c71135c01d4ad4f7d3be0f1e3066 Author: Giovanni Harting <giovanni.harting@touchdata.net> Date: Sat Oct 10 21:09:20 2015 +0200 fixed some bugs added some missing things from transition commit 8ed44b8fcde739b541b1834049025b055a50e6fe Author: Marius Schiffer <marius@mschiffer.de> Date: Sat Oct 10 05:53:41 2015 +0200 Creating fresh database works now. Fixed pwm_freq property. commit dc88ef0df427f90746a499912eff70dfce967c55 Author: Marius Schiffer <marius@mschiffer.de> Date: Sat Oct 10 04:40:41 2015 +0200 Completed SQLAlchemy integration. Completed JSON-RPC integration. All daemon class functionality is now on module-level (required for JSON-RPC decorators). Migrations will have to be reimplemented with alembic. commit a4cabdcd00a3e2a3cbbd92a3c9d59a4235e4d277 Author: Marius Schiffer <marius@mschiffer.de> Date: Sat Oct 10 03:00:19 2015 +0200 First steps towards SQLAlchemy integration.
This commit is contained in:
10
ledd.py
10
ledd.py
@@ -36,9 +36,6 @@ from pkgutil import iter_modules
|
||||
|
||||
from docopt import docopt
|
||||
|
||||
import ledd.daemon
|
||||
import ledd
|
||||
|
||||
if "smbus" not in (name for loader, name, ispkg in iter_modules()):
|
||||
print("smbus not found, installing replacement")
|
||||
|
||||
@@ -65,6 +62,9 @@ if "smbus" not in (name for loader, name, ispkg in iter_modules()):
|
||||
sys.modules['smbus'] = SMBusModule
|
||||
sys.modules['smbus'].SMBus = SMBus
|
||||
|
||||
import ledd.daemon
|
||||
import ledd
|
||||
|
||||
|
||||
def pid_exists(processid):
|
||||
if processid < 0:
|
||||
@@ -118,7 +118,7 @@ if __name__ == "__main__":
|
||||
os.chdir(wdir)
|
||||
with open("ledd.pid", 'w') as pidf:
|
||||
pidf.write(str(os.getpid()) + '\n')
|
||||
daemon = ledd.daemon.Daemon()
|
||||
ledd.daemon.run()
|
||||
else:
|
||||
sys.exit()
|
||||
else:
|
||||
@@ -126,4 +126,4 @@ if __name__ == "__main__":
|
||||
except OSError as e:
|
||||
log.fatal("Start failed: %s", e)
|
||||
else:
|
||||
daemon = ledd.daemon.Daemon()
|
||||
ledd.daemon.run()
|
||||
|
Reference in New Issue
Block a user