-
-
Notifications
You must be signed in to change notification settings - Fork 9.6k
[HttpClient] Copy as curl fixes #46583
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
0a6bd94
to
d8c5f2d
Compare
Hey! I think @Deuchnord has recently worked with this code. Maybe they can help review this? Cheers! Carsonbot |
nicolas-grekas
approved these changes
Jun 9, 2022
d8c5f2d
to
0bc7caf
Compare
Thank you @HypeMC. |
Merged
Fyi, I have noticed that if you use "Copy as curl" when a base URL is used, the copy only contains the relative URL. e.g. $this->httpClient = $httpClient->withOptions([
'base_uri' => 'https://domain.com/api/',
'headers' => [
'Content-Type' => 'application/json',
'Api-Key' => $apiKey,
],
]);
this->httpClient->request('GET', 'foo/bar'); results in:
It should result in:
|
nicolas-grekas
added a commit
that referenced
this pull request
Jun 19, 2022
This PR was merged into the 6.1 branch. Discussion ---------- [HttpClient] Fix Copy as curl with base uri | Q | A | ------------- | --- | Branch? | 6.1 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix #46583 (comment) | License | MIT | Doc PR | - Fixes Copy as curl when `base_uri` is used. Commits ------- 12e40a0 [HttpClient] Fix Copy as curl with base uri
symfony-splitter
pushed a commit
to symfony/http-client
that referenced
this pull request
Jun 19, 2022
This PR was merged into the 6.1 branch. Discussion ---------- [HttpClient] Fix Copy as curl with base uri | Q | A | ------------- | --- | Branch? | 6.1 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix symfony/symfony#46583 (comment) | License | MIT | Doc PR | - Fixes Copy as curl when `base_uri` is used. Commits ------- 12e40a02b1 [HttpClient] Fix Copy as curl with base uri
sadafrangian3
pushed a commit
to sadafrangian3/Dependency-Injection-http-client
that referenced
this pull request
Nov 2, 2022
This PR was merged into the 6.1 branch. Discussion ---------- [HttpClient] Fix Copy as curl with base uri | Q | A | ------------- | --- | Branch? | 6.1 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | Fix symfony/symfony#46583 (comment) | License | MIT | Doc PR | - Fixes Copy as curl when `base_uri` is used. Commits ------- 12e40a02b1 [HttpClient] Fix Copy as curl with base uri
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
The "Copy as curl" button doesn't work as expected in some cases:
query
option: