feat(pkgs/pyjecteur): update
This commit is contained in:
parent
3376137ef8
commit
6733ec2b77
2 changed files with 5 additions and 5 deletions
|
@ -1,4 +1,3 @@
|
||||||
#!/nix/store/z46wvcd15152qnsry80p8ricxya2n2lr-python3-3.11.7-env/bin/python
|
|
||||||
import json
|
import json
|
||||||
import logging
|
import logging
|
||||||
import sys
|
import sys
|
||||||
|
@ -76,9 +75,10 @@ def run():
|
||||||
logging.debug(line)
|
logging.debug(line)
|
||||||
if line.startswith("data:"):
|
if line.startswith("data:"):
|
||||||
dataStr = line[5:]
|
dataStr = line[5:]
|
||||||
logging.debug(f"Received: {dataStr}")
|
logging.info(f"Received: {dataStr}")
|
||||||
data = json.loads(dataStr)
|
data = json.loads(dataStr)
|
||||||
update_light(data["address"], **data["value"])
|
if data["type"] == "Color":
|
||||||
|
update_light(data["address"], **data["value"])
|
||||||
|
|
||||||
|
|
||||||
run()
|
run()
|
||||||
|
|
|
@ -6,8 +6,8 @@ let
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
src = fetchgit {
|
src = fetchgit {
|
||||||
url = "https://git.dgnum.eu/HackENS/pyjecteur.git";
|
url = "https://git.dgnum.eu/HackENS/pyjecteur.git";
|
||||||
rev = "28759972328c2774b3ab571440051bd97ca35bcc";
|
rev = "HEAD";
|
||||||
hash = "sha256-xlLS7Hrh1FrBnW7ASfYz42+pguHCbn3Z1k7X3uQseHQ=";
|
hash = "sha256-s4sXW4mYnmVn1yfeRv1vu3+WH3Aq8Y5OXcupfEp7c/k=";
|
||||||
} ;
|
} ;
|
||||||
passthru = {
|
passthru = {
|
||||||
wheel = buildPythonPackage (attrs // {
|
wheel = buildPythonPackage (attrs // {
|
||||||
|
|
Loading…
Reference in a new issue