[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2020-07-08 Thread David Caro
Change by David Caro : -- nosy: +David Caro nosy_count: 4.0 -> 5.0 pull_requests: +20539 pull_request: https://github.com/python/cpython/pull/21392 ___ Python tracker ___ __

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-07 Thread Raymond Hettinger
Raymond Hettinger added the comment: Backported to Py3.1 in r83807 -- status: open -> closed ___ Python tracker ___ ___ Python-bugs-li

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Éric Araujo
Éric Araujo added the comment: Thanks for sticking with this Terrence, it fell off my radar. Thanks Antoine for the commit. -- versions: +Python 3.1 ___ Python tracker ___ _

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Terrence Cole
Terrence Cole added the comment: Awesome! I greatly appreciate the 3.1 backport, as that's what I'm going to be using for the foreseeable future. -- versions: +Python 3.2 -Python 3.1 ___ Python tracker __

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Raymond Hettinger
Raymond Hettinger added the comment: Okay, I'll do it. The intention of wrapper assignments was to wrap all of the standard attributes, so the omission of __annotations__ is a bug. -- assignee: -> rhettinger status: closed -> open versions: +Python 3.1 -Python 3.2 __

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: > This should probably be backported to 3.1 Well, I think this is technically a new feature. If someone wants to backport it, then fine, but I don't think there's much point in doing so. -- ___ Python tracker

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Raymond Hettinger
Raymond Hettinger added the comment: This should probably be backported to 3.1 -- nosy: +rhettinger ___ Python tracker ___ ___ Python-

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Antoine Pitrou
Antoine Pitrou added the comment: The patch is now committed in py3k (r83731). Thanks for your contribution! -- nosy: +pitrou resolution: -> fixed status: open -> closed ___ Python tracker

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-08-04 Thread Terrence Cole
Terrence Cole added the comment: Is there still a chance to get this fix in 3.2? -- ___ Python tracker ___ ___ Python-bugs-list mailin

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-06-16 Thread Terrence Cole
Terrence Cole added the comment: Alright, I've added several tests. I also modified update_wrapper to not copy missing attributes (like __annotations__ on builtin methods) -- see issue 1576241. (I also finally see what you mean with removing 3.3 from the versions list. Sorry I didn't grok

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-06-13 Thread Éric Araujo
Éric Araujo added the comment: Patch looks good to me. Could you add some tests to Lib/test/test_functools.py to check that annotations are really copied? (3.2 is not frozen, adjusting versions) -- stage: -> unit test needed versions: -Python 3.3 ___

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-05-24 Thread Terrence Cole
Terrence Cole added the comment: Thank you for looking it over! The updated patch adds __annotations__ to the documentation where the value of WRAPPER_ASSIGNMENTS is given. I think it would be nice if the documentation showed WRAPPER_ASSIGNMENTS and WRAPPER_UPDATES in their own section, but

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-05-24 Thread Éric Araujo
Éric Araujo added the comment: The patch is fine. Can you check if some doc has to be updated to mention that? (files under Doc and docstrings in functools.py). Removing 3.1 since this is a new feature, and 3.3 since 3.2 is not frozen. -- nosy: +merwok versions: -Python 3.1, Python 3

[issue8814] functools.WRAPPER_ASSIGNMENTS should include __annotations__

2010-05-24 Thread Terrence Cole
New submission from Terrence Cole : __annotations__ should be included in the set of attributes copied by default to a wrapped method. An example of the problem: >>> from functools import wraps >>> def mydecorator(fn): ... @wraps(fn) ... def inner(*args, **kwargs): ... return fn