Skip to content

from_http bug needs exception handling/test #116

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 19, 2020 · 0 comments
Closed

from_http bug needs exception handling/test #116

cumason123 opened this issue Aug 19, 2020 · 0 comments

Comments

@cumason123
Copy link
Contributor

Expected Behavior

from cloudevents.http import from_http
from_http({"ce-id":"1", "ce-source":"s", "ce-type": "t"}, "123")

should raise MissingRequiredHeader hinting at specversion

Actual Behavior

raises int object has no attribute get because we don't check instance of raw_ce after json loading here on line 54

Might want an if statement checking the value of raw_ce, and error handlinlg appropriately

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