-
-
Notifications
You must be signed in to change notification settings - Fork 18.5k
to_csv to Google Cloud Storage ignores encoding #26124
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
Comments
Not sure this is even supported by gcsfs - I don't see Might need to start upstream if wanted to make this possible |
I've encountered this issue with AWS s3 as well. Encoding is ignored. |
Hi, @WillAyd where applying of passed
Note also this issue from gcsfs So, it looks that in Tracing back to the moment of the first actual setting the
It is so, because in the call of Line 430 in 29d6b02
we do not pass value of As I could suggest for read_csv() we need pass |
Code Sample, a copy-pastable example if possible
Problem description
Instead of expected UTF-8 file is stored in latin-1 on Windows. I can also see that current implementation of method
pandas.io.gcs.get_filepath_or_buffer
ignores encoding argument.I can submit PR if are open to it.
Expected Output
Uploaded file encoded in UTF8 even on Windows.
Output of
pd.show_versions()
[paste the output of
pd.show_versions()
here below this line]INSTALLED VERSIONS
commit: None
python: 3.7.1.final.0
python-bits: 64
OS: Linux
OS-release: 4.18.0-17-generic
machine: x86_64
processor: x86_64
byteorder: little
LC_ALL: None
LANG: en_US.UTF-8
LOCALE: en_US.UTF-8
pandas: 0.24.2
pytest: None
pip: 10.0.1
setuptools: 39.1.0
Cython: None
numpy: 1.16.2
scipy: None
pyarrow: None
xarray: None
IPython: None
sphinx: None
patsy: None
dateutil: 2.8.0
pytz: 2018.9
blosc: None
bottleneck: None
tables: None
numexpr: None
feather: None
matplotlib: None
openpyxl: None
xlrd: None
xlwt: None
xlsxwriter: None
lxml.etree: None
bs4: None
html5lib: None
sqlalchemy: None
pymysql: None
psycopg2: None
jinja2: 2.10
s3fs: None
fastparquet: None
pandas_gbq: 0.9.0
pandas_datareader: None
gcsfs: 0.2.1
The text was updated successfully, but these errors were encountered: