exxeleron / qPython

interprocess communication between Python and kdb+
http://www.devnet.de
Apache License 2.0
152 stars 89 forks source link

Pandas integration bug: Python3 bytes saves to KDB as symbol #68

Open gowestyang opened 5 years ago

gowestyang commented 5 years ago

When reading from KDB to Python 3 pandas dataframe, as document says: symbol (KDB) => numpy.bytes_ (python) string (KDB) => bytes (python) However, I found symbol is also read as bytes with pandas=True

More importantly, when write a pandas dataframe to KDB, I tested the type conversion: str (python) => symbol (KDB) numpy.bytes_(python) => symbol (KDB) bytes (python) => symbol (KDB)

If in a list, the bytes (python) is correctly converted to string (KDB). But the bug shows for pandas dataframe.

dahanaclsa commented 2 years ago

I'm also facing the issue. Probable cause is _pandas.py/line 163 casting QSTRING to QSYMBOL