Skip to content
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

Support for web servers that send HTTP2 request protocol as HTTP/2.0. Fixes #71 #72

Merged
merged 4 commits into from
Sep 22, 2021
Merged

Conversation

JakeBooher
Copy link
Contributor

@JakeBooher JakeBooher commented Sep 3, 2021

Q A
Documentation no
Bugfix yes
BC Break no
New Feature no
RFC no
QA no

Description

Fixes #71

test/MessageTraitTest.php Show resolved Hide resolved
@Xerkus Xerkus linked an issue Sep 3, 2021 that may be closed by this pull request
Copy link
Member

@Ocramius Ocramius left a comment

Choose a reason for hiding this comment

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

Overall patch OK from my PoV, but needs some adjustments for it to be mergeable :)

test/MessageTraitTest.php Outdated Show resolved Hide resolved
test/MessageTraitTest.php Outdated Show resolved Hide resolved
test/MessageTraitTest.php Outdated Show resolved Hide resolved
@Ocramius Ocramius added this to the 2.8.0 milestone Sep 15, 2021
@Ocramius Ocramius changed the base branch from 2.7.x to 2.8.x September 15, 2021 08:42
@Ocramius Ocramius self-assigned this Sep 17, 2021
@Ocramius
Copy link
Member

Heyo, check the new type additions:

Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Argument 2 of Psr\Http\Message\MessageInterface::withHeader expects array<array-key, string>|string, array{float} provided
Error: Argument 2 of Psr\Http\Message\MessageInterface::withHeader expects array<array-key, string>|string, float provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided
Error: Providers must return iterable<array-key, array<array-key, mixed>>, possibly different array<array-key, mixed> provided

That's because the provider type declarations should have @return array<array<...>> or such :)

@JakeBooher
Copy link
Contributor Author

Honestly have no time or interest in digging down that rabbit hole. Nothing even remotely resembling that exists anywhere in that test class, and I've already had to add return type hinting to every method in the class that didn't have it already. We can patch the original issue ourselves in a fork and include that instead if necessary. Feel free to close this PR and its associated issue if needed.

@Ocramius
Copy link
Member

I mean, if you think that's the responsible way to behave when trying to help on a project 🤷‍♀️

Sure, you can also just use a fork, but it really shows that you care little for being part of OSS, and are just hoping to reap the benefits.

We'll eventually get to fix it ourselves here, at some point.

Coincidentally, this reduces the psalm baseline for that file too.
@Ocramius
Copy link
Member

I've adjusted the added type signatures accordingly - will now roll a release.

Thanks for the initial fix, @JakeBooher.

@Ocramius Ocramius merged commit 2f75ed0 into laminas:2.8.x Sep 22, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Error with HTTP2 and NGINX
4 participants