¡@

Home 

python Programming Glossary: fileno

Python live coding/debugging

http://stackoverflow.com/questions/19757232/python-live-coding-debugging

code.interact local locs locs args 0 if args else None fileno sys.stdin.fileno p Process target _open_interp args locs fileno.. local locs locs args 0 if args else None fileno sys.stdin.fileno p Process target _open_interp args locs fileno p.daemon True.. sys.stdin.fileno p Process target _open_interp args locs fileno p.daemon True p.start The reason I initially avoided multiprocessing..

Retrieving the output of subprocess.call()

http://stackoverflow.com/questions/1996518/retrieving-the-output-of-subprocess-call

subprocess.py line 945 in _get_handles c2pwrite stdout.fileno AttributeError StringIO instance has no attribute 'fileno' .. AttributeError StringIO instance has no attribute 'fileno' python pipes subprocess stringio share improve this question.. must have a real file descriptor and thus implement the fileno method. Just using any file like object won't do the trick...

How to flush the input stream in python?

http://stackoverflow.com/questions/2520893/how-to-flush-the-input-stream-in-python

doesn't work on Windows because sys.stdin doesn't have a fileno attribute. I was curious and threw together a solution using..

How to make tkinter repond events while waiting socket data?

http://stackoverflow.com/questions/3348757/how-to-make-tkinter-repond-events-while-waiting-socket-data

be a Python file or socket object actually anything with a fileno method or an integer file descriptor. The mask is one of the..

Wrap subprocess' stdout/stderr

http://stackoverflow.com/questions/4335587/wrap-subprocess-stdout-stderr

parameter stdout and stderr I can see that it accesses the fileno attribute so it is doing something with the object. However.. repr self msg def __getattr__ self name if not name in 'fileno' self._print # Redirecting s name return getattr self._stream..

Decorate \ delegate a File object to add functionality

http://stackoverflow.com/questions/4713932/decorate-delegate-a-file-object-to-add-functionality

def write self data return logging.log self.level data def fileno self return self.pipe 1 def close self if self._run self._run..

Merge and sync stdout and stderr?

http://stackoverflow.com/questions/4984549/merge-and-sync-stdout-and-stderr

name self._impl impl self._buf '' self._rows def fileno self Pass through for file descriptor. return self._impl.fileno.. self Pass through for file descriptor. return self._impl.fileno def read self drain 0 Read from the file descriptor. If 'drain'.. break def _read self Read from the file descriptor fd self.fileno buf os.read fd 4096 if not buf return None if ' n' not in buf..

Python: select() doesn't signal all input from pipe

http://stackoverflow.com/questions/5486717/python-select-doesnt-signal-all-input-from-pipe

outputready exceptready select.select engine.stdout.fileno 10.0 if inputready outputready exceptready print trying to.. object def __init__ self fd self._fd fd self._buf '' def fileno self return self._fd def readlines self data os.read self._fd.. 1 tmp 1 return lines proc_stdout LineReader engine.stdout.fileno proc_stderr LineReader engine.stderr.fileno readable proc_stdout..

How epoll detect clientside close in Python?

http://stackoverflow.com/questions/793646/how-epoll-detect-clientside-close-in-python

blocking socket server epoll select.epoll epoll.register s.fileno select.EPOLLIN # Level triggerred cs data '' while True time.sleep.. # Timeout 1 second print 'Polling d events' len events for fileno event in events if fileno s.fileno sk addr s.accept sk.setblocking.. d events' len events for fileno event in events if fileno s.fileno sk addr s.accept sk.setblocking 0 print addr cs sk.fileno..

Windows cmd encoding change causes Python crash

http://stackoverflow.com/questions/878972/windows-cmd-encoding-change-causes-python-crash

or GetConsoleMode handle byref DWORD 0 old_stdout_fileno None old_stderr_fileno None if hasattr sys.stdout 'fileno' old_stdout_fileno.. handle byref DWORD 0 old_stdout_fileno None old_stderr_fileno None if hasattr sys.stdout 'fileno' old_stdout_fileno sys.stdout.fileno.. None old_stderr_fileno None if hasattr sys.stdout 'fileno' old_stdout_fileno sys.stdout.fileno if hasattr sys.stderr 'fileno'..