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 http-message 2.0 as well as 1.0. #1907
Conversation
See this comment, make this a draft and propose only when [you are] certain [that] |
Yeah, that's what I started on - I initially thought the solution was going to be simpler since this one isn't overriding constructors; apologies for the premature PR. On the plus side, it hopefully provides visibility that something is happening and an opportunity for testers to jump in. May I ask what might seem like a silly question from your perspective: why are you supporting such old versions of PHP? |
There are people still using them. |
Ok, and I can see there's no point going further with that question :) |
Maybe not even with this PR, over the last months, I've become much closer to releasing the next major version with older PHP versions dropped. |
Should I bother continuing then? I have plenty of other things I could spend the time on. |
Depends on if and how fast you need this, I'd give the drop a few months (which is quite fast given how the library is evolving) |
Ok. We have people wanting to use our Drupal module with D10 today, so I'll keep going. |
I'll create the repository for the module and give you access, so you can work under mpdf namespace directly. |
Oh, that would be great; thanks. |
2804908
to
abb6203
Compare
@NigelCunningham Can you please mark this as a draft until there is actually anything to review? I'm getting notified for every commit. |
abb6203
to
03a9840
Compare
Ok, I've updated this PR and pushed to the http-message-aware-trait repo, having tested on Ubuntu with PHP 5.6, 7.0, 7.1, 7.2, 7.3, 7.4, 8.0, 8.1, 8.2. It all works locally and I've also tested using the repository on github. |
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.
Looks on a good path, just maybe, seeing that all the content of the classes is removed, wouldn't it be better to move whole classes to the package insteadof using a trait in an empty class? of course the package would then have to be renamed.
d18273f
to
950270b
Compare
Signed-off-by: Nigel Cunningham <nigel@technocrat.com.au>
950270b
to
f19bd1a
Compare
I believe all issues have been resolved now. I've renamed the repo contents to mpdf/psr-http-message-shim. If you're able to rename the repo as well, everything should just work. I've been testing with the following addition to the mpdf/mpdf composer.json:
... and have successfully checked tests pass with PHP 5.6, 7.0 through 7.4 inclusive and 8.0 and 8.1. |
Great job, thanks! |
You're welcome! |
Could I just query as to when you're planning another release? I can make the Drupal module that depends on this use the development branch for now, but it would be better to avoid that if I can :) |
Shortly. I just need to resolve one seemingly minor issue elsewhere to release 8.2.0 |
Great; thanks! |
Released. |
The 2.0 release only differs in adding return type hints and removing the strict types declarations. Either version should be usable with mpdf.
This update is also needed for projects that use pdf, where other dependencies already require http-message 2. We are seeking this need in the Drupal printable / pdf_api use of mpdf; the lack of http-message 2 support is preventing an update to Drupal 10.1 (https://www.drupal.org/project/printable/issues/3374990).