Closed bltierney closed 8 years ago
gethostbyname()
by itself does not return anything so this incomplete. That resolves a hostname. I can do this one of two ways:
>>> socket.gethostname()
'Natsume.local'
>>> socket.gethostbyname(socket.gethostname())
'192.168.1.4'
What do we want?
The first option will never fail and is more human readable.
we want socket.gethostname()
1) Duration should be in seconds, not ms. Round to 2 decimal places
2) add a new 'meta' field: sensor_id default: results of 'gethostname()' system call ability to override default with a command line switch