patch to upgrade Wake On Lan Recipe that "Switches on remote computers using WOL".
1 2 3 4 5 6 7 8 9 10 11 | 20,21c20,21
< data = ''.join(['FFFFFFFFFFFF', macaddress * 20])
< send_data = ''
---
> data = b'FFFFFFFFFFFF' + (macaddress * 20).encode()
> send_data = b''
25,26c25
< send_data = ''.join([send_data,
< struct.pack('B', int(data[i: i + 2], 16))])
---
> send_data += struct.pack('B', int(data[i: i + 2], 16)
|