comparison light8/Patch.py @ 42:5e4fb4ac2d18

corrected Patch's error behavior and subediting's catching behavior
author drewp
date Sun, 07 Jul 2002 12:24:01 +0000
parents f974a462133f
children 174b35926067
comparison
equal deleted inserted replaced
41:02151923be45 42:5e4fb4ac2d18
6 6
7 try: 7 try:
8 i = int(name) 8 i = int(name)
9 return i 9 return i
10 except ValueError: 10 except ValueError:
11 raise "Invalid channel name:", name 11 raise ValueError("Invalid channel name: %s" % name)
12 12
13 def get_channel_name(dmxnum): 13 def get_channel_name(dmxnum):
14 try: 14 try:
15 return reverse_patch[dmxnum] 15 return reverse_patch[dmxnum]
16 except KeyError: 16 except KeyError: