root@debian:/bin# ./mac.py
from: can't read /var/mail/python_arptable
./mac.py: line 4: syntax error near unexpected token `('
./mac.py: line 4: `def get_ip_by_mac(macaddr: str):'
root@debian:/bin# nl mac.py
1 from python_arptable import get_arp_table
2 def get_ip_by_mac(macaddr: str):
3 if record := next(filter(lambda i: i['HW address'].lower() == macaddr.lower(), get_arp_table()), None):
4 return record['IP address']
5 print(get_ip_by_mac('my_mac'))
select * from olx
name: olx
time id name price title views
---- -- ---- ----- ----- -----
1638445619723411611 726553615 "Alex" 2000 SSD M2 Samsung 250Gb PRO 125
1638445652184178827 723134335 "Alex" 600 ОЗУ SK Hynix 4gb DDR-4 2666 81
1638445682003754288 728372625 "Alex" 500 Комутатор Ubiquiti UniFi Switch 8 (US-8) (все не рабочие) 233
1638445716856633795 723268384 "Alex" 4555 MIDI-клавиатура Novation LAUNCHKEY 49 407
1638445747457026240 723259840 "Alex" 1200 Графический планшет Wacom PTH-450 ( без пера ) 159
1638445784823900344 723260301 "Alex" 1200 Графический планшет Wacom PTK-440 ( без пера ) 129
1638445810871590032 723248702 "Alex" 5000 Ubiquiti Unifi USG-4-PRO 172
1638445835927006304 723134975 "Alex" 300 Точка доступа D-Link DWL-2600AP 121