Strip less punctuation and clearer message on broken direction when scanning story
This commit is contained in:
parent
9cd98367cd
commit
902ce549f5
4 changed files with 13 additions and 10 deletions
|
@ -25,7 +25,8 @@ import string
|
||||||
mainLogger = logging.getLogger("hugvey")
|
mainLogger = logging.getLogger("hugvey")
|
||||||
logger = mainLogger.getChild("google")
|
logger = mainLogger.getChild("google")
|
||||||
|
|
||||||
punctuationTranslation = str.maketrans('','',string.punctuation)
|
# punctuationTranslation = str.maketrans('','',string.punctuation) # has ' etc., so don't use it!
|
||||||
|
punctuationTranslation = str.maketrans('','','.,!?')
|
||||||
|
|
||||||
class RequireRestart(Exception):
|
class RequireRestart(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
|
@ -151,7 +151,7 @@ class Toolbox:
|
||||||
for i, item in enumerate(story):
|
for i, item in enumerate(story):
|
||||||
if item['@type'] == 'Direction':
|
if item['@type'] == 'Direction':
|
||||||
if type(item['source']) == dict:
|
if type(item['source']) == dict:
|
||||||
logger.warn(f"Fixing broken direction {item['@id']}, please check if everything still works!")
|
logger.warn(f"Fixing broken direction {item['@id']}, connecting {item['source']['@id']} -> {item['target']}, please check if everything still works!")
|
||||||
validMsg = itemsPerId[item['source']['@id']]
|
validMsg = itemsPerId[item['source']['@id']]
|
||||||
diff = DictDiffer(item['source'], validMsg)
|
diff = DictDiffer(item['source'], validMsg)
|
||||||
if diff.changed() or diff.added() or diff.removed():
|
if diff.changed() or diff.added() or diff.removed():
|
||||||
|
|
2
local
2
local
|
@ -1 +1 @@
|
||||||
Subproject commit 16738c586f1938814b12ad50be2af06ffa2bf37e
|
Subproject commit 7b7f5c687465bf370400fc7bb91368e205794830
|
|
@ -1,11 +1,11 @@
|
||||||
#N canvas 1208 380 676 571 10;
|
#N canvas 1382 64 1276 1029 10;
|
||||||
#X obj 178 276 dac~;
|
#X obj 178 276 dac~;
|
||||||
#X obj 178 226 readsf~;
|
#X obj 178 226 readsf~;
|
||||||
#X obj 256 208 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
|
#X obj 256 208 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144
|
||||||
-1 -1;
|
-1 -1;
|
||||||
#X text 276 205 (re-)start loop;
|
#X text 276 205 (re-)start loop;
|
||||||
#X obj 399 463 netsend -u -b;
|
#X obj 399 463 netsend -u -b;
|
||||||
#X obj 399 485 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
|
#X obj 399 485 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
|
||||||
1;
|
1;
|
||||||
#X msg 270 333 disconnect;
|
#X msg 270 333 disconnect;
|
||||||
#X obj 355 311 list prepend send;
|
#X obj 355 311 list prepend send;
|
||||||
|
@ -18,7 +18,7 @@
|
||||||
#X obj 365 83 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
|
#X obj 365 83 bng 15 250 50 0 empty empty empty 17 7 0 10 -262144 -1
|
||||||
-1;
|
-1;
|
||||||
#X text 264 59 START;
|
#X text 264 59 START;
|
||||||
#X obj 483 83 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
|
#X obj 483 83 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
|
||||||
1;
|
1;
|
||||||
#X text 356 60 !STOP!;
|
#X text 356 60 !STOP!;
|
||||||
#X text 469 59 Playing indicator;
|
#X text 469 59 Playing indicator;
|
||||||
|
@ -26,20 +26,22 @@
|
||||||
#X msg 377 116 0;
|
#X msg 377 116 0;
|
||||||
#X obj 355 263 oscformat /loop;
|
#X obj 355 263 oscformat /loop;
|
||||||
#X obj 99 463 netsend -u -b;
|
#X obj 99 463 netsend -u -b;
|
||||||
#X obj 99 485 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 1
|
#X obj 99 485 tgl 15 0 empty empty empty 17 7 0 10 -262144 -1 -1 0
|
||||||
1;
|
1;
|
||||||
#X msg 99 419 connect 127.0.0.1 9000;
|
#X msg 99 419 connect 127.0.0.1 9000;
|
||||||
#X text 393 384 Connection to Max/MSP with light;
|
#X text 393 384 Connection to Max/MSP with light;
|
||||||
#X text 104 375 Connection to local python server commanding the Hugveys
|
#X text 104 375 Connection to local python server commanding the Hugveys
|
||||||
;
|
;
|
||||||
#X msg 399 422 connect 192.168.1.175 7400;
|
#X msg 399 422 connect 192.168.1.175 7400;
|
||||||
#X msg 179 169 open /mnt/stash/hugvey/sound/score41_loop_plus40s.wav
|
#X obj 612 168 vsl 15 128 0 127 0 0 empty empty empty 0 -9 0 10 -262144
|
||||||
|
-1 -1 0 1;
|
||||||
|
#X msg 180 169 open /home/ruben/Documents/Projecten/2018/Hugvey/hugvey/recordings/3/20190427-15:20:29/3.wav
|
||||||
\, 1;
|
\, 1;
|
||||||
#X connect 1 0 0 0;
|
#X connect 1 0 0 0;
|
||||||
#X connect 1 0 0 1;
|
#X connect 1 0 0 1;
|
||||||
#X connect 1 1 2 0;
|
#X connect 1 1 2 0;
|
||||||
#X connect 2 0 12 0;
|
#X connect 2 0 12 0;
|
||||||
#X connect 2 0 27 0;
|
#X connect 2 0 28 0;
|
||||||
#X connect 4 0 5 0;
|
#X connect 4 0 5 0;
|
||||||
#X connect 6 0 4 0;
|
#X connect 6 0 4 0;
|
||||||
#X connect 6 0 21 0;
|
#X connect 6 0 21 0;
|
||||||
|
@ -61,4 +63,4 @@
|
||||||
#X connect 21 0 22 0;
|
#X connect 21 0 22 0;
|
||||||
#X connect 23 0 21 0;
|
#X connect 23 0 21 0;
|
||||||
#X connect 26 0 4 0;
|
#X connect 26 0 4 0;
|
||||||
#X connect 27 0 1 0;
|
#X connect 28 0 1 0;
|
||||||
|
|
Loading…
Reference in a new issue