GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — http: remove useless ternary in test by LockingReal · Pull Request #48481 · nodejs/node

Conversation

@LockingReal

@LockingReal LockingReal commented Jun 17, 2023

Copy link
Copy Markdown
Contributor

The value of check depends on whether the value of headers [': method'] is equal to "GET". The first statement uses the Ternary operation to achieve this. My change uses a simple comparison expression.

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

bricss, Amorim33, and vitorsouzaalmeida reacted with thumbs up emoji
All reactions
  • 👍 3 reactions
@nodejs-github-bot nodejs-github-bot added needs-ci PRs that need a full CI run. test Issues and PRs related to Node.js core tests and test infrastructure. labels Jun 17, 2023
@LockingReal

LockingReal commented Jun 17, 2023

Copy link
Copy Markdown
Contributor Author

@JakobJingleheimer I saw that you have been performing a codereview operation recently. Can you help me check it ~ 😉

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

JakobJingleheimer
JakobJingleheimer approved these changes Jun 17, 2023
View reviewed changes

@JakobJingleheimer JakobJingleheimer left a comment

Copy link
Copy Markdown
Member

There was a problem hiding this comment.

Choose a reason for hiding this comment

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

Nice simplification 🙌

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@JakobJingleheimer

JakobJingleheimer commented Jun 17, 2023

Copy link
Copy Markdown
Member

Note that your commit summary does not follow the required pattern. I think it should be http: remove useless ternary in test (or perhaps test: remove…). I'm not clear on the use of test: now that it's also a core module (previously it was used for changes solely affecting nodes own tests).

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal LockingReal changed the title fix(test): remove useless ternary operator test: remove useless ternary operator Jun 17, 2023
@LockingReal

LockingReal commented Jun 17, 2023

Copy link
Copy Markdown
Contributor Author

Note that your commit summary does not follow the required pattern. I think it should be http: remove useless ternary in test (or perhaps test: remove…). I'm not clear on the use of test: now that it's also a core module (previously it was used for changes solely affecting nodes own tests).

I have corrected it, thank you for your guidance ❤️

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal LockingReal changed the title test: remove useless ternary operator test:remove useless ternary operator Jun 17, 2023
@LockingReal LockingReal changed the title test:remove useless ternary operator http: remove useless ternary in test Jun 17, 2023
@JakobJingleheimer

JakobJingleheimer commented Jun 17, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

It looks like you changed the PR title but not the commit message. The PR summary can be whatever you want, but the first commit is what CI checks (and prevents landing when invalid).

You'll need to run

git commit --amend -m "http: remove useless ternary in test"
git push --force

PS your change to the PR summary is missing a space character between the colon and the next word (test:remove …), which would fail the pattern check (so don't copy+paste your PR title—you don't need to correct the PR title, but you can if you want).

PPS A forced push will invalidate my approval; I'll re-approve after you push ;) I think it will send me a notification; if you do it in the next ~½ hour, I'm around. If I haven't re-approved in like 20 mins, feel free to re-request a review from me.

LockingReal reacted with thumbs up emoji
All reactions
  • 👍 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal
LockingReal force-pushed the fix-test-useless-ternaryoperator branch from c80dcf5 to ac5433e Compare June 17, 2023 15:52
@LockingReal

LockingReal commented Jun 17, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

It looks like you changed the PR title but not the commit message. The PR summary can be whatever you want, but the first commit is what CI checks (and prevents landing when invalid).

You'll need to run

git commit --amend -m "http: remove useless ternary in test"
git push --force

PS your change to the PR summary is missing a space character between the colon and the next word (test:remove …), which would fail the pattern check (so don't copy+paste your PR title—you don't need to correct the PR title, but you can if you want).

Thank you very much. I have learned a lot, and my foundation still needs to be strengthened 😢

JakobJingleheimer reacted with heart emoji
All reactions
  • ❤️ 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@JakobJingleheimer

JakobJingleheimer commented Jun 17, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Everyone starts somewhere 🙌

And thanks for the contribution!

LockingReal reacted with heart emoji
All reactions
  • ❤️ 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

mscdex
mscdex reviewed Jun 17, 2023
View reviewed changes
Comment thread test/parallel/test-http2-endafterheaders.js Resolved

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal
LockingReal force-pushed the fix-test-useless-ternaryoperator branch from ac5433e to 260da3f Compare June 17, 2023 15:59
JakobJingleheimer
JakobJingleheimer approved these changes Jun 17, 2023
View reviewed changes
lpinca
lpinca approved these changes Jun 17, 2023
View reviewed changes
@LockingReal
LockingReal requested a review from mscdex June 17, 2023 19:02
KhafraDev
KhafraDev approved these changes Jun 17, 2023
View reviewed changes
anonrig
anonrig approved these changes Jun 17, 2023
View reviewed changes
tniessen
tniessen approved these changes Jun 17, 2023
View reviewed changes
@LockingReal

LockingReal commented Jun 18, 2023

Copy link
Copy Markdown
Contributor Author

@mscdex Here~~,Can you give me an approval 😉

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

cjihrig
cjihrig approved these changes Jun 18, 2023
View reviewed changes
@aduh95 aduh95 added author ready PRs with CI started, the required approvals, and no outstanding review comments. request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. labels Jun 18, 2023
Ayase-252
Ayase-252 approved these changes Jun 20, 2023
View reviewed changes
@JakobJingleheimer JakobJingleheimer added commit-queue PRs queued for automated landing through the Commit Queue. commit-queue-squash PRs the Commit Queue should land as one squashed commit. labels Jun 20, 2023
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Jun 20, 2023
@nodejs-github-bot

nodejs-github-bot commented Jun 20, 2023

Copy link
Copy Markdown
Collaborator

CI: https://ci.nodejs.org/job/node-test-pull-request/52295/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@targos

targos commented Jun 21, 2023

Copy link
Copy Markdown
Member

Rebasing shouldn't be necessary. If you start a new CI run, Jenkins will rebase by default:
CleanShot 2023-06-21 at 10 19 16

JakobJingleheimer and LockingReal reacted with heart emoji
All reactions
  • ❤️ 2 reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@JakobJingleheimer JakobJingleheimer added request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. and removed needs-ci PRs that need a full CI run. commit-queue-failed PRs whose Commit Queue landing failed and need manual intervention before retrying. labels Jun 21, 2023
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Jun 21, 2023
@nodejs-github-bot

nodejs-github-bot commented Jun 21, 2023

Copy link
Copy Markdown
Collaborator

CI: https://ci.nodejs.org/job/node-test-pull-request/52307/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal
http: remove useless ternary in test
c2bcd0d
@LockingReal
LockingReal force-pushed the fix-test-useless-ternaryoperator branch from 260da3f to c2bcd0d Compare June 21, 2023 18:04
JakobJingleheimer
JakobJingleheimer approved these changes Jun 21, 2023
View reviewed changes
@JakobJingleheimer JakobJingleheimer added the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Jun 21, 2023
@github-actions github-actions Bot removed the request-ci Add this label to start a Jenkins CI on a PR. Only starts once the PR has an approving review. label Jun 21, 2023
@nodejs-github-bot

nodejs-github-bot commented Jun 21, 2023

Copy link
Copy Markdown
Collaborator

CI: https://ci.nodejs.org/job/node-test-pull-request/52327/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal

LockingReal commented Jun 21, 2023

Copy link
Copy Markdown
Contributor Author

I performed a rebase operation ~ 😉❤️

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@JakobJingleheimer

JakobJingleheimer commented Jun 21, 2023

Copy link
Copy Markdown
Member

I think you missed Michaël's comment that it's actually unnecessary (my mistake—I'm usually supplying the PRs, not landing them 😅). I restarted the landing process though 🙂

LockingReal reacted with heart emoji
All reactions
  • ❤️ 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@LockingReal

LockingReal commented Jun 22, 2023 •
edited
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Contributor Author

Commit Queue failed
🤔🤔,I have read some error logs and it doesn't feel like they were caused by changes 😕

again 😢 ... error msg like【tap2junit: error: argument --input/-i: can't open 'cctest.tap': [Errno 2] No such file or directory: 'cctest.tap'】,Should this be a problem with ci itself ?Can we skip them😢

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@nodejs-github-bot

nodejs-github-bot commented Jun 22, 2023

Copy link
Copy Markdown
Collaborator

CI: https://ci.nodejs.org/job/node-test-pull-request/52339/

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@JakobJingleheimer

JakobJingleheimer commented Jun 22, 2023

Copy link
Copy Markdown
Member

Commit Queue failed
🤔🤔,I have read some error logs and it doesn't feel like they were caused by changes 😕

again 😢 ... error msg like【tap2junit: error: argument --input/-i: can't open 'cctest.tap': [Errno 2] No such file or directory: 'cctest.tap'】,Should this be a problem with ci itself ?Can we skip them😢

Did this same error occur multiple runs?

It's very common to have to run CI half a dozen or more times to get a passing suite (we track this, and it's gotten better, but the ones that remain have proven difficult to squash). I checked another PR also currently going through CI, and I did not see this error there. We can't selectively skip tests, however unrelated the failures are :(

I resumed the failing tests, so 🤞

LockingReal reacted with thumbs up emoji LockingReal reacted with rocket emoji
All reactions
  • 👍 1 reaction
  • 🚀 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@JakobJingleheimer JakobJingleheimer added the commit-queue PRs queued for automated landing through the Commit Queue. label Jun 22, 2023
@nodejs-github-bot nodejs-github-bot removed the commit-queue PRs queued for automated landing through the Commit Queue. label Jun 22, 2023
@nodejs-github-bot
nodejs-github-bot merged commit 0d1dfe1 into nodejs:main Jun 22, 2023
@nodejs-github-bot

nodejs-github-bot commented Jun 22, 2023

Copy link
Copy Markdown
Collaborator

Landed in 0d1dfe1

JakobJingleheimer reacted with hooray emoji
All reactions
  • 🎉 1 reaction

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

This was referenced Jun 23, 2023
CI Reliability 2023-06-23 nodejs/reliability#596
Open
CI Reliability 2023-06-24 nodejs/reliability#597
Open
RafaelGSS pushed a commit that referenced this pull request Jul 3, 2023
@LockingReal @RafaelGSS
http: remove useless ternary in test
c6a69e3
PR-URL: #48481
Reviewed-By: Jacob Smith <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Matthew Aitken <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Qingyu Deng <[email protected]>
@RafaelGSS RafaelGSS mentioned this pull request Jul 3, 2023
v20.4.0 proposal #48643
Merged
Ceres6 pushed a commit to Ceres6/node that referenced this pull request Aug 14, 2023
@LockingReal @Ceres6
http: remove useless ternary in test
e240140
PR-URL: nodejs#48481
Reviewed-By: Jacob Smith <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Matthew Aitken <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Qingyu Deng <[email protected]>
Ceres6 pushed a commit to Ceres6/node that referenced this pull request Aug 14, 2023
@LockingReal @Ceres6
http: remove useless ternary in test
adc0e4a
PR-URL: nodejs#48481
Reviewed-By: Jacob Smith <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Matthew Aitken <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Qingyu Deng <[email protected]>
ruyadorno pushed a commit that referenced this pull request Sep 10, 2023
@LockingReal @ruyadorno
http: remove useless ternary in test
54406f1
PR-URL: #48481
Reviewed-By: Jacob Smith <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Matthew Aitken <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Qingyu Deng <[email protected]>
@ruyadorno ruyadorno mentioned this pull request Sep 10, 2023
v18.18.0 proposal #49220
Merged
ruyadorno pushed a commit that referenced this pull request Sep 13, 2023
@LockingReal @ruyadorno
http: remove useless ternary in test
d47eb73
PR-URL: #48481
Reviewed-By: Jacob Smith <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Matthew Aitken <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
Reviewed-By: Tobias Nießen <[email protected]>
Reviewed-By: Colin Ihrig <[email protected]>
Reviewed-By: Qingyu Deng <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@lpinca lpinca lpinca approved these changes
@anonrig anonrig anonrig approved these changes
@cjihrig cjihrig cjihrig approved these changes
@JakobJingleheimer JakobJingleheimer JakobJingleheimer approved these changes
@tniessen tniessen tniessen approved these changes
@Ayase-252 Ayase-252 Ayase-252 approved these changes
@KhafraDev KhafraDev KhafraDev approved these changes
@mscdex mscdex Awaiting requested review from mscdex

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

author ready PRs with CI started, the required approvals, and no outstanding review comments. commit-queue-squash PRs the Commit Queue should land as one squashed commit. test Issues and PRs related to Node.js core tests and test infrastructure.

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

12 participants

@LockingReal @JakobJingleheimer @nodejs-github-bot @targos @mscdex @lpinca @anonrig @cjihrig @tniessen @Ayase-252 @KhafraDev @aduh95
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.