The source of this error is this (sub "begin_capture")...

def begin_capture(self):
        for t, pkt in self.pcap:
            stream = dpkt.ethernet.Ethernet(pkt)
            data =
            self.ip = "%d.%d.%d.%d" %tuple(map(ord, list(

            if data.dport == self.port:

Its not that it behaves differently in a shell, as I don't run it in any shell; just through console. This is the link to the entire module:

Yahoo! oneSearch: Finally, mobile search that gives answers, not web links.