-
Notifications
You must be signed in to change notification settings - Fork 40
preliminary minimal changes #251
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
base: main
Are you sure you want to change the base?
preliminary minimal changes #251
Conversation
|
Appears to be failing 2 tests for me on MacOS: |
|
Should HTTP::UserAgent be producing valid Messages, or is it up to the users of the library to use it in such a way that it only produces valid messages? Some of the test messages are themselves invalid, so what needs changing will depend on the library's purpose. |
|
Well, that is a good question. What this module really needs, is a maintainer. Would you be willing to take on that role? You apparently have a need to fix things in it :-) |
|
Yes, but I'll need guidance and feedback as I maintain it, if that's okay? Some first questions:
I'll start looking through the other open issues, too. |
|
What would the best channel / medium be for discussing this module? |
|
Either #raku on libera.chat or on Discord |
|
There are enough changes to get things conformant that it would be difficult not to break existing behavior. My plan is to provide alternate classes that can be imported with:
if that is acceptable, though I'm open to other options. |
|
That would make it opt-in, and as such backward compatible. 👍 |
|
I wasn't able to get exporting to work how I was hoping, so instead, the strict versions are just named after the originals with "-Strict" attached. They are subclasses of the originals. The new classes are:
They are all made available with
so that it is easy to just import the strict classes. Behavior when mixing strict and original classes is "undefined". The only change to the original should be the is-chunked multi methods in the HTTP::Message class. One checks the message's own headers, the other takes an arbitrary header object. The following new testcases were added:
I still need to do some testing with the HTTP::UserAgent-Strict class before turning this draft request into a full pull request, but this should be a good place for review and verifying testcases (the new behavior passed for me locally across Windows, Linux, and Mac). |
|
need to fix body-less messages. will comment again once fixed. |
| unit class HTTP::Cookies; | ||
|
|
||
| use HTTP::Cookie; | ||
| use HTTP::Response:auth<zef:raku-community-modules>; |
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.
I think these were qualified like this because there are un-related packages that provide similarly named modules, so I'd be careful about removing that.
|
My apologies. I am now reading through the META6.json and distributions documentation and committed some fixes. Will the version's patch number eventually need to be updated? |
|
Okay, the META6.json should be fixed. I did not change the version number. |
draft pull request with minimal changes to handle eol. also updates is-chunked check to include the case where multiple Transfer Encodings are present (chunked should always be last).
requesting feedback before final changes.