python - Using raw_input causes problems with PyQt page loading -
i'm using pyqt4 enter credentials domain login page , pull data several additional pages in domain. works expected when supplying login or search credentials within code. when open raw_input allow user enter information, causes hang-ups trying download 1 of web-pages. can't provide information on page because on corporate network, doesn't make sense using raw_input cause problems qwebpage loads.
the qnetworkmanager throws 1 of expected 3 or 4 .finished signals , qwebpage frame never throws .loadfinished signal hangs.
(i've tried flushing stdin seek(0) gives me bad file descriptor error). has run such problem before?
raw_input
uses synchronous/blocking io without giving qt chance continue processing events in background. qt isn't prepared it's processing halted in way. in theory should resume when raw_input finished. maybe in meantime timeout occurred or that. should use signal/event based input when using qt.
if gui interaction ok should try qinputdialog::gettext because looks blocking call outside internally lets qt continue processing background jobs.
Comments
Post a Comment