Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"codeception/codeception": "*@dev",
"codeception/lib-innerbrowser": "*@dev",
"guzzlehttp/guzzle": "^7.4",
"symfony/browser-kit": "^5.4 | ^6.0 | ^7.0"
"symfony/browser-kit": "^5.4 | ^6.0 | ^7.0 | ^8.0"
},
"require-dev": {
"ext-curl": "*",
Expand Down
2 changes: 1 addition & 1 deletion src/Codeception/Lib/Connector/Guzzle.php
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ protected function getAbsoluteUri(string $uri): string
return Uri::mergeUrls((string)$baseUri, $uri);
}

protected function doRequest(object $request)
protected function doRequest(object $request): object
Copy link
Contributor Author

Choose a reason for hiding this comment

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

The return type was added because it was added in symfony/browser-kit v8 as well.

This change could be considered a BC break.
The class is not final and thus users might get a type error if they extended this class and used a different return type.

@TavoNiievez @SamMousa What's your opinion here? Should this change be considered a BC break and thus result in a new major release?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I just noticed that #37 added some return type hints to some methods as well without tagging a new major version. The changes were part of the bugfix release 3.0.2.

Maybe it is okay to accept the BC break of my PR without tagging a new major version?

Copy link
Member

Choose a reason for hiding this comment

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

I'm not sure how major releases in repositories that have automated releases configured actually work.
I probably skipped checking whether this should be released as a minor or major change when I saw that the process was automated.
IMO, we should treat the release of this version as it was labeled as a mistake.
We should stick to semver as much as possible.
But I'll leave the final word to @SamMousa since he's a little more familiar with it.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm not sure how major releases in repositories that have automated releases configured actually work.

According to the docs to add "BREAKING CHANGE:" to the footer of the commit message.

I'm looking forward to the opinion of @SamMousa as well 😃

{
/** @var BrowserKitRequest $request **/
$guzzleRequest = new Psr7Request(
Expand Down
Loading