SIGN IN SIGN UP

bpo-41249: Fix postponed annotations for TypedDict (GH-27017) (#27204)

This fixes TypedDict to work with get_type_hints and postponed evaluation of annotations across modules.

This is done by adding the module name to ForwardRef at the time the object is created and using that to resolve the globals during the evaluation.

Co-authored-by: Ken Jin <28750310+Fidget-Spinner@users.noreply.github.com>
(cherry picked from commit 889036f7ef7290ef15b6c3373023f6a35387af0c)

Co-authored-by: Germán Méndez Bravo <german.mb@gmail.com>
M
Miss Islington (bot) committed
480f29f913cff30329e7b425fd6669f83d6d8af8
Parent: efda905
Committed by GitHub <noreply@github.com> on 7/17/2021, 8:48:17 AM