Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

step hangs when python script contains any japanese text #13

Open
benghuduga12 opened this issue Nov 2, 2017 · 1 comment
Open

step hangs when python script contains any japanese text #13

benghuduga12 opened this issue Nov 2, 2017 · 1 comment

Comments

@benghuduga12
Copy link

Hi,

I am facing issue in running the CPython step in transformation when the python script contains any japanese text.

Here i am reading the excel files which the file name and the sheet name is in japanese text.
I am using openpyxl library for processing the excel(read and write). The same script when i run from python environment directly it runs properly. I face problem only when i run it from the CPython Script Executor.

Any help is appreciated.

@m-a-hall
Copy link
Contributor

I will be making a new release shortly that, hopefully, will address this issue. I've seen this issue when decoding UTF-8 bytes in python that have been encoded to UTF-8 by Java (8 at least) when the source text contains characters outside of ascii range. To be honest, I have no idea why this is happening. The same bytes can be decoded fine when done so directly in python - just the encoding in Java seems to be problematic. My fix involves base64 encoding (when non ascii characters are detected). When that is decoded in python, and then the resulting UTF-8 decoded, it seems to work fine. There is an cost in overhead though.

Cheers,
Mark.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants