Skip to content
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

Fixed #30453 -- Fixed crash of simple_tag() and inclusion_tag() when function is wrapped. #11334

Merged
merged 1 commit into from May 17, 2019
Merged

Conversation

isidentical
Copy link

Functions unwrapped before the getting fullargspec part.

tests/template_tests/test_library.py Outdated Show resolved Hide resolved
tests/template_tests/test_library.py Outdated Show resolved Hide resolved
Copy link
Member

@charettes charettes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess unwrap could be used instead of __wrapped__ accesses in tests but except for that changes are looking great, thanks!

tests/template_tests/test_library.py Outdated Show resolved Hide resolved
@isidentical
Copy link
Author

Changes made, it is good to be squashed and merged. Thank you for caring the issue on bug tracker.

@isidentical
Copy link
Author

@charettes I'm waiting review.

@charettes
Copy link
Member

@isidentical it will be reviewed and merged eventually, it's currently in the review queue

@isidentical
Copy link
Author

Oh, okay. I didnt know that, sorry.

@felixxm felixxm self-assigned this May 17, 2019
@felixxm felixxm changed the title Fixed #30453 -- Unwrap Functions at Template Library Registration Fixed #30453 -- Fixed crash of simple_tag() and inclusion_tag() when function is wrapped. May 17, 2019
…function is wrapped.

getfullargspec() doesn't work with wrapped functions.
@felixxm
Copy link
Member

felixxm commented May 17, 2019

@isidentical Thanks for this patch 👍 I added similar test for inclusion_tag().

@felixxm felixxm merged commit 5c19274 into django:master May 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
3 participants