Answer the question
In order to leave comments, you need to log in
Why doesn't print work in the console?
from nfstream import NFStreamer
import sys
path = sys.argv[1]
flow_streamer = NFStreamer(source=path)
result = {}
for flow in flow_streamer:
print('-------------------------------------------------------------------------')
print('FLOW')
Answer the question
In order to leave comments, you need to log in
Most likely the code is working correctly. Try putting a delay in your code, and convince yourself that print() outputs data to the console on each iteration of the loop:
from nfstream import NFStreamer
import sys
import time
path = sys.argv[1]
flow_streamer = NFStreamer(source=path)
result = {}
for flow in flow_streamer:
print('-------------------------------------------------------------------------')
print('FLOW')
time.sleep(0.2)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question