-
Notifications
You must be signed in to change notification settings - Fork 0
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
add DialOption for adding a header #1
base: master
Are you sure you want to change the base?
Conversation
Awesome. Hope they'll accept the PR eventually. I guess we'd have to update docs and tests there as well. The devs of chromedp are very responsive fyi. |
@@ -30,6 +31,8 @@ type Allocator interface { | |||
// Cancelling the allocator context will already perform this operation, | |||
// so normally there's no need to call Wait directly. | |||
Wait() | |||
|
|||
getDialHeader() http.Header |
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.
Sure we need this private method in the Interface? This is usually for external use, internally we should have access to the real implementation ad not through the interface
@@ -583,6 +592,7 @@ func (a *RemoteAllocator) Allocate(ctx context.Context, opts ...BrowserOption) ( | |||
a.wg.Done() | |||
}() | |||
|
|||
opts = append(opts, WithDialHeaderBrowser(FromContext(ctx).Allocator.getDialHeader())) |
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 see why we need it in the interface
opening this PR just for discussing the changes, not intending to merge this.
Todo: