Skip to content

from_http should expect headers as first parameter #103

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

Closed
cumason123 opened this issue Aug 13, 2020 · 0 comments
Closed

from_http should expect headers as first parameter #103

cumason123 opened this issue Aug 13, 2020 · 0 comments

Comments

@cumason123
Copy link
Contributor

Expected Behavior

def from_http(
    headers: typing.Dict[str, str],
    data: typing.Union[str, bytes],
    data_unmarshaller: types.UnmarshallerType = None,
):

This order of parameters would make cloudevents.http.from_http more consistent with the other methods which either expect some header like object first, or return headers followed by data

Actual Behavior

def from_http(
    data: typing.Union[str, bytes],
    headers: typing.Dict[str, str],
    data_unmarshaller: types.UnmarshallerType = None,
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant