§ x<ˆj \ãóf—ddlZddlmZmZddlmZmZGd„de¦«ZGd„de¦«Z dS)éN)ÚmessagesÚchecker)ÚTestCaseÚskipcó"—eZdZd„Zd„Zd„Zd„Zd„Zed¦«d„¦«Z d„Z d „Z d „Z d „Z ed¦«d „¦«Zed¦«d „¦«Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Zd„Z ed¦«d „¦«Z!d!„Z"d"„Z#d#„Z$d$„Z%d%„Z&d&„Z'd'„Z(d(„Z)d)„Z*d*„Z+d+„Z,d,„Z-d-„Z.d.„Z/d/„Z0d0„Z1d1„Z2d2„Z3d3„Z4d4„Z5d5„Z6d6„Z7d7„Z8d8„Z9d9„Z:d:„Z;d;„Zd>„Z?d?„Z@d@„ZAdA„ZBdB„ZCdC„ZDdD„ZEdES)FÚTestcóF—| dtj¦«dS)NÚbar©ÚflakesÚmÚ UndefinedName©Úselfs út/builddir/build/BUILD/cloudlinux-venv-1.0.12/venv/lib/python3.11/site-packages/pyflakes/test/test_undefined_names.pyÚtest_undefinedzTest.test_undefineds€Ø � Š �E�1œ?Ñ+Ô+Ð+Ð+Ð+ócó0—| d¦«dS)Nz for a in range(10) if a]©r rs rÚtest_definedInListCompzTest.test_definedInListComp s€Ø � Š Ð1Ñ2Ô2Ð2Ð2Ð2rcóF—| dtj¦«dS)Nz2 [a for a in range(10)] a r rs rÚtest_undefinedInListCompzTest.test_undefinedInListComps.€Ø � Š ð õ”Oñ  %ô %ð %ð %ð %rcó\—| dtjtj¦«dS)zxException names can't be used after the except: block. The exc variable is unused inside the exception handler.zx try: raise ValueError('ve') except ValueError as exc: pass exc N©r r rÚUnusedVariablers rÚtest_undefinedExceptionNamez Test.test_undefinedExceptionNames5€ð � Š ð õ Œ_�aÔ.ñ  0ô 0ð 0ð 0ð 0rcó0—| d¦«dS)z“Locals declared in except: blocks can be used after the block. This shows the example in test_undefinedExceptionName is different.zy try: raise ValueError('ve') except ValueError as exc: e = exc e Nrrs rÚ test_namesDeclaredInExceptBlocksz%Test.test_namesDeclaredInExceptBlocks!ó)€ð � Š ð ñ ô ð ð ð rz5error reporting disabled due to false positives belowcóF—| dtj¦«dS)zÞException names obscure locals, can't be used after. Last line will raise UnboundLocalError on Python 3 after exiting the except: block. Note next two examples for false positives to watch out for.z— exc = 'Original value' try: raise ValueError('ve') except ValueError as exc: pass exc Nr rs rÚ1test_undefinedExceptionNameObscuringLocalVariablez6Test.test_undefinedExceptionNameObscuringLocalVariable.s0€ð � Š ð õ”Oñ %ô %ð %ð %ð %rcó\—| dtjtj¦«dS)z±Exception names are unbound after the `except:` block. Last line will raise UnboundLocalError. The exc variable is unused inside the exception handler. zž try: raise ValueError('ve') except ValueError as exc: pass print(exc) exc = 'Original value' Nrrs rÚ2test_undefinedExceptionNameObscuringLocalVariable2z7Test.test_undefinedExceptionNameObscuringLocalVariable2?s5€ð � Š ð õŒ_�aÔ.ñ 0ô 0ð 0ð 0ð 0rcóF—| dtj¦«dS)z°Exception names obscure locals, can't be used after. Unless. Last line will never raise UnboundLocalError because it's only entered if no exception was raised.z¾ exc = 'Original value' try: raise ValueError('ve') except ValueError as exc: print('exception logged') raise exc N©r r rrs rÚ?test_undefinedExceptionNameObscuringLocalVariableFalsePositive1zDTest.test_undefinedExceptionNameObscuringLocalVariableFalsePositive1Nó1€ð � Š ð õÔ ñ ô ð ð ð rcó0—| d¦«dS)z7The exception name can be deleted in the except: block.z\ try: pass except Exception as exc: del exc Nrrs rÚtest_delExceptionInExceptzTest.test_delExceptionInExcept]ó'€à � Š ð ñ ô ð ð ð rcóF—| dtj¦«dS)zÅException names obscure locals, can't be used after. Unless. Last line will never raise UnboundLocalError because `error` is only falsy if the `except:` block has not been entered.zÿ exc = 'Original value' error = None try: raise ValueError('ve') except ValueError as exc: error = 'exception logged' if error: print(error) else: exc Nr%rs rÚ?test_undefinedExceptionNameObscuringLocalVariableFalsePositive2zDTest.test_undefinedExceptionNameObscuringLocalVariableFalsePositive2fs1€ð � Š ð  õÔ ñ ô ð ð ð rcóF—| dtj¦«dS)zèException names obscure globals, can't be used after. Last line will raise UnboundLocalError because the existence of that exception name creates a local scope placeholder for it, obscuring any globals, etc.zì exc = 'Original value' def func(): try: pass # nothing is raised except ValueError as exc: pass # block never entered, exc stays unbound exc N©r r ÚUndefinedLocalrs rÚ2test_undefinedExceptionNameObscuringGlobalVariablez7Test.test_undefinedExceptionNameObscuringGlobalVariablexs1€ð � Š ð õÔ$ñ &ô &ð &ð &ð &rcóF—| dtj¦«dS)a�Exception names obscure globals, can't be used after. Last line will raise NameError on Python 3 because the name is locally unbound after the `except:` block, even if it's nonlocal. We should issue an error in this case because code only working correctly if an exception isn't raised, is invalid. Unless it's explicitly silenced, see false positives below.a exc = 'Original value' def func(): global exc try: raise ValueError('ve') except ValueError as exc: pass # block never entered, exc stays unbound exc Nr.rs rÚ3test_undefinedExceptionNameObscuringGlobalVariable2z8Test.test_undefinedExceptionNameObscuringGlobalVariable2Šs1€ð � Š ð  õÔ$ñ &ô &ð &ð &ð &rcóF—| dtj¦«dS)z©Exception names obscure globals, can't be used after. Unless. Last line will never raise NameError because it's only entered if no exception was raised.a exc = 'Original value' def func(): global exc try: raise ValueError('ve') except ValueError as exc: print('exception logged') raise exc Nr%rs rÚ@test_undefinedExceptionNameObscuringGlobalVariableFalsePositive1zETest.test_undefinedExceptionNameObscuringGlobalVariableFalsePositive1Ÿs1€ð � Š ð  õÔ ñ ô ð ð ð rcóF—| dtj¦«dS)z¾Exception names obscure globals, can't be used after. Unless. Last line will never raise NameError because `error` is only falsy if the `except:` block has not been entered.aN exc = 'Original value' def func(): global exc error = None try: raise ValueError('ve') except ValueError as exc: error = 'exception logged' if error: print(error) else: exc Nr%rs rÚ@test_undefinedExceptionNameObscuringGlobalVariableFalsePositive2zETest.test_undefinedExceptionNameObscuringGlobalVariableFalsePositive2°s1€ð � Š ð  õÔ ñ ô ð ð ð rcó0—| d¦«dS)NzQ class a: def b(): fu fu = 1 rrs rÚtest_functionsNeedGlobalScopez"Test.test_functionsNeedGlobalScopeÄs'€Ø � Š ð ñ ô ð ð ð rcó0—| d¦«dS)Nz range(10)rrs rÚ test_builtinszTest.test_builtinsÌs€Ø � Š �KÑ Ô Ð Ð Ð rcó0—| d¦«dS)zm C{WindowsError} is sometimes a builtin name, so no warning is emitted for using it. Ú WindowsErrorNrrs rÚtest_builtinWindowsErrorzTest.test_builtinWindowsErrorÏó€ð � Š �NÑ#Ô#Ð#Ð#Ð#rcó0—| d¦«dS)zŸ Use of the C{__annotations__} in module scope should not emit an undefined name warning when version is greater than or equal to 3.6. Ú__annotations__Nrrs rÚtest_moduleAnnotationszTest.test_moduleAnnotationsÖs€ð � Š Ð%Ñ&Ô&Ð&Ð&Ð&rcó0—| d¦«dS)zh Use of the C{__file__} magic global should not emit an undefined name warning. Ú__file__Nrrs rÚtest_magicGlobalsFilezTest.test_magicGlobalsFileÝó€ð � Š �JÑÔÐÐÐrcó0—| d¦«dS)zl Use of the C{__builtins__} magic global should not emit an undefined name warning. Ú __builtins__Nrrs rÚtest_magicGlobalsBuiltinszTest.test_magicGlobalsBuiltinsär>rcó0—| d¦«dS)zh Use of the C{__name__} magic global should not emit an undefined name warning. Ú__name__Nrrs rÚtest_magicGlobalsNamezTest.test_magicGlobalsNameërErcót—| dtj¦«| dd¬¦«dS)z› Use of the C{__path__} magic global should not emit an undefined name warning, if you refer to it from a file called __init__.py. Ú__path__zpackage/__init__.py)ÚfilenameNr rs rÚtest_magicGlobalsPathzTest.test_magicGlobalsPathòs7€ð � Š �J¥¤Ñ0Ô0Ð0Ø � Š �JÐ)>ˆ Ñ?Ô?Ð?Ð?Ð?rcó°—| dtj¦«| d¦«| dtj¦«dS)z‚ Use of the C{__module__} magic builtin should not emit an undefined name warning if used in class scope. Ú __module__z3 class Foo: __module__ zR class Foo: def bar(self): __module__ Nr rs rÚtest_magicModuleInClassScopez!Test.test_magicModuleInClassScopeúsc€ð � Š �L¥!¤/Ñ2Ô2Ð2Ø � Š ð ñ ô ð ð � Š ð õŒ_ñ  ô ð ð ð rcó°—| dtj¦«| d¦«| dtj¦«dS)z„ Use of the C{__qualname__} magic builtin should not emit an undefined name warning if used in class scope. Ú __qualname__z5 class Foo: __qualname__ zT class Foo: def bar(self): __qualname__ Nr rs rÚtest_magicQualnameInClassScopez#Test.test_magicQualnameInClassScope sc€ð � Š �N¥A¤OÑ4Ô4Ð4Ø � Š ð ñ ô ð ð � Š ð õŒ_ñ  ô ð ð ð rcó\—| dtjtj¦«dS)z)Can't find undefined names with import *.zfrom fu import *; barN)r r ÚImportStarUsedÚImportStarUsagers rÚtest_globalImportStarzTest.test_globalImportStars0€à � Š Ð+ÝÔ$¥aÔ&7ñ 9ô 9ð 9ð 9ð 9rcóZ—| d¦«| d¦«dS)zd "global" can make an otherwise undefined name in another function defined. z@ def a(): global fu; fu = 1 def b(): fu zC def c(): bar def b(): global bar; bar = 1 Nrrs rÚtest_definedByGlobalzTest.test_definedByGlobalsF€ð � Š ð ñ ô ð ð � Š ð ñ ô ð ð ð rcó0—| d¦«dS)z5 "global" can accept multiple names. zS def a(): global fu, bar; fu = 1; bar = 2 def b(): fu; bar Nrrs rÚ!test_definedByGlobalMultipleNamesz&Test.test_definedByGlobalMultipleNames-s)€ð � Š ð ñ ô ð ð ð rcóF—| dtj¦«dS)zD A global statement in the global scope is ignored. zB global x def foo(): print(x) Nr rs rÚtest_globalInGlobalScopezTest.test_globalInGlobalScope6s0€ð � Š ð õŒ_ñ  ô ð ð ð rcóF—| dtj¦«dS)z@A global statement does not prevent other names being undefined.zQ def f1(): s def f2(): global m Nr rs rÚtest_global_reset_name_onlyz Test.test_global_reset_name_only@s0€ð � Š ð õ Œ_ñ  ô ð ð ð rÚtodocóF—| dtj¦«dS)z4An unused global statement does not define the name.zQ def f1(): m def f2(): global m Nr rs rÚtest_unused_globalzTest.test_unused_globalLs0€ð � Š ð õ Œ_ñ  ô ð ð ð rcóF—| dtj¦«dS)zDel deletes bindings.za = 1; del a; aNr rs rÚtest_delz Test.test_delWs€à � Š Ð%¥q¤Ñ7Ô7Ð7Ð7Ð7rcó0—| d¦«dS)z%Del a global binding from a function.zY a = 1 def f(): global a del a a Nrrs rÚtest_delGlobalzTest.test_delGlobal[s'€à � Š ð ñ ô ð ð ð rcóF—| dtj¦«dS)zDel an undefined name.zdel aNr rs rÚtest_delUndefinedzTest.test_delUndefinedes€à � Š �G�Qœ_Ñ-Ô-Ð-Ð-Ð-rcó0—| d¦«dS)z8 Ignores conditional bindings deletion. zq context = None test = True if False: del(test) assert(test) Nrrs rÚtest_delConditionalzTest.test_delConditionalis)€ð � Š ð ñ ô ð ð ð rcó0—| d¦«dS)zh Ignored conditional bindings deletion even if they are nested in other blocks. z‘ context = None test = True if False: with context(): del(test) assert(test) Nrrs rÚtest_delConditionalNestedzTest.test_delConditionalNestedus)€ð � Š ð ñ ô ð ð ð rcó0—| d¦«dS)zb Ignore bindings deletion if called inside the body of a while statement. z~ def test(): foo = 'bar' while False: del foo assert(foo) Nrrs rÚ test_delWhilezTest.test_delWhileƒrrcó0—| d¦«dS)zŒ Ignore bindings deletion if called inside the body of a while statement and name is used inside while's test part. z† def _worker(): o = True while o is not True: del o o = False Nrrs rÚtest_delWhileTestUsagezTest.test_delWhileTestUsage�rrcó0—| d¦«dS)zx Ignore bindings deletions if node is part of while's test, even when del is in a nested block. zå context = None def _worker(): o = True while o is not True: while True: with context(): del o o = False Nrrs rÚtest_delWhileNestedzTest.test_delWhileNested�s)€ð � Š ð  ñ ô ð ð ð rcó0—| d¦«dS)z.Global names are available from nested scopes.zO a = 1 def b(): def c(): a Nrrs rÚtest_globalFromNestedScopezTest.test_globalFromNestedScope­r*rcóF—| dtj¦«dS)z~ Test that referencing a local name that shadows a global, before it is defined, generates a warning. z_ a = 1 def fun(): a a = 2 return a Nr.rs rÚ(test_laterRedefinedGlobalFromNestedScopez-Test.test_laterRedefinedGlobalFromNestedScope¶s1€ð � Š ð õ Ô ñ  ô ð ð ð rcóF—| dtj¦«dS)z· Test that referencing a local name in a nested scope that shadows a global declared in an enclosing scope, before it is defined, generates a warning. z´ a = 1 def fun(): global a def fun2(): a a = 2 return a Nr.rs rÚ)test_laterRedefinedGlobalFromNestedScope2z.Test.test_laterRedefinedGlobalFromNestedScope2Ãs1€ð � Š ð õÔ ñ ô ð ð ð rcóF—| dtj¦«dS)a If a name defined in an enclosing scope is shadowed by a local variable and the name is used locally before it is bound, an unbound local warning is emitted, even if there is a class scope between the enclosing scope and the local scope. zÊ def f(): x = 1 class g: def h(self): a = x x = None print(x, a) print(x) Nr.rs rÚ"test_intermediateClassScopeIgnoredz'Test.test_intermediateClassScopeIgnoredÓs1€ð � Š ð  õÔ ñ ô ð ð ð rcó¬—| dtj¦«jd}|jrdnd}| |jd|f¦«dS)a Test that referencing a local name in a nested scope that shadows a variable declared in two different outer scopes before it is defined in the innermost scope generates an UnboundLocal warning which refers to the nearest shadowed name. a def a(): x = 1 def b(): x = 2 # line 5 def c(): x x = 3 return x return x return x rééÚxN)r r r/rÚ withDoctestÚ assertEqualÚ message_args)rÚexcÚexpected_line_nums rÚ$test_doubleNestingReportsClosestNamez)Test.test_doubleNestingReportsClosestNameåsi€ð�kŠkð  õÔ ñ ô ô (¨ô +ˆð"&Ô!1Ð8˜A˜A°qÐà ×Ò˜Ô)¨CÐ1BÐ+CÑDÔDÐDÐDÐDrcóF—| dtj¦«dS)z� Test that referencing a local name in a nested scope that shadows a global, before it is defined, generates a warning. z¸ def fun(): a = 1 def fun2(): a a = 1 return a return a Nr.rs rÚ)test_laterRedefinedGlobalFromNestedScope3z.Test.test_laterRedefinedGlobalFromNestedScope3þr'rcóž—| dtjtjtjtjtj¦«dS)NzÖ def f(seq): a = 0 seq[a] += 1 seq[b] /= 2 c[0] *= 2 a -= 3 d += 4 e[any] = 5 rrs rÚ!test_undefinedAugmentedAssignmentz&Test.test_undefinedAugmentedAssignment sB€Ø � Š ð õ ŒOÝ ŒOÝ ŒO�QÔ-Ý ŒOñ ô ð ð ð rcó0—| d¦«dS)z*Nested classes can access enclosing scope.z³ def f(foo): class C: bar = foo def f(self): return foo return C() f(123).f() Nrrs rÚtest_nestedClasszTest.test_nestedClasss'€à � Š ð  ñ ô ð ð ð rcóF—| dtj¦«dS)z=Free variables in nested classes must bind at class creation.z‚ def f(): class C: bar = foo foo = 456 return foo f() Nr rs rÚtest_badNestedClasszTest.test_badNestedClass,s.€à � Š ð õŒ_ñ ô ð ð ð rcó0—| d¦«dS)z+Star and double-star arg names are defined.z? def f(a, *b, **c): print(a, b, c) Nrrs rÚtest_definedAsStarArgszTest.test_definedAsStarArgs7s'€à � Š ð ñ ô ð ð ð rcó„—| d¦«| d¦«| d¦«dS)z!Star names in unpack are defined.z7 a, *b = range(10) print(a, b) z7 *a, b = range(10) print(a, b) z= a, *b, c = range(10) print(a, b, c) Nrrs rÚtest_definedAsStarUnpackzTest.test_definedAsStarUnpack>sa€à � Š ð ñ ô ð ð � Š ð ñ ô ð ð � Š ð ñ ô ð ð ð rcó„—| d¦«| d¦«| d¦«dS)zS Star names in unpack are used if RHS is not a tuple/list literal. z8 def f(): a, *b = range(10) z: def f(): (*a, b) = range(10) z= def f(): [a, *b, c] = range(10) Nrrs rÚtest_usedAsStarUnpackzTest.test_usedAsStarUnpackMsc€ð � Š ð ñ ô ð ð � Š ð ñ ô ð ð � Š ð ñ ô ð ð ð rcó—| dtjtj¦«| dtjtj¦«| dtjtjtj¦«dS)zQ Star names in unpack are unused if RHS is a tuple/list literal. zC def f(): a, *b = any, all, 4, 2, 'un' zL def f(): (*a, b) = [bool, int, float, complex] zD def f(): [a, *b, c] = 9, 8, 7, 6, 5, 4 Nr%rs rÚtest_unusedAsStarUnpackzTest.test_unusedAsStarUnpack^s”€ð � Š ð õÔ �qÔ/ñ 1ô 1ð 1ð � Š ð õÔ �qÔ/ñ 1ô 1ð 1ð � Š ð õÔ �qÔ/µÔ1Añ Cô Cð Cð Cð CrcóZ—| d¦«| d¦«dS)z#Keyword-only arg names are defined.z> def f(*, a, b=None): print(a, b) z\ import default_b def f(*, a, b=default_b): print(a, b) Nrrs rÚtest_keywordOnlyArgszTest.test_keywordOnlyArgsosD€à � Š ð ñ ô ð ð � Š ð ñ ô ð ð ð rcóF—| dtj¦«dS)zTypo in kwonly name.zC def f(*, a, b=default_c): print(a, b) Nr rs rÚtest_keywordOnlyArgsUndefinedz"Test.test_keywordOnlyArgsUndefined|s.€à � Š ð õŒ_ñ ô ð ð ð rcóZ—| d¦«| d¦«dS)zUndefined annotations.z¦ from abc import note1, note2, note3, note4, note5 def func(a: note1, *args: note2, b: note3=12, **kw: note4) -> note5: pass zk def func(): d = e = 42 def func(a: {1, d}) -> (lambda c: e): pass Nrrs rÚtest_annotationUndefinedzTest.test_annotationUndefinedƒsD€à � Š ð ñ ô ð ð � Š ð ñ ô ð ð ð rcó0—| d¦«dS)NzR from abc import ABCMeta class A(metaclass=ABCMeta): pass rrs rÚtest_metaClassUndefinedzTest.test_metaClassUndefined‘s'€Ø � Š ð ñ ô ð ð ð rcóZ—| d¦«| d¦«dS)zc Using the loop variable of a generator expression results in no warnings. z(a for a in [1, 2, 3] if a)z-(b for b in (a for a in [1, 2, 3] if a) if b)Nrrs rÚtest_definedInGenExpzTest.test_definedInGenExp—s0€ð � Š Ð1Ñ2Ô2Ð2à � Š ÐCÑDÔDÐDÐDÐDrcó†—| dtj¦«| dtj¦«dS)z} The loop variables of generator expressions nested together are not defined in the other generator. z-(b for b in (a for a in [1, 2, 3] if b) if b)z-(b for b in (a for a in [1, 2, 3] if a) if a)Nr rs rÚtest_undefinedInGenExpNestedz!Test.test_undefinedInGenExpNested sL€ð � Š ÐCÝ”Oñ %ô %ð %ð � Š ÐCÝ”Oñ %ô %ð %ð %ð %rcóÚ—| d¦«| d¦«| dtj¦«| dtj¦«dS)zr Some compatibility code checks explicitly for NameError. It should not trigger warnings. zc try: socket_map except NameError: socket_map = {} z¡ try: _memoryview.contiguous except (NameError, AttributeError): raise RuntimeError("Python >= 3.3 is required") zY try: socket_map except: socket_map = {} zc try: socket_map except Exception: socket_map = {} Nr rs rÚtest_undefinedWithErrorHandlerz#Test.test_undefinedWithErrorHandler«sŽ€ð � Š ð ñ ô ð ð � Š ð ñ ô ð ð � Š ð õ Œ_ñ  ô ð ð � Š ð õ Œ_ñ  ô ð ð ð rcóZ—| d¦«| d¦«dS)zT Defined name for generator expressions and dict/set comprehension. z  class A: T = range(10) Z = (x for x in T) L = [x for x in T] B = dict((i, str(i)) for i in T) zu class A: T = range(10) X = {x for x in T} Y = {x:x for x in T} Nrrs rÚtest_definedInClasszTest.test_definedInClassÊsF€ð � Š ð ñ ô ð ð � Š ð ñ ô ð ð ð rcó0—| d¦«dS)z9Defined name for nested generator expressions in a class.za class A: T = range(10) Z = (x for x in (a for a in T)) Nrrs rÚtest_definedInClassNestedzTest.test_definedInClassNestedßr*rcóÆ—| dtj¦«| dtj¦«| dtj¦«dS)zP The loop variable is defined after the expression is computed. z9 for i in range(i): print(i) z( [42 for i in range(i)] z( (42 for i in range(i)) Nr rs rÚtest_undefinedInLoopzTest.test_undefinedInLoopèst€ð � Š ð õŒ_ñ ô ð ð � Š ð å Œ_ñ ô ð ð � Š ð å Œ_ñ ô ð ð ð rcó0—| d¦«dS)zi Defined name referenced from a lambda function within a dict/set comprehension. z4 {lambda: id(x) for x in range(10)} Nrrs rÚ/test_definedFromLambdaInDictionaryComprehensionz4Test.test_definedFromLambdaInDictionaryComprehension÷ó)€ð � Š ð ñ ô ð ð ð rcó0—| d¦«dS)zg Defined name referenced from a lambda function within a generator expression. z7 any(lambda: id(x) for x in range(10)) Nrrs rÚ!test_definedFromLambdaInGeneratorz&Test.test_definedFromLambdaInGeneratorr­rcóF—| dtj¦«dS)zk Undefined name referenced from a lambda function within a dict/set comprehension. z4 {lambda: id(y) for x in range(10)} Nr rs rÚ1test_undefinedFromLambdaInDictionaryComprehensionz6Test.test_undefinedFromLambdaInDictionaryComprehension ó.€ð � Š ð å Œ_ñ ô ð ð ð rcóF—| dtj¦«dS)zi Undefined name referenced from a lambda function within a generator expression. z7 any(lambda: id(y) for x in range(10)) Nr rs rÚ'test_undefinedFromLambdaInComprehensionz,Test.test_undefinedFromLambdaInComprehensionr²rcó4—d}| |¦«dS)Nzž class Test(object): def __init__(self): print(__class__.__name__) self.x = 1 t = Test() r)rÚcodes rÚtest_dunderClasszTest.test_dunderClasss#€ð ˆð � Š �DÑÔÐÐÐrN)FrJrQrTrrrrrrr!r#r&r)r,r0r2r4r6r8r:r=rArDrHrKrOrRrUrYr[r]r_rardrfrhrjrlrnrprrrtrvrxrzr|r†rˆrŠrŒrŽr�r’r”r–r˜ršrœržr r¢r¤r¦r¨rªr¬r¯r±r´r·©rrrrs]€€€€€ð,ð,ð,ð3ð3ð3ð%ð%ð%ð 0ð 0ð 0ð  ð  ð  ð €TÐ AÑBÔBð%ð%ñCÔBð%ð 0ð 0ð 0ð ð ð ð ð ð ðððð$ €TÐ AÑBÔBð&ð&ñCÔBð&ð" €TÐ AÑBÔBð&ð&ñCÔBð&ð(ððð"ððð( ð ð ð!ð!ð!ð$ð$ð$ð'ð'ð'ð ð ð ð$ð$ð$ð ð ð ð@ð@ð@ðððð ððð 9ð9ð9ð  ð  ð  ð ð ð ðððð ð ð ð €Tˆ&�\„\ððñ„\ðð8ð8ð8ð ð ð ð.ð.ð.ð  ð  ð  ð  ð  ð  ð  ð  ð  ð  ð  ð  ð ð ð ð  ð ð ð ð ð ðððð ððð$EðEðEð2 ð ð ð ð ð ð$  ð  ð  ð ð ð ð ð ð ð  ð  ð  ð ð ð ð"CðCðCð"  ð  ð  ðððð  ð  ð  ð ð ð ð EðEðEð %ð %ð %ðððð> ð ð ð* ð ð ð ð ð ð ð ð ð ð ð ððððððð ð ð ð ð rrcó—eZdZdZd„ZdS)Ú NameTestsz6 Tests for some extra cases of name handling. cóø—tjd¦«}tjd¦«}t ¦«|jdjd_| ttj ||¬¦«dS)zj A Name node with an unrecognized context results in a RuntimeError being raised. zx = 10r)Ú file_tokensN) ÚastÚparserÚ make_tokensÚobjectÚbodyÚtargetsÚctxÚ assertRaisesÚ RuntimeErrorÚChecker)rÚtreer¼s rÚtest_impossibleContextz NameTests.test_impossibleContext+sb€õ Œy˜Ñ"Ô"ˆÝÔ)¨(Ñ3Ô3ˆ å&,¡h¤hˆŒ �!Œ Ô˜QÔÔ#Ø ×Ò�,­¬¸È;ÐÑWÔWÐWÐWÐWrN)rJrQrTÚ__doc__rÈr¸rrrºrº's2€€€€€ððð Xð Xð Xð Xð Xrrº) r½Úpyflakesrr rÚpyflakes.test.harnessrrrrºr¸rrúrÌs¯ðØ € € € à+Ð+Ð+Ð+Ð+Ð+Ð+Ð+Ø0Ð0Ð0Ð0Ð0Ð0Ð0Ð0ð] ð] ð] ð] ð] ˆ8ñ] ô] ð] ð@ Xð Xð Xð Xð X�ñ Xô Xð Xð Xð Xr