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

fix(HTTP Request Node): Use iconv-lite to decode http responses, to support more encoding types #11930

Merged
merged 2 commits into from
Nov 28, 2024

Conversation

netroy
Copy link
Member

@netroy netroy commented Nov 27, 2024

Summary

Buffer.prototype.toString supports a different set of encoding types than what are common with http responses.
This PR replaces the .toString call with decode from iconv-lite, which supports a much larger set of encoding types.

Related Linear tickets, Github issues, and Community forum posts

CAT-370
Fixes #11928

Review / Merge checklist

  • PR title and summary are descriptive. (conventions)
  • Docs updated or follow-up ticket created.
  • Tests included.
  • PR Labeled with release/backport (if the PR is an urgent fix that needs to be backported)

@n8n-assistant n8n-assistant bot added core Enhancement outside /nodes-base and /editor-ui n8n team Authored by the n8n team labels Nov 27, 2024
Copy link

codecov bot commented Nov 27, 2024

Codecov Report

Attention: Patch coverage is 75.00000% with 1 line in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
packages/core/src/NodeExecuteFunctions.ts 75.00% 0 Missing and 1 partial ⚠️

📢 Thoughts on this report? Let us know!

@netroy netroy marked this pull request as ready for review November 27, 2024 15:48
@netroy netroy changed the title fix(core): Use iconv-lite to decode http responses, to support more encoding types fix(HTTP Request Node): Use iconv-lite to decode http responses, to support more encoding types Nov 27, 2024
Copy link
Contributor

@ShireenMissi ShireenMissi left a comment

Choose a reason for hiding this comment

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

LGTM 🎉

Copy link
Contributor

✅ All Cypress E2E specs passed

Copy link

cypress bot commented Nov 28, 2024

n8n    Run #8142

Run Properties:  status check passed Passed #8142  •  git commit e497ed0ff9: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 netroy 🗃️ e2e/*
Project n8n
Branch Review fix-CAT-370-iconv-decode-http-responses
Run status status check passed Passed #8142
Run duration 04m 50s
Commit git commit e497ed0ff9: 🌳 🖥️ browsers:node18.12.0-chrome107 🤖 netroy 🗃️ e2e/*
Committer कारतोफ्फेलस्क्रिप्ट™
View all properties for this run ↗︎

Test results
Tests that failed  Failures 0
Tests that were flaky  Flaky 3
Tests that did not run due to a developer annotating a test with .skip  Pending 0
Tests that did not run due to a failure in a mocha hook  Skipped 0
Tests that passed  Passing 478
View all changes introduced in this branch ↗︎

@netroy netroy merged commit 461b39c into master Nov 28, 2024
37 checks passed
@netroy netroy deleted the fix-CAT-370-iconv-decode-http-responses branch November 28, 2024 13:31
@github-actions github-actions bot mentioned this pull request Dec 4, 2024
@janober
Copy link
Member

janober commented Dec 4, 2024

Got released with [email protected]

riascho pushed a commit that referenced this pull request Jan 14, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Enhancement outside /nodes-base and /editor-ui n8n team Authored by the n8n team Released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

HTTP Request node & ISO-8859-15 charset
3 participants