| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
Review requested:
|
Sorry, something went wrong.
Codecov Report✅ All modified and coverable lines are covered by tests. @@ Coverage Diff @@
## main #61409 +/- ##
==========================================
- Coverage 89.87% 89.78% -0.09%
==========================================
Files 671 672 +1
Lines 203178 203876 +698
Branches 39062 39186 +124
==========================================
+ Hits 182599 183051 +452
- Misses 12926 13142 +216
- Partials 7653 7683 +30
... and 70 files with indirect coverage changes 🚀 New features to boost your workflow:
|
Sorry, something went wrong.
| let StringDecoder; | ||
| function lazyStringDecoder() { | ||
| if (StringDecoder === undefined) | ||
| ({ StringDecoder } = require('string_decoder')); | ||
| return StringDecoder; | ||
| } |
There was a problem hiding this comment.
There's a lazy utility in the internal utils.
Sorry, something went wrong.
There was a problem hiding this comment.
@avivkeller this is not new code, it's just moved to an outer scope
Ideally all that should go away with follow-up fixes, string_decoder path is invalid anyway
I don't think it's worth refactoring it further
Sorry, something went wrong.
There was a problem hiding this comment.
I still think we should use the new lazy module. Regardless of this being new code or not, git sees it as a new code.
Sorry, something went wrong.
There was a problem hiding this comment.
@anonrig Next two prs will remove this anyway. This is going in iterative steps, the intention of this PR is to make rewrite easier, not to be that rewrite. I don't think it should be blocked on rewriting a code block that wasn't introduced here and is gonna be removed.
Sorry, something went wrong.
Sorry, something went wrong.
|
Rebased, no actual changes |
Sorry, something went wrong.
There was a problem hiding this comment.
lgtm
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
|
The withoutintl test failure looks related. 19:12:10 not ok 3707 parallel/test-whatwg-encoding-custom-textdecoder
19:12:10 ---
19:12:10 duration_ms: 70.66700
19:12:10 severity: fail
19:12:10 exitcode: 1
19:12:10 stack: |-
19:12:10 node:internal/assert/utils:146
19:12:10 throw error;
19:12:10 ^
19:12:10
19:12:10 AssertionError [ERR_ASSERTION]: Missing expected exception (TypeError).
19:12:10 at Object.<anonymous> (/home/iojs/build/workspace/node-test-commit-linux-containered/test/parallel/test-whatwg-encoding-custom-textdecoder.js:88:10)
19:12:10 at Module._compile (node:internal/modules/cjs/loader:1803:14)
19:12:10 at Object..js (node:internal/modules/cjs/loader:1934:10)
19:12:10 at Module.load (node:internal/modules/cjs/loader:1524:32)
19:12:10 at Module._load (node:internal/modules/cjs/loader:1326:12)
19:12:10 at TracingChannel.traceSync (node:diagnostics_channel:328:14)
19:12:10 at wrapModuleLoad (node:internal/modules/cjs/loader:245:24)
19:12:10 at Module.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:154:5)
19:12:10 at node:internal/main/run_main_module:33:47 {
19:12:10 generatedMessage: false,
19:12:10 code: 'ERR_ASSERTION',
19:12:10 actual: undefined,
19:12:10 expected: {
19:12:10 code: 'ERR_NO_ICU',
19:12:10 name: 'TypeError',
19:12:10 message: '"fatal" option is not supported on Node.js compiled without ICU'
19:12:10 },
19:12:10 operator: 'throws',
19:12:10 diff: 'simple'
19:12:10 }
19:12:10
19:12:10 Node.js v26.0.0-pre
19:12:10 ...
|
Sorry, something went wrong.
|
@richardlau indeed, I missed that, thanks! I'll update the test |
Sorry, something went wrong.
Sorry, something went wrong.
Sorry, something went wrong.
PR-URL: #61409 Reviewed-By: Aviv Keller <me@aviv.sh> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day> Reviewed-By: Richard Lau <richard.lau@ibm.com>
PR-URL: #61409 Reviewed-By: Aviv Keller <me@aviv.sh> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day> Reviewed-By: Richard Lau <richard.lau@ibm.com>
PR-URL: #61409 Reviewed-By: Aviv Keller <me@aviv.sh> Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Gürgün Dayıoğlu <hey@gurgun.day> Reviewed-By: Richard Lau <richard.lau@ibm.com>
| Back | FazBrowse Home | New Git URL |
Better reviewed with whitespace ignored
I don't think this is major, and reporting the actual encoding name is better in that case.
This will allow further fixes and common fast path for UTF-16 / fixed impl for UTF-16 as string_decoder doesn't implement UTF-16 per spec.
UTF-16 is still broken in no-ICU version here, this PR does not address that.
Tracking: #61041