HaxeFoundation / HaxeFoundation/haxe

[python] 'TTYOutStream' object has no attribute 'buffer'

Open
#11,027 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
Haxe
Stars
6.9k
Forks
715
Avg merge
2d 2h
Merged PRs (30d)
11

Description

**Environment**
Anaconda Python 3.9 Spyder IDE
haxe 4.3.0-rc.a49b191

When I try to run my haxe library on [Anaconda Python](https://www.anaconda.com), I get this error

```
File ~\anaconda3\envs\Economic\lib\site-packages\lightstreamer_client\com_lightstreamer_client.py:1687 in printString
python_lib_Sys.stdout.buffer.write(_hx_str.encode("utf-8", "strict"))

AttributeError: 'TTYOutStream' object has no attribute 'buffer'
```

As far as I understand from the haxe source code, the class python.lib.Sys has an attribute `stdout` of type python.lib.io.TextIOBase, which does have a `buffer` attribute (of type BufferedIOBase).

So why do I get the above error?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.