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

{rdbms-connect} Add support to read UTF-8 files with and without BOM #5162

Merged

Conversation

alanenriqueo
Copy link
Member

@alanenriqueo alanenriqueo commented Jul 28, 2022

If a sql file with UTF-8 BOM encoding is passed to the command az postgres flexible-server execute it will fail because its contents are read assuming that the encoding is utf-8. We need to change to utf-8-sig to be able to handle both cases (UTF-8 with/without BOM).


This checklist is used to make sure that common guidelines for a pull request are followed.

Related command

General Guidelines

  • Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
  • Have you run python scripts/ci/test_index.py -q locally?

For new extensions:

About Extension Publish

There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update src/index.json automatically.
The precondition is to put your code inside this repository and upgrade the version in the pull request but do not modify src/index.json.

@yonzhan
Copy link
Collaborator

yonzhan commented Jul 28, 2022

rdbms-connect

@yonzhan yonzhan requested a review from evelyn-ys July 28, 2022 01:16
@yonzhan yonzhan requested a review from calvinhzy July 28, 2022 01:16
@yonzhan yonzhan added this to the Jul 2022 (2022-08-02) milestone Jul 28, 2022
@evelyn-ys
Copy link
Member

If you want to release a new version, please update setup.py and history.rst

@alanenriqueo alanenriqueo force-pushed the rdbms-connect/fix-utf8-bom-execute branch from b639e1e to ee6c9a3 Compare August 2, 2022 03:39
@evelyn-ys evelyn-ys merged commit b27a2bc into Azure:main Aug 2, 2022
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

Successfully merging this pull request may close these issues.

3 participants