Skip to content

Revert "src: migrate String::Value to String::ValueView" - #55828

Merged
nodejs-github-bot merged 2 commits into
nodejs:mainfrom
targos:revert-55458
Nov 16, 2024
Merged

Revert "src: migrate String::Value to String::ValueView"#55828
nodejs-github-bot merged 2 commits into
nodejs:mainfrom
targos:revert-55458

Conversation

@targos

Copy link
Copy Markdown
Member

This reverts commit 45c6a9e.

Closes: #55826

@nodejs-github-botnodejs-github-bot added c++ Issues and PRs that require attention from people who are familiar with C++. lib / src Issues and PRs related to general changes in the lib or src directory. needs-ci PRs that need a full CI run. labels Nov 12, 2024
Comment on lines -248 to +250

TwoByteValue task_name_buffer(args.GetIsolate(), args[0]);
StringView task_name_view(*task_name_buffer, task_name_buffer.length());
Local<String> task_name = args[0].As<String>();
String::Value task_name_value(args.GetIsolate(), task_name);
StringView task_name_view(*task_name_value, task_name_value.length());

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Do we need a full revert, I feel like this part can stay the same?

Copy link
Copy Markdown
MemberAuthor

Choose a reason for hiding this comment

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

A full revert is easier to work with. You're free to make incremental changes after it.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

A good illustration of why atomic PRs should always be preferred.

@avivkeller

Copy link
Copy Markdown
Member

Is there a test that can be added to ensure this doesn't happen again?

@targos

Copy link
Copy Markdown
MemberAuthor

I wasn't able to find a repro that doesn't involve webpack.

@codecov

codecovBot commented Nov 12, 2024

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 60.71429% with 11 lines in your changes missing coverage. Please review.

Project coverage is 88.41%. Comparing base (3a0968d) to head (df0b75f).
Report is 95 commits behind head on main.

Files with missing linesPatch %Lines
src/string_bytes.cc20.00%8 Missing ⚠️
src/node_buffer.cc80.00%1 Missing and 2 partials ⚠️
Additional details and impacted files
@@ Coverage Diff @@## main #55828 +/- ##
==========================================
- Coverage 88.41% 88.41% -0.01% 
==========================================
Files 654 654 Lines 187811 187817 +6 Branches 36134 36132 -2 ==========================================
+ Hits 166052 166056 +4 - Misses 15008 15011 +3 + Partials 6751 6750 -1 
Files with missing linesCoverage Δ
src/inspector_js_api.cc86.29% <100.00%> (+0.05%)⬆️
src/node_buffer.cc70.06% <80.00%> (-0.12%)⬇️
src/string_bytes.cc68.43% <20.00%> (-0.46%)⬇️

... and 31 files with indirect coverage changes

@targostargos added request-ci Add this label to start a Jenkins CI on a PR. commit-queue-squash Add this label to instruct the Commit Queue to squash all the PR commits into the first one. labels Nov 12, 2024
@github-actionsgithub-actionsBot removed the request-ci Add this label to start a Jenkins CI on a PR. label Nov 12, 2024
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@avivkeller

avivkeller commented Nov 13, 2024

Copy link
Copy Markdown
Member

Sorry for breaking this, everyone! Thanks for the speedy fix

@avivkelleravivkeller added author ready PRs that have at least one approval, no pending requests for changes, and a CI started. revert PRs that revert previously landed PRs. labels Nov 13, 2024
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

willxj36 added a commit to willxj36/Interactive-Resume that referenced this pull request Nov 16, 2024
@aduh95aduh95 added the commit-queue Add this label to land a pull request using GitHub Actions. label Nov 16, 2024
@nodejs-github-botnodejs-github-bot removed the commit-queue Add this label to land a pull request using GitHub Actions. label Nov 16, 2024
@nodejs-github-bot
nodejs-github-bot merged commit 9f2885a into nodejs:mainNov 16, 2024
@nodejs-github-bot

Copy link
Copy Markdown
Collaborator

Landed in 9f2885a

@targos
targos deleted the revert-55458 branch November 17, 2024 06:13
RafaelGSS pushed a commit that referenced this pull request Nov 18, 2024
This reverts commit 45c6a9e.
PR-URL: #55828Fixes: #55826
Reviewed-By: Gireesh Punathil <gpunathi@in.ibm.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com>
Reviewed-By: Benjamin Gruenbaum <benjamingr@gmail.com>
Reviewed-By: Jason Zhang <xzha4350@gmail.com>
@ruyadorno

Copy link
Copy Markdown
Member

This commit does not land cleanly on v22.x-staging and will need manual backport in case we want it in v22.x.

@ruyadornoruyadorno added the backport-requested-v22.x PRs awaiting manual backport to the v22.x-staging branch. label Nov 27, 2024
@richardlau

Copy link
Copy Markdown
Member

This reverts #55458 which is marked https://github.com/nodejs/node/labels/dont-land-on-v22.x so should be similarly labelled.

@richardlaurichardlau added dont-land-on-v18.x dont-land-on-v22.x PRs that should not land on the v22.x-staging branch and should not be released in v22.x. and removed backport-requested-v22.x PRs awaiting manual backport to the v22.x-staging branch. labels Nov 27, 2024
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

author readyPRs that have at least one approval, no pending requests for changes, and a CI started.c++Issues and PRs that require attention from people who are familiar with C++.commit-queue-squashAdd this label to instruct the Commit Queue to squash all the PR commits into the first one.dont-land-on-v22.xPRs that should not land on the v22.x-staging branch and should not be released in v22.x.lib / srcIssues and PRs related to general changes in the lib or src directory.needs-ciPRs that need a full CI run.revertPRs that revert previously landed PRs.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

23.2 breaks a few packages that use json trough webpack (date-fns)

11 participants

@targos@avivkeller@nodejs-github-bot@ruyadorno@richardlau@benjamingr@lpinca@gireeshpunathil@aduh95@jazelly@jakecastelli