Closed shadowhand closed 6 years ago
I knew there was going to be something weird about the transition to PSR-15 interfaces, and this is it. 😢 Because of the switch from Http\*\RequestHandlerInterface
the middleware signature is no longer the same. Also a side effect of splitting the packages.
Not sure how else to resolve this, as it really complicates things and makes it hard to cleanly switch. Existing ^1.0
packages have no direct route to upgrade to psr/*
packages without using psr/http-server-handler
.
cc @webimpress @weierophinney
The same than https://github.com/http-interop/http-server-middleware/pull/3#issuecomment-359709112
To me, if we need to create a new major version with breaking changes just for the transition to PSR-15 interface, it's better to simply deprecate this package and warn to change to PSR, instead need to upgrade the package with http-interop v2 and then upgrade again with psr.
hm.... maybe we can do a magic trick with class_alias
?
Not sure, haven't tried it yet, just a crazy idea....
@oscarotero Please note that 1.1.0 has been already released and we should resolve somehow that BC issue. Not sure if revoking the tag is a good idea...
I'm inclined to remove the tag because it's so recent. It's not an ideal solution but I dont see a better one.
@oscarotero it was been pushed, published, and I think it shouldn't be removed. What is going to happen to the project which already updated their dependencies?
I remember one topic when @Ocramius said you cannot never-ever remove the published tag... Can't find it now :/
No need to find a topic, but don't do that.
Once a tag is up and broadcasted to packagist, unless you delete it
immediately (talking about couple minutes) it is there to stay, as somebody
will already be relying on it in, for example, their composer.lock
.
If it was a cockup, then it needs a new patch or major version.
On 23 Jan 2018 10:25, "Michał Bundyra" notifications@github.com wrote:
@oscarotero https://github.com/oscarotero it was been pushed, published, and I think it shouldn't be removed. What is going to happen to the project which already updated their dependencies?
I remember one topic when @Ocramius https://github.com/ocramius said you cannot never-ever remove the published tag... Can't find it now :/
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/http-interop/http-server-handler/pull/13#issuecomment-359730205, or mute the thread https://github.com/notifications/unsubscribe-auth/AAJakG3HPPcaFb7FHntTKjgVWj5P-ZuWks5tNaV1gaJpZM4Ro7Oe .
Ok, I just created this pull request that seems to fix this error using class_alias
as suggested by @webimpress https://github.com/http-interop/http-server-middleware/pull/5
Is this patch necessary now that #5 has been merged and tagged as 1.1.1?
It is not.
it should be updated to v1.1.1 I think .... because v1.1 is broken :(
Refs #12