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

csv module utils: detect unicode BOM in content #6662

Merged
merged 6 commits into from
Jun 15, 2023

Conversation

russoz
Copy link
Collaborator

@russoz russoz commented Jun 9, 2023

SUMMARY

If CSV content contains a BOM marker then remove it from the content

Fixes #544

ISSUE TYPE
  • Bugfix Pull Request
  • Test Pull Request
COMPONENT NAME

plugins/module_utils/csv.py

@ansibullbot ansibullbot added bug This issue/PR relates to a bug integration tests/integration module_utils module_utils plugins plugin (any type) tests tests needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR labels Jun 9, 2023
@ansibullbot ansibullbot removed the needs_revision This PR fails CI tests or a maintainer has requested a review/revision of the PR label Jun 9, 2023
@felixfontein felixfontein added check-before-release PR will be looked at again shortly before release and merged if possible. backport-7 labels Jun 10, 2023
@felixfontein
Copy link
Collaborator

recheck

Copy link
Collaborator

@felixfontein felixfontein left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me. If nobody objects, I'll merge this in ~a week.

@felixfontein felixfontein removed the check-before-release PR will be looked at again shortly before release and merged if possible. label Jun 15, 2023
@felixfontein felixfontein merged commit bb21693 into ansible-collections:main Jun 15, 2023
@patchback
Copy link

patchback bot commented Jun 15, 2023

Backport to stable-6: 💚 backport PR created

✅ Backport PR branch: patchback/backports/stable-6/bb2169340d04b70f3a35f6e321ca5dfe444fb3aa/pr-6662

Backported as #6694

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback bot pushed a commit that referenced this pull request Jun 15, 2023
* csv module utils: detect unicode BOM in content

* fix handling of py2

* fix comment

* add changelog frag

* add missing link

* simplification

(cherry picked from commit bb21693)
@patchback
Copy link

patchback bot commented Jun 15, 2023

Backport to stable-7: 💚 backport PR created

✅ Backport PR branch: patchback/backports/stable-7/bb2169340d04b70f3a35f6e321ca5dfe444fb3aa/pr-6662

Backported as #6695

🤖 @patchback
I'm built with octomachinery and
my source is open — https://github.com/sanitizers/patchback-github-app.

patchback bot pushed a commit that referenced this pull request Jun 15, 2023
* csv module utils: detect unicode BOM in content

* fix handling of py2

* fix comment

* add changelog frag

* add missing link

* simplification

(cherry picked from commit bb21693)
@felixfontein
Copy link
Collaborator

@russoz thanks for fixing this!

felixfontein pushed a commit that referenced this pull request Jun 15, 2023
…de BOM in content (#6694)

csv module utils: detect unicode BOM in content (#6662)

* csv module utils: detect unicode BOM in content

* fix handling of py2

* fix comment

* add changelog frag

* add missing link

* simplification

(cherry picked from commit bb21693)

Co-authored-by: Alexei Znamensky <[email protected]>
felixfontein pushed a commit that referenced this pull request Jun 15, 2023
…de BOM in content (#6695)

csv module utils: detect unicode BOM in content (#6662)

* csv module utils: detect unicode BOM in content

* fix handling of py2

* fix comment

* add changelog frag

* add missing link

* simplification

(cherry picked from commit bb21693)

Co-authored-by: Alexei Znamensky <[email protected]>
@russoz russoz deleted the 544-csv-bom branch June 15, 2023 06:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue/PR relates to a bug has_issue integration tests/integration module_utils module_utils plugins plugin (any type) tests tests
Projects
None yet
Development

Successfully merging this pull request may close these issues.

read_csv - Key 'Name' was not found in the CSV header fields
3 participants