-
Notifications
You must be signed in to change notification settings - Fork 1.2k
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
[EngSys] upgrade dev dependency puppeteer
to ^22.0.0
#28200
Conversation
by running `rush add -m --dev -p puppeteer@^21.0.0`
API change check API changes are not detected in this pull request. |
db722d1
to
3ab2efe
Compare
@@ -216,6 +217,12 @@ export class Recorder { | |||
* - sanitizerOptions - Generated recordings are updated by the "proxy-tool" based on the sanitizer options provided, these santizers are applied only in "record" mode. | |||
*/ | |||
async start(options: RecorderStartOptions): Promise<void> { | |||
if (isBrowser && isPlaybackMode()) { |
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.
Were changes in the recorder related to the upgrade or something found in passing?
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.
Oh I see #28455 (comment)
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.
Yes there's some behavior changes in headers being sent (Accept-Language). I updated sanitizers in recorder and keyvault. However some keyvault tests still failed.
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.
I need to re-record keyvault tests with the new service version some time in the next few days (it's not fully deployed yet). Hopefully just rerecording will fix the problem but if not I will investigate further at that time :)
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.
Also, I am curious what the change to Accept-Language
was. I remember this being a bugbear for me when playing back tests in the past since the locale on my machine was en-CA
instead of en-US
which is what was present in the recordings.
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.
IIRC ideally the header should be ignored by test-proxy. Not sure what was the exact issue that prevented it from happening.
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.
We wanted to do this here Azure/azure-sdk-tools#6152 but didn't in the end, presumably due to engsys objection. @HarshaNalluru do you recall why?
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.
Their resistance was that it might have unintended consequences and is disruptive keeping other languages as well in mind.
From JS perspective, it should be safe, and we need to move forward with this change, so doing it in JS recorder makes sense.
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.
Changes largely look good to me! We chatted about going to 22 but happy to review a separate PR for it (or get it into this one)
puppeteer
to ^21.0.0
puppeteer
to ^22.0.0
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.
LGTM!
@@ -216,6 +217,12 @@ export class Recorder { | |||
* - sanitizerOptions - Generated recordings are updated by the "proxy-tool" based on the sanitizer options provided, these santizers are applied only in "record" mode. | |||
*/ | |||
async start(options: RecorderStartOptions): Promise<void> { | |||
if (isBrowser && isPlaybackMode()) { |
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.
Also, I am curious what the change to Accept-Language
was. I remember this being a bugbear for me when playing back tests in the past since the locale on my machine was en-CA
instead of en-US
which is what was present in the recordings.
@@ -216,6 +217,12 @@ export class Recorder { | |||
* - sanitizerOptions - Generated recordings are updated by the "proxy-tool" based on the sanitizer options provided, these santizers are applied only in "record" mode. | |||
*/ | |||
async start(options: RecorderStartOptions): Promise<void> { | |||
if (isBrowser && isPlaybackMode()) { |
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.
Move this to a new method "preStart()" or similar, and call that here to keep the code clean?
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.
Updated
if (isPlaybackMode()) { | ||
if (!this.httpClient) { | ||
throw new RecorderError("httpClient should be defined in playback mode"); | ||
} | ||
|
||
await setMatcher(Recorder.url, this.httpClient, matcher, this.recordingId, options); | ||
const excludedHeaders = isBrowser | ||
? (options.excludedHeaders ?? []).concat("Accept-Language") |
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.
Can you add a comment explaining why? for future reference
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.
Fixed
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.
💚
by running
rush add -m --dev -p puppeteer@^22.0.0
Resolves #25790