• Swoboderz

    @JonB this chunk of code (which is where it all goes wrong) already has that. Does it need to be hard coded? stream = sys.stdout
    if stream.errors == 'strict':
    # emulate backslashreplace error handler
    encoding = stream.encoding
    msg = msg.encode(encoding, "backslashreplace").decode(encoding)
    stream.write('%s\n' % msg)
    stream.flush()

    posted in Pythonista read more
  • Swoboderz

    @ccc2

    >>> import sys
    >>> print(sys.stdout)
    <__main__.main.<locals>.StdoutCatcher object at 0x1093257b8>
    >>> print(sys.__stdout__)
    <_io.TextIOWrapper name='<stdout>' mode='w' encoding='US-ASCII'>
    

    I'm trying to use a C extension..

    posted in Pythonista read more
  • Swoboderz

    File "/var/containers/Bundle/Application/D1ECCA2A-92A4-498F-9924-55A09E1EE6CD/Pythonista3.app/Frameworks/Py3Kit.framework/pylib/distutils/log.py", line 32, in _log
    if stream.errors == 'strict':
    AttributeError: 'StdoutCatcher' object has no attribute 'errors'

    Why is it doing this,

    posted in Pythonista read more

Internal error.

Oops! Looks like something went wrong!