Module Expr Str Import alias ImportFrom alias alias alias alias identifier ImportFrom alias identifier alias ImportFrom alias alias alias alias alias alias ImportFrom alias ImportFrom alias alias alias alias alias alias alias alias ImportFrom alias ImportFrom alias identifier Import alias Assign NameStore ListLoad Str Str Str Str Assign NameStore Call AttributeLoad NameLoad attr Expr Str FunctionDef arguments args NameParam defaults body Expr Str If AttributeLoad NameLoad attr body TryExcept body Return SubscriptLoad NameLoad Index AttributeLoad NameLoad attr handlers ExceptHandler type NameLoad body Pass Return NameLoad decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam defaults body Expr Str For NameStore Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Expr Str Return Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list NameLoad Call AttributeLoad NameLoad attr Str FunctionDef arguments args NameParam NameParam defaults body Expr Str Return Call NameLoad NameLoad decorator_list NameLoad decorator_list Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr Str ClassDef bases NameLoad body Expr Str Assign NameStore NameLoad FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Dict Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad If BoolOpAnd UnaryOpNot NameLoad NameLoad body Raise Call AttributeLoad NameLoad attr Str If AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr If AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return BoolOpAnd CompareIsNot AttributeLoad NameLoad attr NameLoad CompareIs AttributeLoad NameLoad attr NameLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad Str body If CompareIs AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr Str orelse If CompareIs AttributeLoad NameLoad attr NameLoad body If UnaryOpNot NameLoad body Raise Call AttributeLoad NameLoad attr Str orelse If CompareIs AttributeLoad NameLoad attr NameLoad body If BoolOpAnd UnaryOpNot NameLoad UnaryOpNot NameLoad body If AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr BinOpMod Str AttributeLoad NameLoad attr orelse If UnaryOpNot NameLoad body Raise Call AttributeLoad NameLoad attr Str orelse If CompareIs AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return BoolOpOr AttributeLoad NameLoad attr UnaryOpNot AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad kwarg body Expr Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Return Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Call AttributeLoad NameLoad attr Return Call NameLoad AttributeLoad NameLoad attr NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body If CompareIs AttributeLoad NameLoad attr NameLoad body Return TupleLoad NameLoad orelse If CompareIs AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str NameLoad Return BinOpAdd TupleLoad NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body If UnaryOpNot AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr Return If UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Assert AttributeLoad NameLoad attr For NameStore Call AttributeLoad Call NameLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If AttributeLoad NameLoad attr body Delete AttributeDel NameLoad attr For TupleStore NameStore TupleStore NameStore NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad For NameStore Call AttributeLoad Call NameLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr body If AttributeLoad NameLoad attr body Delete AttributeDel NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad keyword NameLoad Assert UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr For NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr body If BoolOpOr UnaryOpNot NameLoad AttributeLoad NameLoad attr CompareIn NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr decorator_list FunctionDef arguments args NameParam defaults body Assert AttributeLoad NameLoad attr If BoolOpAnd UnaryOpNot AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr body For NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr For NameStore AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr orelse If AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr If CompareIn NameLoad AttributeLoad NameLoad attr body If NameLoad body Expr Call AttributeLoad NameLoad attr Str Return SubscriptLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad Index Num If AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Return NameLoad orelse If Call NameLoad NameLoad AttributeLoad NameLoad attr body Assign NameStore NameLoad If CompareIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Str orelse Assign NameStore Call AttributeLoad NameLoad attr If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad If BoolOpAnd AttributeLoad AttributeLoad NameLoad attr attr CompareIs AttributeLoad NameLoad attr NameLoad body Assign NameStore Call AttributeLoad NameLoad attr orelse If AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr orelse Assign NameStore Call AttributeLoad NameLoad attr Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad SubscriptStore AttributeLoad NameLoad attr Index AttributeLoad NameLoad attr TupleLoad NameLoad NameLoad CompareIsNot NameLoad NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body If BoolOpOr CompareIsNot AttributeLoad NameLoad attr NameLoad UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body Raise Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr If BoolOpOr CompareIs AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr If CompareIsNot NameLoad NameLoad body For NameStore Call AttributeLoad NameLoad attr keyword NameLoad body Expr Call AttributeLoad NameLoad attr If UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body For NameStore Call NameLoad Num body If Call AttributeLoad AttributeLoad NameLoad attr attr body Break Expr Call AttributeLoad AttributeLoad NameLoad attr attr orelse Raise Call AttributeLoad NameLoad attr Str If BoolOpAnd CompareIs AttributeLoad NameLoad attr NameLoad AttributeLoad AttributeLoad NameLoad attr attr body TryExcept body For NameStore Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad SubscriptLoad NameLoad Index Num attr handlers ExceptHandler body With Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr keyword NameLoad If CompareIsNot AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr If BoolOpOr CompareIs AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr body For NameStore Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad SubscriptLoad NameLoad Index Num attr Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr If AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr If CompareIsNot NameLoad NameLoad body For NameStore Call AttributeLoad NameLoad attr keyword NameLoad body Expr Call AttributeLoad NameLoad attr Assign NameStore NameLoad If CompareIn AttributeLoad NameLoad attr TupleLoad NameLoad NameLoad body For NameStore Call AttributeLoad NameLoad attr body If BoolOpOr CompareIs AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad Assign NameStore NameLoad Break orelse Assign AttributeStore NameLoad attr NameLoad Assign NameStore AttributeLoad NameLoad attr If BoolOpAnd AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr If BoolOpAnd AttributeLoad NameLoad attr NameLoad body Assign AttributeStore AttributeLoad NameLoad attr attr SubscriptLoad Call AttributeLoad NameLoad attr Index Num Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body For NameStore Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad SubscriptLoad NameLoad Index Num attr If AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Assign AttributeStore AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr If CompareIs AttributeLoad NameLoad attr NameLoad body For TupleStore NameStore NameStore NameStore Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr body If NameLoad body Expr Call AttributeLoad NameLoad attr If NameLoad body Expr Call AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad If AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad NameLoad attr NameLoad If CompareIs AttributeLoad NameLoad attr NameLoad body If UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad If CompareIs AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Return If CompareIs NameLoad NameLoad body TryExcept body Expr Call AttributeLoad NameLoad attr handlers ExceptHandler body With Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore TupleLoad Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str Str FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad AttributeLoad NameLoad attr body Expr Str If NameLoad body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr Str Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Dict Assign AttributeStore NameLoad attr Dict Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Dict Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad If NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If NameLoad body For NameStore Call AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad If CompareIsNot NameLoad NameLoad body For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body Assign NameStore Call NameLoad NameLoad If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad orelse If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad orelse Assert NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Assign SubscriptStore NameLoad Index AttributeLoad NameLoad attr NameLoad decorator_list Assign NameStore NameLoad Assign NameStore NameLoad Expr Str FunctionDef arguments args NameParam defaults body Expr Str Return Dict decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str If CompareIsNot AttributeLoad NameLoad attr NameLoad body If BoolOpOr NameLoad NameLoad body Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr keyword NameLoad orelse Raise Call AttributeLoad NameLoad attr Str orelse Assign AttributeStore NameLoad attr Call NameLoad NameLoad keyword NameLoad Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr keyword NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareIs AttributeLoad NameLoad attr NameLoad body Pass orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareIs AttributeLoad NameLoad attr NameLoad body If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr orelse Raise Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareIs AttributeLoad NameLoad attr NameLoad body If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr orelse Raise Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad NameLoad NameLoad kwarg body Expr Str If CompareIs NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad NameLoad Return Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad kwarg body If CompareIsNot AttributeLoad NameLoad attr NameLoad body Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad orelse Assign NameStore Call AttributeLoad NameLoad attr NameLoad If NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad kwarg body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad If CompareIs NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad NameLoad Return Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad attr NameLoad BoolOpOr NameLoad Dict decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad kwarg body Expr Str Return Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword NameLoad keyword NameLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr keyword NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr If CompareIsNot AttributeLoad NameLoad attr NameLoad body For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str For NameStore BinOpAdd Call AttributeLoad AttributeLoad NameLoad attr attr Call NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Dict Assign AttributeStore NameLoad attr Dict decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str If Call NameLoad NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad Assign SubscriptStore AttributeLoad NameLoad attr Index AttributeLoad NameLoad attr NameLoad For NameStore AttributeLoad NameLoad attr body Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str If CompareIsIs NameLoad NameLoad NameLoad body If AttributeLoad NameLoad attr body Return AttributeLoad NameLoad attr orelse Raise Call AttributeLoad NameLoad attr Str Assign NameStore BoolOpOr BoolOpAnd CompareIsNot NameLoad NameLoad Call NameLoad NameLoad NameLoad If AttributeLoad NameLoad attr body If NameLoad body If CompareIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Return SubscriptLoad AttributeLoad NameLoad attr Index AttributeLoad NameLoad attr orelse If CompareIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Return SubscriptLoad AttributeLoad NameLoad attr Index AttributeLoad NameLoad attr If CompareIsNot NameLoad NameLoad body For NameStore Call AttributeLoad NameLoad attr NameLoad keyword NameLoad body If CompareIn NameLoad AttributeLoad NameLoad attr body Return SubscriptLoad AttributeLoad NameLoad attr Index NameLoad If AttributeLoad NameLoad attr body Return AttributeLoad NameLoad attr If BoolOpAnd Call NameLoad NameLoad AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr body Return AttributeLoad NameLoad attr If BoolOpAnd NameLoad AttributeLoad AttributeLoad NameLoad attr attr body Return AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore ListLoad If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr BinOpMod Str NameLoad If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr Str Raise Call AttributeLoad NameLoad attr BinOpMod Str Call AttributeLoad Str attr NameLoad decorator_list FunctionDef arguments args NameParam defaults vararg kwarg body Expr Str Return Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad Expr Yield NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list NameLoad AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body If BoolOpAnd AttributeLoad NameLoad attr UnaryOpNot AttributeLoad NameLoad attr body TryExcept body Expr Call AttributeLoad NameLoad attr handlers ExceptHandler type AttributeLoad NameLoad attr name NameStore body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad If CompareIs Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Call NameLoad NameLoad AttributeLoad NameLoad attr keyword NameLoad keyword NameLoad keyword NameLoad NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr NameLoad If NameLoad body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad orelse Assign NameStore Call NameLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad For TupleStore NameStore NameStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr orelse If CompareIn NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list Call AttributeLoad NameLoad attr Str Str FunctionDef arguments args NameParam NameParam defaults body Expr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad If CompareIsNot AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad Assign NameStore Call NameLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str NameLoad Expr Call AttributeLoad NameLoad attr NameLoad For TupleStore NameStore NameStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareIn NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr orelse If Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr orelse If AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body For NameStore NameLoad body Assign NameStore Call NameLoad NameLoad Assign NameStore Call AttributeLoad NameLoad attr If CompareIsNot NameLoad NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad If BoolOpOr BoolOpAnd Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num UnaryOpNot AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad If CompareIs AttributeLoad NameLoad attr NameLoad body Assign AttributeStore NameLoad attr NameLoad orelse If CompareNotEq AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If CompareIn NameLoad AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore SubscriptLoad SubscriptLoad AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad Index Num orelse Assign NameStore AttributeLoad NameLoad attr Assign SubscriptStore AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad TupleLoad NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr GeneratorExp TupleLoad NameLoad AttributeLoad NameLoad attr comprehension NameStore NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad For NameStore Call AttributeLoad Call NameLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If BoolOpAnd AttributeLoad NameLoad attr AttributeLoad NameLoad attr body For NameStore NameLoad body If CompareIn NameLoad AttributeLoad NameLoad attr body Assign SubscriptStore AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad NameLoad orelse Assign SubscriptStore AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body For NameStore NameLoad body If BoolOpAnd AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign SubscriptStore AttributeLoad AttributeLoad NameLoad attr attr Index NameLoad NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If BoolOpAnd NameLoad AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad For TupleStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr Str NameLoad keyword AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad If CompareIs AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad If CompareIn NameLoad AttributeLoad NameLoad attr body Return Expr Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign NameStore Call NameLoad Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Str NameLoad Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad Call AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad For TupleStore NameStore NameStore NameStore NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Str Assign NameStore Dict If NameLoad body Expr Call AttributeLoad NameLoad attr Expr Call NameLoad NameLoad Assign NameStore AttributeLoad NameLoad attr TryFinally body Assign AttributeStore NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad keyword NameLoad finalbody Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Assign NameStore Call NameLoad NameLoad If CompareIn NameLoad NameLoad body Return SubscriptLoad NameLoad Index NameLoad Assign NameStore NameLoad Assign NameStore AttributeLoad NameLoad attr If CompareIs NameLoad NameLoad body If UnaryOpNot NameLoad body Raise Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad If CompareIn NameLoad AttributeLoad NameLoad attr body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index NameLoad orelse If UnaryOpNot NameLoad body If AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Str Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameLoad orelse If BoolOpOr UnaryOpNot Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num BoolOpAnd AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr attr SubscriptLoad NameLoad Index Num orelse Assign NameStore NameLoad If CompareIs NameLoad NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore NameLoad Expr Call AttributeLoad NameLoad attr NameLoad orelse Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign SubscriptStore NameLoad Index NameLoad NameLoad If CompareIsNot NameLoad NameLoad body If CompareIsNot AttributeLoad NameLoad attr NameLoad body Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr If BoolOpAnd CompareIsNot NameLoad AttributeLoad NameLoad attr CompareIsNot NameLoad AttributeLoad NameLoad attr CompareNotEq NameLoad NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str TupleLoad NameLoad Call NameLoad NameLoad NameLoad Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr For NameStore AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad If UnaryOpNot NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr If NameLoad body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareIsNot AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad If CompareNotIn NameLoad AttributeLoad NameLoad attr body Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body If BoolOpAnd Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad CompareNotIn NameLoad AttributeLoad NameLoad attr body Return If CompareIs AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad If AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr BinOpMod Str Call NameLoad NameLoad Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad If NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareIs AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad orelse Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareIn NameLoad AttributeLoad NameLoad attr body Return If CompareIs AttributeLoad NameLoad attr NameLoad body Return Expr Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad Call AttributeLoad NameLoad attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If BoolOpAnd CompareNotEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body If BoolOpAnd AttributeLoad NameLoad attr CompareIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str TupleLoad Call NameLoad NameLoad AttributeLoad NameLoad attr If BoolOpAnd AttributeLoad NameLoad attr CompareIsNot AttributeLoad NameLoad attr AttributeLoad NameLoad attr CompareIn AttributeLoad NameLoad attr NameLoad body Raise Call AttributeLoad NameLoad attr BinOpMod Str TupleLoad Call NameLoad NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareNotEq AttributeLoad NameLoad attr AttributeLoad NameLoad attr body If BoolOpAnd NameLoad AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr If BoolOpAnd AttributeLoad NameLoad attr CompareIs AttributeLoad NameLoad attr NameLoad body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr If AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad Return Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call NameLoad BinOpAdd Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Return BoolOpOr CompareIn NameLoad AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Str If Call AttributeLoad NameLoad attr body Return TryFinally body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad finalbody Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Call AttributeLoad NameLoad attr BinOpMod Str NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return BoolOpAnd UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr UnaryOpNot AttributeLoad NameLoad attr UnaryOpNot AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Assign NameStore AttributeLoad NameLoad attr If BoolOpAnd UnaryOpNot NameLoad UnaryOpNot AttributeLoad NameLoad attr UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Return Assign NameStore Call NameLoad NameLoad If AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign NameStore Call NameLoad AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad Call NameLoad NameLoad attr NameLoad If NameLoad body Assign NameStore Call NameLoad For NameStore NameLoad body TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr NameLoad orelse Assign NameStore NameLoad Assign NameStore Call NameLoad If NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr NameLoad attr NameLoad orelse Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr NameLoad For NameStore NameLoad body Assign NameStore BoolOpAnd Call AttributeLoad Call NameLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad If NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr NameLoad attr NameLoad orelse Assign NameStore Call AttributeLoad NameLoad attr NameLoad For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad keyword NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Return Assign AttributeStore NameLoad attr NameStore Call AttributeLoad NameLoad attr keyword NameLoad TryExcept body Assign AttributeStore NameLoad attr NameLoad TryFinally body Expr Call AttributeLoad NameLoad attr finalbody Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr If BoolOpAnd UnaryOpNot NameLoad AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore Call NameLoad AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad AttributeLoad NameLoad attr attr ListComp TupleLoad NameLoad AttributeLoad NameLoad attr comprehension NameStore AttributeLoad AttributeLoad NameLoad attr attr keyword AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr BinOpMod Str NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr handlers ExceptHandler body With Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Assign NameStore Call NameLoad NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Return NameLoad Assign NameStore AttributeLoad NameLoad attr For NameStore AttributeLoad AttributeLoad NameLoad attr attr body If BoolOpOr BoolOpAnd UnaryOpNot NameLoad Call NameLoad AttributeLoad NameLoad attr Str UnaryOpNot Call NameLoad AttributeLoad NameLoad attr Str body Continue Assign TupleStore NameStore NameStore NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad keyword AttributeLoad NameLoad attr If BoolOpOr NameLoad NameLoad body Return NameLoad orelse Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return BoolOpAnd AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr decorator_list NameLoad Assign NameStore NameLoad Expr Str FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr ListComp Call AttributeLoad NameLoad attr comprehension NameStore AttributeLoad NameLoad attr CompareNotIn NameLoad AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad NameLoad attr Call NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list NameLoad decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad NameLoad NameLoad NameLoad kwarg body Expr Str Assign SubscriptStore NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str NameLoad Assign SubscriptStore NameLoad Index Str NameLoad If CompareIsNot NameLoad NameLoad body Assign SubscriptStore NameLoad Index Str NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Call NameLoad AttributeLoad NameLoad attr TupleLoad NameLoad Dict decorator_list FunctionDef arguments args NameParam defaults kwarg body Expr Str For TupleStore NameStore NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body If BoolOpAnd CompareEq NameLoad Str CompareIn Str NameLoad body Assign NameStore Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Str Assign SubscriptStore NameLoad Index Str NameLoad orelse Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Return Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults kwarg body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return BinOpMod Str TupleLoad AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad Str attr GeneratorExp BinOpMod Str TupleLoad NameLoad NameLoad comprehension TupleStore NameStore NameStore Call AttributeLoad AttributeLoad NameLoad attr attr decorator_list decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad AttributeLoad NameLoad attr attr If AttributeLoad NameLoad attr body Delete AttributeDel NameLoad attr If AttributeLoad NameLoad attr body Delete AttributeDel NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr NameLoad If BoolOpOr AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr Str Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad If AttributeLoad NameLoad attr body Delete AttributeDel NameLoad attr Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str TryExcept body Assign NameStore Call AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type AttributeLoad NameLoad attr body Raise Call AttributeLoad NameLoad attr NameLoad orelse Return Call NameLoad NameLoad decorator_list Assign NameStore Call AttributeLoad NameLoad attr
N/A N/A Provides the Session class and related utilities. N/A weakref N/A util sql engine exc sa_exc sql util sql_util expression N/A SessionExtension attributes exc query loading identity inspection inspect base object_mapper class_mapper _class_to_mapper _state_mapper object_state _none_set state_str instance_str unitofwork UOWTransaction N/A state statelib N/A sys N/A __all__ N/A Session SessionTransaction SessionExtension sessionmaker N/A _sessions N/A N/A weakref WeakValueDictionary N/A Weak-referencing dictionary of :class:`.Session` objects.
 _state_session N/A N/A state N/A N/A N/A Given an :class:`.InstanceState`, return the :class:`.Session`
        associated, if any.
     N/A N/A state session_id N/A N/A N/A N/A N/A _sessions N/A N/A state session_id N/A N/A N/A KeyError N/A N/A N/A None N/A _SessionClassMethods N/A object N/A N/A Class-level methods for :class:`.Session`, :class:`.sessionmaker`. close_all N/A N/A cls N/A N/A N/A Close *all* sessions in memory. N/A sess N/A N/A _sessions values N/A N/A N/A N/A sess close N/A classmethod identity_key N/A N/A cls orm_util N/A args kwargs N/A N/A Return an identity key.

        This is an alias of :func:`.util.identity_key`.

         N/A N/A N/A orm_util identity_key args kwargs N/A classmethod N/A N/A util dependencies sqlalchemy.orm.util object_session N/A N/A cls instance N/A N/A N/A Return the :class:`.Session` to which an object belongs.

        This is an alias of :func:`.object_session`.

         N/A N/A object_session instance N/A classmethod N/A N/A ACTIVE N/A N/A util symbol ACTIVE N/A PREPARED N/A N/A util symbol PREPARED N/A COMMITTED N/A N/A util symbol COMMITTED N/A DEACTIVE N/A N/A util symbol DEACTIVE N/A CLOSED N/A N/A util symbol CLOSED SessionTransaction N/A object N/A N/A A :class:`.Session`-level transaction.

    :class:`.SessionTransaction` is a mostly behind-the-scenes object
    not normally referenced directly by application code.   It coordinates
    among multiple :class:`.Connection` objects, maintaining a database
    transaction for each one individually, committing or rolling them
    back all at once.   It also provides optional two-phase commit behavior
    which can augment this coordination operation.

    The :attr:`.Session.transaction` attribute of :class:`.Session`
    refers to the current :class:`.SessionTransaction` object in use, if any.


    A :class:`.SessionTransaction` is associated with a :class:`.Session`
    in its default mode of ``autocommit=False`` immediately, associated
    with no database connections.  As the :class:`.Session` is called upon
    to emit SQL on behalf of various :class:`.Engine` or :class:`.Connection`
    objects, a corresponding :class:`.Connection` and associated
    :class:`.Transaction` is added to a collection within the
    :class:`.SessionTransaction` object, becoming one of the
    connection/transaction pairs maintained by the
    :class:`.SessionTransaction`.

    The lifespan of the :class:`.SessionTransaction` ends when the
    :meth:`.Session.commit`, :meth:`.Session.rollback` or
    :meth:`.Session.close` methods are called.  At this point, the
    :class:`.SessionTransaction` removes its association with its parent
    :class:`.Session`.   A :class:`.Session` that is in ``autocommit=False``
    mode will create a new :class:`.SessionTransaction` to replace it
    immediately, whereas a :class:`.Session` that's in ``autocommit=True``
    mode will remain without a :class:`.SessionTransaction` until the
    :meth:`.Session.begin` method is called.

    Another detail of :class:`.SessionTransaction` behavior is that it is
    capable of "nesting".  This means that the :meth:`.Session.begin` method
    can be called while an existing :class:`.SessionTransaction` is already
    present, producing a new :class:`.SessionTransaction` that temporarily
    replaces the parent :class:`.SessionTransaction`.   When a
    :class:`.SessionTransaction` is produced as nested, it assigns itself to
    the :attr:`.Session.transaction` attribute.  When it is ended via
    :meth:`.Session.commit` or :meth:`.Session.rollback`, it restores its
    parent :class:`.SessionTransaction` back onto the
    :attr:`.Session.transaction` attribute.  The behavior is effectively a
    stack, where :attr:`.Session.transaction` refers to the current head of
    the stack.

    The purpose of this stack is to allow nesting of
    :meth:`.Session.rollback` or :meth:`.Session.commit` calls in context
    with various flavors of :meth:`.Session.begin`. This nesting behavior
    applies to when :meth:`.Session.begin_nested` is used to emit a
    SAVEPOINT transaction, and is also used to produce a so-called
    "subtransaction" which allows a block of code to use a
    begin/rollback/commit sequence regardless of whether or not its enclosing
    code block has begun a transaction.  The :meth:`.flush` method, whether
    called explicitly or via autoflush, is the primary consumer of the
    "subtransaction" feature, in that it wishes to guarantee that it works
    within in a transaction block regardless of whether or not the
    :class:`.Session` is in transactional mode when the method is called.

    See also:

    :meth:`.Session.rollback`

    :meth:`.Session.commit`

    :meth:`.Session.begin`

    :meth:`.Session.begin_nested`

    :attr:`.Session.is_active`

    :meth:`.SessionEvents.after_commit`

    :meth:`.SessionEvents.after_rollback`

    :meth:`.SessionEvents.after_soft_rollback`

     N/A _rollback_exception None __init__ N/A N/A self session parent nested N/A None False N/A N/A N/A self session session N/A N/A self _connections N/A N/A N/A self _parent parent N/A N/A self nested nested N/A N/A self _state ACTIVE N/A N/A N/A parent nested N/A N/A N/A N/A sa_exc InvalidRequestError Can't start a SAVEPOINT transaction when no existing transaction is in progress N/A N/A N/A self session _enable_transaction_accounting N/A N/A N/A N/A self _take_snapshot N/A N/A N/A N/A self session dispatch after_transaction_create N/A N/A N/A N/A N/A N/A self session dispatch after_transaction_create N/A self session self N/A is_active N/A N/A self N/A N/A N/A N/A N/A N/A self session None N/A N/A self _state ACTIVE N/A property _assert_active N/A N/A self prepared_ok rollback_ok deactive_ok closed_msg N/A False False False This transaction is closed N/A N/A N/A N/A self _state COMMITTED N/A N/A N/A N/A sa_exc InvalidRequestError This session is in 'committed' state; no further SQL can be emitted within this transaction. N/A N/A N/A N/A self _state PREPARED N/A N/A N/A prepared_ok N/A N/A N/A N/A sa_exc InvalidRequestError This session is in 'prepared' state; no further SQL can be emitted within this transaction. N/A N/A N/A N/A self _state DEACTIVE N/A N/A N/A N/A deactive_ok N/A rollback_ok N/A N/A N/A self _rollback_exception N/A N/A N/A N/A sa_exc InvalidRequestError N/A This Session's transaction has been rolled back due to a previous exception during flush. To begin a new transaction with this Session, first issue Session.rollback(). Original exception was: %s N/A self _rollback_exception N/A N/A N/A deactive_ok N/A N/A N/A N/A sa_exc InvalidRequestError This Session's transaction has been rolled back by a nested rollback() call.  To begin a new transaction, issue Session.rollback() first. N/A N/A N/A N/A self _state CLOSED N/A N/A N/A N/A sa_exc ResourceClosedError closed_msg N/A _is_transaction_boundary N/A N/A self N/A N/A N/A N/A N/A self nested N/A N/A self _parent N/A property connection N/A N/A self bindkey execution_options N/A None kwargs N/A N/A N/A N/A self _assert_active N/A bind N/A N/A N/A self session get_bind bindkey kwargs N/A N/A N/A self _connection_for_bind bind execution_options N/A _begin N/A N/A self nested N/A False N/A N/A N/A N/A self _assert_active N/A N/A SessionTransaction N/A self session self nested nested N/A _iterate_parents N/A N/A self upto N/A None N/A N/A N/A N/A self _parent upto N/A N/A N/A self N/A N/A N/A N/A self _parent None N/A N/A N/A N/A sa_exc InvalidRequestError N/A Transaction %s is not on the active transaction list upto N/A N/A N/A self N/A N/A N/A self _parent _iterate_parents upto N/A _take_snapshot N/A N/A self N/A N/A N/A N/A N/A self _is_transaction_boundary N/A N/A N/A self _new N/A N/A self _parent _new N/A N/A self _deleted N/A N/A self _parent _deleted N/A N/A self _dirty N/A N/A self _parent _dirty N/A N/A self _key_switches N/A N/A self _parent _key_switches N/A N/A N/A N/A N/A self session _flushing N/A N/A N/A N/A N/A self session flush N/A N/A self _new N/A N/A weakref WeakKeyDictionary N/A N/A self _deleted N/A N/A weakref WeakKeyDictionary N/A N/A self _dirty N/A N/A weakref WeakKeyDictionary N/A N/A self _key_switches N/A N/A weakref WeakKeyDictionary N/A _restore_snapshot N/A N/A self dirty_only N/A False N/A N/A N/A self _is_transaction_boundary N/A s N/A N/A N/A set N/A self _new union N/A N/A self session _new N/A N/A N/A N/A N/A self session _expunge_state s N/A N/A s key N/A N/A N/A s key N/A N/A s N/A oldkey newkey N/A N/A N/A self _key_switches items N/A N/A N/A N/A N/A N/A self session identity_map discard s N/A N/A s key oldkey N/A N/A N/A N/A N/A self session identity_map replace s N/A s N/A N/A N/A set N/A self _deleted union N/A N/A self session _deleted N/A N/A N/A s deleted N/A N/A N/A s deleted N/A N/A N/A N/A self session _update_impl s discard_existing True N/A N/A N/A N/A self session _deleted N/A s N/A N/A N/A N/A self session identity_map all_states N/A N/A N/A N/A dirty_only N/A s modified N/A s N/A self _dirty N/A N/A N/A N/A s _expire N/A s dict N/A N/A N/A self session identity_map _modified N/A _remove_snapshot N/A N/A self N/A N/A N/A N/A self _is_transaction_boundary N/A N/A N/A N/A self nested N/A N/A self session expire_on_commit N/A N/A s N/A N/A N/A N/A self session identity_map all_states N/A N/A N/A N/A s _expire N/A s dict N/A N/A N/A self session identity_map _modified N/A s N/A self _deleted N/A N/A N/A s session_id None N/A N/A N/A N/A self _deleted clear N/A N/A N/A self nested N/A N/A N/A N/A N/A N/A self _parent _new update N/A self _new N/A N/A N/A N/A N/A self _parent _deleted update N/A self _deleted N/A N/A N/A N/A N/A self _parent _key_switches update N/A self _key_switches N/A _connection_for_bind N/A N/A self bind execution_options N/A N/A N/A N/A N/A self _assert_active N/A N/A bind N/A self _connections N/A N/A execution_options N/A N/A N/A N/A util warn Connection is already established for the given bind; execution_options ignored N/A N/A N/A N/A self _connections N/A bind N/A 0 N/A N/A self _parent N/A N/A conn N/A N/A N/A self _parent _connection_for_bind bind execution_options N/A N/A N/A self nested N/A N/A conn N/A N/A N/A isinstance bind N/A engine Connection N/A N/A conn bind N/A N/A N/A conn engine N/A self _connections N/A N/A N/A N/A sa_exc InvalidRequestError Session already has a Connection associated for the given Connection's Engine N/A N/A conn N/A N/A bind contextual_connect N/A execution_options N/A N/A conn N/A N/A conn execution_options execution_options N/A N/A N/A N/A self session twophase N/A N/A self _parent None N/A N/A transaction N/A N/A conn begin_twophase N/A N/A N/A self nested N/A N/A transaction N/A N/A conn begin_nested N/A N/A transaction N/A N/A conn begin N/A N/A N/A self _connections N/A conn N/A N/A self _connections N/A N/A conn engine N/A conn transaction N/A conn bind N/A N/A N/A N/A N/A self session dispatch after_begin N/A self session self conn N/A conn N/A prepare N/A N/A self N/A N/A N/A N/A N/A N/A self _parent None N/A N/A N/A self session twophase N/A N/A N/A N/A sa_exc InvalidRequestError 'twophase' mode not enabled, or not root transaction; can't prepare. N/A N/A N/A self _prepare_impl N/A _prepare_impl N/A N/A self N/A N/A N/A N/A N/A self _assert_active N/A N/A N/A N/A self _parent None N/A self nested N/A N/A N/A N/A N/A N/A self session dispatch before_commit N/A self session N/A stx N/A N/A self session transaction N/A N/A stx self N/A N/A subtransaction N/A N/A stx _iterate_parents upto self N/A N/A N/A N/A subtransaction commit N/A N/A N/A N/A self session _flushing N/A N/A _flush_guard N/A range 100 N/A N/A N/A N/A N/A self session _is_clean N/A N/A N/A N/A N/A N/A self session flush N/A N/A N/A N/A exc FlushError Over 100 subsequent flushes have occurred within session.commit() - is an after_flush() hook creating new objects? N/A N/A N/A N/A self _parent None N/A N/A self session twophase N/A N/A N/A N/A t N/A set N/A N/A N/A self _connections values N/A N/A N/A N/A N/A t N/A 1 prepare N/A N/A N/A N/A N/A N/A util safe_reraise N/A N/A N/A N/A self rollback N/A N/A self _state PREPARED N/A commit N/A N/A self N/A N/A N/A N/A N/A self _assert_active prepared_ok True N/A N/A N/A self _state PREPARED N/A N/A N/A N/A self _prepare_impl N/A N/A N/A N/A self _parent None N/A self nested N/A N/A t N/A set N/A N/A N/A self _connections values N/A N/A N/A N/A N/A t N/A 1 commit N/A N/A self _state COMMITTED N/A N/A N/A N/A N/A self session dispatch after_commit N/A self session N/A N/A N/A self session _enable_transaction_accounting N/A N/A N/A N/A self _remove_snapshot N/A N/A N/A self close N/A N/A self _parent N/A rollback N/A N/A self _capture_exception N/A False N/A N/A N/A N/A self _assert_active prepared_ok True rollback_ok True N/A stx N/A N/A self session transaction N/A N/A stx self N/A N/A subtransaction N/A N/A stx _iterate_parents upto self N/A N/A N/A N/A subtransaction close N/A boundary self N/A N/A N/A self _state N/A ACTIVE PREPARED N/A N/A transaction N/A N/A self _iterate_parents N/A N/A N/A N/A N/A transaction _parent None N/A transaction nested N/A N/A N/A N/A transaction _rollback_impl N/A N/A transaction _state DEACTIVE N/A boundary transaction N/A N/A N/A N/A transaction _state DEACTIVE N/A sess N/A self session N/A N/A N/A sess _enable_transaction_accounting N/A N/A N/A sess _is_clean N/A N/A N/A N/A util warn Session's state has been changed on a non-active transaction - this state will be discarded. N/A N/A N/A boundary _restore_snapshot dirty_only N/A boundary nested N/A N/A N/A self close N/A N/A N/A self _parent _capture_exception N/A N/A N/A N/A self _parent _rollback_exception N/A N/A N/A sys exc_info N/A 1 N/A N/A N/A N/A sess dispatch after_soft_rollback sess self N/A N/A self _parent N/A _rollback_impl N/A N/A self N/A N/A N/A t N/A set N/A N/A N/A self _connections values N/A N/A N/A N/A N/A t N/A 1 rollback N/A N/A N/A self session _enable_transaction_accounting N/A N/A N/A N/A self _restore_snapshot dirty_only N/A self nested N/A N/A N/A N/A N/A self session dispatch after_rollback N/A self session N/A close N/A N/A self invalidate N/A False N/A N/A N/A N/A self session transaction N/A self _parent N/A N/A N/A self _parent None N/A N/A N/A connection transaction autoclose N/A set N/A N/A N/A self _connections values N/A N/A invalidate N/A N/A N/A N/A connection invalidate N/A autoclose N/A N/A N/A N/A connection close N/A N/A N/A N/A transaction close N/A N/A self _state CLOSED N/A N/A N/A N/A self session dispatch after_transaction_end N/A N/A N/A N/A N/A N/A self session dispatch after_transaction_end N/A self session self N/A N/A N/A self _parent None N/A N/A N/A N/A N/A self session autocommit N/A N/A N/A N/A N/A self session begin N/A N/A self session None N/A N/A self _connections None N/A __enter__ N/A N/A self N/A N/A N/A self N/A __exit__ N/A N/A self type value traceback N/A N/A N/A N/A N/A self _assert_active deactive_ok True prepared_ok True N/A N/A N/A N/A self session transaction None N/A N/A N/A N/A type None N/A N/A N/A N/A N/A N/A self commit N/A N/A N/A N/A N/A N/A util safe_reraise N/A N/A N/A N/A self rollback N/A N/A N/A N/A self rollback N/A N/A Session N/A _SessionClassMethods N/A N/A Manages persistence operations for ORM-mapped objects.

    The Session's usage paradigm is described at :doc:`/orm/session`.


     N/A public_methods N/A __contains__ __iter__ add add_all begin begin_nested close commit connection delete execute expire expire_all expunge expunge_all flush get_bind is_modified merge query refresh rollback scalar __init__ N/A N/A self bind autoflush expire_on_commit _enable_transaction_accounting autocommit twophase weak_identity_map binds extension info query_cls N/A None True True True False False True None None None N/A query Query N/A N/A Construct a new Session.

        See also the :class:`.sessionmaker` function which is used to
        generate a :class:`.Session`-producing callable with a given
        set of arguments.

        :param autocommit:

          .. warning::

             The autocommit flag is **not for general use**, and if it is
             used, queries should only be invoked within the span of a
             :meth:`.Session.begin` / :meth:`.Session.commit` pair.  Executing
             queries outside of a demarcated transaction is a legacy mode
             of usage, and can in some cases lead to concurrent connection
             checkouts.

          Defaults to ``False``. When ``True``, the
          :class:`.Session` does not keep a persistent transaction running,
          and will acquire connections from the engine on an as-needed basis,
          returning them immediately after their use. Flushes will begin and
          commit (or possibly rollback) their own transaction if no
          transaction is present. When using this mode, the
          :meth:`.Session.begin` method is used to explicitly start
          transactions.

          .. seealso::

            :ref:`session_autocommit`

        :param autoflush: When ``True``, all query operations will issue a
           :meth:`~.Session.flush` call to this ``Session`` before proceeding.
           This is a convenience feature so that :meth:`~.Session.flush` need
           not be called repeatedly in order for database queries to retrieve
           results. It's typical that ``autoflush`` is used in conjunction with
           ``autocommit=False``. In this scenario, explicit calls to
           :meth:`~.Session.flush` are rarely needed; you usually only need to
           call :meth:`~.Session.commit` (which flushes) to finalize changes.

        :param bind: An optional :class:`.Engine` or :class:`.Connection` to
           which this ``Session`` should be bound. When specified, all SQL
           operations performed by this session will execute via this
           connectable.

        :param binds: An optional dictionary which contains more granular
           "bind" information than the ``bind`` parameter provides. This
           dictionary can map individual :class`.Table`
           instances as well as :class:`~.Mapper` instances to individual
           :class:`.Engine` or :class:`.Connection` objects. Operations which
           proceed relative to a particular :class:`.Mapper` will consult this
           dictionary for the direct :class:`.Mapper` instance as
           well as the mapper's ``mapped_table`` attribute in order to locate a
           connectable to use. The full resolution is described in the
           :meth:`.Session.get_bind`.
           Usage looks like::

            Session = sessionmaker(binds={
                SomeMappedClass: create_engine('postgresql://engine1'),
                somemapper: create_engine('postgresql://engine2'),
                some_table: create_engine('postgresql://engine3'),
                })

          Also see the :meth:`.Session.bind_mapper`
          and :meth:`.Session.bind_table` methods.

        :param \class_: Specify an alternate class other than
           ``sqlalchemy.orm.session.Session`` which should be used by the
           returned class. This is the only argument that is local to the
           :class:`.sessionmaker` function, and is not sent directly to the
           constructor for ``Session``.

        :param _enable_transaction_accounting:  Defaults to ``True``.  A
           legacy-only flag which when ``False`` disables *all* 0.5-style
           object accounting on transaction boundaries, including auto-expiry
           of instances on rollback and commit, maintenance of the "new" and
           "deleted" lists upon rollback, and autoflush of pending changes
           upon :meth:`~.Session.begin`, all of which are interdependent.

        :param expire_on_commit:  Defaults to ``True``. When ``True``, all
           instances will be fully expired after each :meth:`~.commit`,
           so that all attribute/object access subsequent to a completed
           transaction will load from the most recent database state.

        :param extension: An optional
           :class:`~.SessionExtension` instance, or a list
           of such instances, which will receive pre- and post- commit and
           flush events, as well as a post-rollback event. **Deprecated.**
           Please see :class:`.SessionEvents`.

        :param info: optional dictionary of arbitrary data to be associated
           with this :class:`.Session`.  Is available via the
           :attr:`.Session.info` attribute.  Note the dictionary is copied at
           construction time so that modifications to the per-
           :class:`.Session` dictionary will be local to that
           :class:`.Session`.

           .. versionadded:: 0.9.0

        :param query_cls:  Class which should be used to create new Query
           objects, as returned by the :meth:`~.Session.query` method. Defaults
           to :class:`.Query`.

        :param twophase:  When ``True``, all transactions will be started as
            a "two phase" transaction, i.e. using the "two phase" semantics
            of the database in use along with an XID.  During a
            :meth:`~.commit`, after :meth:`~.flush` has been issued for all
            attached databases, the :meth:`~.TwoPhaseTransaction.prepare`
            method on each database's :class:`.TwoPhaseTransaction` will be
            called. This allows each database to roll back the entire
            transaction, before each transaction is committed.

        :param weak_identity_map:  Defaults to ``True`` - when set to
           ``False``, objects placed in the :class:`.Session` will be
           strongly referenced until explicitly removed or the
           :class:`.Session` is closed.  **Deprecated** - this option
           is obsolete.

         N/A weak_identity_map N/A N/A N/A self _identity_cls N/A identity WeakInstanceDict N/A N/A N/A N/A util warn_deprecated weak_identity_map=False is deprecated.  This feature is not needed. N/A N/A self _identity_cls N/A identity StrongInstanceDict N/A N/A self identity_map N/A N/A self _identity_cls N/A N/A self _new N/A N/A N/A self _deleted N/A N/A N/A self bind bind N/A N/A self __binds N/A N/A N/A self _flushing False N/A N/A self _warn_on_events False N/A N/A self transaction None N/A N/A self hash_key N/A _new_sessionid N/A N/A self autoflush autoflush N/A N/A self autocommit autocommit N/A N/A self expire_on_commit expire_on_commit N/A N/A self _enable_transaction_accounting _enable_transaction_accounting N/A N/A self twophase twophase N/A N/A self _query_cls query_cls N/A info N/A N/A N/A N/A N/A self info update info N/A extension N/A N/A ext N/A N/A util to_list extension N/A N/A N/A N/A SessionExtension _adapt_listener self ext N/A N/A binds None N/A N/A N/A mapperortable bind N/A N/A binds items N/A N/A insp N/A inspect mapperortable N/A N/A insp is_selectable N/A N/A N/A N/A self bind_table mapperortable bind N/A N/A N/A insp is_mapper N/A N/A N/A N/A self bind_mapper mapperortable bind N/A N/A False N/A N/A N/A self autocommit N/A N/A N/A N/A self begin N/A N/A _sessions N/A N/A self hash_key self N/A N/A connection_callable None N/A transaction None N/A The current active or inactive :class:`.SessionTransaction`. info N/A N/A self N/A N/A N/A A user-modifiable dictionary.

        The initial value of this dictioanry can be populated using the
        ``info`` argument to the :class:`.Session` constructor or
        :class:`.sessionmaker` constructor or factory methods.  The dictionary
        here is always local to this :class:`.Session` and can be modified
        independently of all other :class:`.Session` objects.

        .. versionadded:: 0.9.0

         N/A N/A N/A N/A util memoized_property begin N/A N/A self subtransactions nested N/A False False N/A N/A Begin a transaction on this :class:`.Session`.

        If this Session is already within a transaction, either a plain
        transaction or nested transaction, an error is raised, unless
        ``subtransactions=True`` or ``nested=True`` is specified.

        The ``subtransactions=True`` flag indicates that this
        :meth:`~.Session.begin` can create a subtransaction if a transaction
        is already in progress. For documentation on subtransactions, please
        see :ref:`session_subtransactions`.

        The ``nested`` flag begins a SAVEPOINT transaction and is equivalent
        to calling :meth:`~.Session.begin_nested`. For documentation on
        SAVEPOINT transactions, please see :ref:`session_begin_nested`.

         N/A N/A N/A self transaction None N/A N/A N/A subtransactions nested N/A N/A N/A self transaction N/A N/A N/A self transaction _begin nested nested N/A N/A N/A N/A sa_exc InvalidRequestError A transaction is already begun.  Use subtransactions=True to allow subtransactions. N/A N/A N/A self transaction N/A SessionTransaction self nested nested N/A N/A self transaction N/A begin_nested N/A N/A self N/A N/A N/A Begin a `nested` transaction on this Session.

        The target database(s) must support SQL SAVEPOINTs or a
        SQLAlchemy-supported vendor implementation of the idea.

        For documentation on SAVEPOINT
        transactions, please see :ref:`session_begin_nested`.

         N/A N/A N/A self begin nested True N/A rollback N/A N/A self N/A N/A N/A Rollback the current transaction in progress.

        If no transaction is in progress, this method is a pass-through.

        This method rolls back the current transaction or nested transaction
        regardless of subtransactions being in effect.  All subtransactions up
        to the first real transaction are closed.  Subtransactions occur when
        :meth:`.begin` is called multiple times.

        .. seealso::

            :ref:`session_rollback`

         N/A N/A N/A self transaction None N/A N/A N/A N/A N/A N/A N/A self transaction rollback N/A commit N/A N/A self N/A N/A N/A Flush pending changes and commit the current transaction.

        If no transaction is in progress, this method raises an
        :exc:`~sqlalchemy.exc.InvalidRequestError`.

        By default, the :class:`.Session` also expires all database
        loaded state on all ORM-managed attributes after transaction commit.
        This so that subsequent operations load the most recent
        data from the database.   This behavior can be disabled using
        the ``expire_on_commit=False`` option to :class:`.sessionmaker` or
        the :class:`.Session` constructor.

        If a subtransaction is in effect (which occurs when begin() is called
        multiple times), the subtransaction will be closed, and the next call
        to ``commit()`` will operate on the enclosing transaction.

        When using the :class:`.Session` in its default mode of
        ``autocommit=False``, a new transaction will
        be begun immediately after the commit, but note that the newly begun
        transaction does *not* use any connection resources until the first
        SQL is actually emitted.

        .. seealso::

            :ref:`session_committing`

         N/A N/A N/A self transaction None N/A N/A N/A N/A self autocommit N/A N/A N/A N/A self begin N/A N/A N/A N/A sa_exc InvalidRequestError No transaction is begun. N/A N/A N/A N/A self transaction commit N/A prepare N/A N/A self N/A N/A N/A Prepare the current transaction in progress for two phase commit.

        If no transaction is in progress, this method raises an
        :exc:`~sqlalchemy.exc.InvalidRequestError`.

        Only root transactions of two phase sessions can be prepared. If the
        current transaction is not such, an
        :exc:`~sqlalchemy.exc.InvalidRequestError` is raised.

         N/A N/A N/A self transaction None N/A N/A N/A N/A self autocommit N/A N/A N/A N/A self begin N/A N/A N/A N/A sa_exc InvalidRequestError No transaction is begun. N/A N/A N/A N/A self transaction prepare N/A connection N/A N/A self mapper clause bind close_with_result execution_options N/A None None None False None kw N/A N/A Return a :class:`.Connection` object corresponding to this
        :class:`.Session` object's transactional state.

        If this :class:`.Session` is configured with ``autocommit=False``,
        either the :class:`.Connection` corresponding to the current
        transaction is returned, or if no transaction is in progress, a new
        one is begun and the :class:`.Connection` returned (note that no
        transactional state is established with the DBAPI until the first
        SQL statement is emitted).

        Alternatively, if this :class:`.Session` is configured with
        ``autocommit=True``, an ad-hoc :class:`.Connection` is returned
        using :meth:`.Engine.contextual_connect` on the underlying
        :class:`.Engine`.

        Ambiguity in multi-bind or unbound :class:`.Session` objects can be
        resolved through any of the optional keyword arguments.   This
        ultimately makes usage of the :meth:`.get_bind` method for resolution.

        :param bind:
          Optional :class:`.Engine` to be used as the bind.  If
          this engine is already involved in an ongoing transaction,
          that connection will be used.  This argument takes precedence
          over ``mapper``, ``clause``.

        :param mapper:
          Optional :func:`.mapper` mapped class, used to identify
          the appropriate bind.  This argument takes precedence over
          ``clause``.

        :param clause:
            A :class:`.ClauseElement` (i.e. :func:`~.sql.expression.select`,
            :func:`~.sql.expression.text`,
            etc.) which will be used to locate a bind, if a bind
            cannot otherwise be identified.

        :param close_with_result: Passed to :meth:`.Engine.connect`,
          indicating the :class:`.Connection` should be considered
          "single use", automatically closing when the first result set is
          closed.  This flag only has an effect if this :class:`.Session` is
          configured with ``autocommit=True`` and does not already have a
          transaction in progress.

        :param execution_options: a dictionary of execution options that will
         be passed to :meth:`.Connection.execution_options`, **when the
         connection is first procured only**.   If the connection is already
         present within the :class:`.Session`, a warning is emitted and
         the arguments are ignored.

         .. versionadded:: 0.9.9

         .. seealso::

            :ref:`session_transaction_isolation`

        :param \**kw:
          Additional keyword arguments are sent to :meth:`get_bind()`,
          allowing additional arguments to be passed to custom
          implementations of :meth:`get_bind`.

         N/A N/A bind None N/A N/A bind N/A N/A self get_bind mapper clause clause kw N/A N/A N/A self _connection_for_bind bind close_with_result close_with_result execution_options execution_options N/A _connection_for_bind N/A N/A self engine execution_options N/A None kw N/A N/A N/A N/A self transaction None N/A N/A N/A N/A N/A self transaction _connection_for_bind engine execution_options N/A N/A conn N/A N/A engine contextual_connect kw N/A execution_options N/A N/A conn N/A N/A conn execution_options execution_options N/A conn N/A execute N/A N/A self clause params mapper bind N/A None None None kw N/A N/A Execute a SQL expression construct or string statement within
        the current transaction.

        Returns a :class:`.ResultProxy` representing
        results of the statement execution, in the same manner as that of an
        :class:`.Engine` or
        :class:`.Connection`.

        E.g.::

            result = session.execute(
                        user_table.select().where(user_table.c.id == 5)
                    )

        :meth:`~.Session.execute` accepts any executable clause construct,
        such as :func:`~.sql.expression.select`,
        :func:`~.sql.expression.insert`,
        :func:`~.sql.expression.update`,
        :func:`~.sql.expression.delete`, and
        :func:`~.sql.expression.text`.  Plain SQL strings can be passed
        as well, which in the case of :meth:`.Session.execute` only
        will be interpreted the same as if it were passed via a
        :func:`~.expression.text` construct.  That is, the following usage::

            result = session.execute(
                        "SELECT * FROM user WHERE id=:param",
                        {"param":5}
                    )

        is equivalent to::

            from sqlalchemy import text
            result = session.execute(
                        text("SELECT * FROM user WHERE id=:param"),
                        {"param":5}
                    )

        The second positional argument to :meth:`.Session.execute` is an
        optional parameter set.  Similar to that of
        :meth:`.Connection.execute`, whether this is passed as a single
        dictionary, or a list of dictionaries, determines whether the DBAPI
        cursor's ``execute()`` or ``executemany()`` is used to execute the
        statement.   An INSERT construct may be invoked for a single row::

            result = session.execute(
                users.insert(), {"id": 7, "name": "somename"})

        or for multiple rows::

            result = session.execute(users.insert(), [
                                    {"id": 7, "name": "somename7"},
                                    {"id": 8, "name": "somename8"},
                                    {"id": 9, "name": "somename9"}
                                ])

        The statement is executed within the current transactional context of
        this :class:`.Session`.   The :class:`.Connection` which is used
        to execute the statement can also be acquired directly by
        calling the :meth:`.Session.connection` method.  Both methods use
        a rule-based resolution scheme in order to determine the
        :class:`.Connection`, which in the average case is derived directly
        from the "bind" of the :class:`.Session` itself, and in other cases
        can be based on the :func:`.mapper`
        and :class:`.Table` objects passed to the method; see the
        documentation for :meth:`.Session.get_bind` for a full description of
        this scheme.

        The :meth:`.Session.execute` method does *not* invoke autoflush.

        The :class:`.ResultProxy` returned by the :meth:`.Session.execute`
        method is returned with the "close_with_result" flag set to true;
        the significance of this flag is that if this :class:`.Session` is
        autocommitting and does not have a transaction-dedicated
        :class:`.Connection` available, a temporary :class:`.Connection` is
        established for the statement execution, which is closed (meaning,
        returned to the connection pool) when the :class:`.ResultProxy` has
        consumed all available data. This applies *only* when the
        :class:`.Session` is configured with autocommit=True and no
        transaction has been started.

        :param clause:
            An executable statement (i.e. an :class:`.Executable` expression
            such as :func:`.expression.select`) or string SQL statement
            to be executed.

        :param params:
            Optional dictionary, or list of dictionaries, containing
            bound parameter values.   If a single dictionary, single-row
            execution occurs; if a list of dictionaries, an
            "executemany" will be invoked.  The keys in each dictionary
            must correspond to parameter names present in the statement.

        :param mapper:
          Optional :func:`.mapper` or mapped class, used to identify
          the appropriate bind.  This argument takes precedence over
          ``clause`` when locating a bind.   See :meth:`.Session.get_bind`
          for more details.

        :param bind:
          Optional :class:`.Engine` to be used as the bind.  If
          this engine is already involved in an ongoing transaction,
          that connection will be used.  This argument takes
          precedence over ``mapper`` and ``clause`` when locating
          a bind.

        :param \**kw:
          Additional keyword arguments are sent to :meth:`.Session.get_bind()`
          to allow extensibility of "bind" schemes.

        .. seealso::

            :ref:`sqlexpression_toplevel` - Tutorial on using Core SQL
            constructs.

            :ref:`connections_toplevel` - Further information on direct
            statement execution.

            :meth:`.Connection.execute` - core level statement execution
            method, which is :meth:`.Session.execute` ultimately uses
            in order to execute the statement.

         N/A clause N/A N/A expression _literal_as_text clause N/A N/A bind None N/A N/A bind N/A N/A self get_bind mapper clause clause kw N/A N/A N/A N/A N/A self _connection_for_bind bind close_with_result True execute clause N/A params N/A N/A scalar N/A N/A self clause params mapper bind N/A None None None kw N/A N/A Like :meth:`~.Session.execute` but return a scalar result. N/A N/A N/A N/A N/A self execute clause params params mapper mapper bind bind kw scalar N/A close N/A N/A self N/A N/A N/A Close this Session.

        This clears all items and ends any transaction in progress.

        If this session were created with ``autocommit=False``, a new
        transaction is immediately begun.  Note that this new transaction does
        not use any connection resources until they are first needed.

         N/A N/A N/A self _close_impl invalidate False N/A invalidate N/A N/A self N/A N/A N/A Close this Session, using connection invalidation.

        This is a variant of :meth:`.Session.close` that will additionally
        ensure that the :meth:`.Connection.invalidate` method will be called
        on all :class:`.Connection` objects.  This can be called when
        the database is known to be in a state where the connections are
        no longer safe to be used.

        E.g.::

            try:
                sess = Session()
                sess.add(User())
                sess.commit()
            except gevent.Timeout:
                sess.invalidate()
                raise
            except:
                sess.rollback()
                raise

        This clears all items and ends any transaction in progress.

        If this session were created with ``autocommit=False``, a new
        transaction is immediately begun.  Note that this new transaction does
        not use any connection resources until they are first needed.

        .. versionadded:: 0.9.9

         N/A N/A N/A self _close_impl invalidate True N/A _close_impl N/A N/A self invalidate N/A N/A N/A N/A N/A self expunge_all N/A N/A N/A self transaction None N/A N/A transaction N/A N/A N/A self transaction _iterate_parents N/A N/A N/A N/A transaction close invalidate N/A expunge_all N/A N/A self N/A N/A N/A Remove all object instances from this ``Session``.

        This is equivalent to calling ``expunge(obj)`` on all objects in this
        ``Session``.

         N/A state N/A N/A N/A N/A self identity_map all_states N/A list N/A self _new N/A N/A N/A N/A state _detach N/A N/A self identity_map N/A N/A self _identity_cls N/A N/A self _new N/A N/A N/A self _deleted N/A N/A bind_mapper N/A N/A self mapper bind N/A N/A N/A Bind operations for a mapper to a Connectable.

        mapper
          A mapper instance or mapped class

        bind
          Any Connectable: a :class:`.Engine` or :class:`.Connection`.

        All subsequent operations involving this mapper will use the given
        `bind`.

         N/A N/A isinstance mapper type N/A N/A mapper N/A class_mapper mapper N/A N/A N/A self __binds N/A N/A mapper base_mapper bind N/A t N/A mapper _all_tables N/A N/A N/A N/A self __binds N/A t bind N/A bind_table N/A N/A self table bind N/A N/A N/A Bind operations on a Table to a Connectable.

        table
          A :class:`.Table` instance

        bind
          Any Connectable: a :class:`.Engine` or :class:`.Connection`.

        All subsequent operations involving this :class:`.Table` will use the
        given `bind`.

         N/A N/A N/A self __binds N/A table bind N/A get_bind N/A N/A self mapper clause N/A None None N/A N/A Return a "bind" to which this :class:`.Session` is bound.

        The "bind" is usually an instance of :class:`.Engine`,
        except in the case where the :class:`.Session` has been
        explicitly bound directly to a :class:`.Connection`.

        For a multiply-bound or unbound :class:`.Session`, the
        ``mapper`` or ``clause`` arguments are used to determine the
        appropriate bind to return.

        Note that the "mapper" argument is usually present
        when :meth:`.Session.get_bind` is called via an ORM
        operation such as a :meth:`.Session.query`, each
        individual INSERT/UPDATE/DELETE operation within a
        :meth:`.Session.flush`, call, etc.

        The order of resolution is:

        1. if mapper given and session.binds is present,
           locate a bind based on mapper.
        2. if clause given and session.binds is present,
           locate a bind based on :class:`.Table` objects
           found in the given clause present in session.binds.
        3. if session.bind is present, return that.
        4. if clause given, attempt to return a bind
           linked to the :class:`.MetaData` ultimately
           associated with the clause.
        5. if mapper given, attempt to return a bind
           linked to the :class:`.MetaData` ultimately
           associated with the :class:`.Table` or other
           selectable to which the mapper is mapped.
        6. No bind can be found, :exc:`~sqlalchemy.exc.UnboundExecutionError`
           is raised.

        :param mapper:
          Optional :func:`.mapper` mapped class or instance of
          :class:`.Mapper`.   The bind can be derived from a :class:`.Mapper`
          first by consulting the "binds" map associated with this
          :class:`.Session`, and secondly by consulting the :class:`.MetaData`
          associated with the :class:`.Table` to which the :class:`.Mapper`
          is mapped for a bind.

        :param clause:
            A :class:`.ClauseElement` (i.e. :func:`~.sql.expression.select`,
            :func:`~.sql.expression.text`,
            etc.).  If the ``mapper`` argument is not present or could not
            produce a bind, the given expression construct will be searched
            for a bound element, typically a :class:`.Table` associated with
            bound :class:`.MetaData`.

         N/A N/A mapper clause None N/A N/A N/A self bind N/A N/A N/A self bind N/A N/A N/A N/A sa_exc UnboundExecutionError This session is not bound to a single Engine or Connection, and no context was provided to locate a binding. N/A c_mapper N/A N/A N/A mapper None N/A _class_to_mapper mapper None N/A N/A self __binds N/A N/A c_mapper N/A N/A N/A N/A c_mapper base_mapper N/A self __binds N/A N/A N/A N/A self __binds N/A N/A c_mapper base_mapper N/A N/A N/A N/A c_mapper mapped_table N/A self __binds N/A N/A N/A N/A self __binds N/A N/A c_mapper mapped_table N/A N/A clause None N/A N/A t N/A N/A sql_util find_tables clause include_crud True N/A N/A N/A t N/A self __binds N/A N/A N/A N/A self __binds N/A t N/A N/A self bind N/A N/A N/A self bind N/A N/A N/A isinstance clause N/A N/A sql expression ClauseElement N/A clause bind N/A N/A N/A clause bind N/A N/A c_mapper N/A N/A c_mapper mapped_table bind N/A N/A N/A N/A c_mapper mapped_table bind N/A context N/A N/A N/A mapper None N/A N/A N/A N/A context append N/A mapper %s c_mapper N/A N/A clause None N/A N/A N/A N/A context append SQL expression N/A N/A N/A sa_exc UnboundExecutionError N/A Could not locate a bind configured on %s or this Session N/A N/A ,  join context N/A query N/A N/A self N/A entities kwargs N/A N/A Return a new :class:`.Query` object corresponding to this
        :class:`.Session`. N/A N/A N/A self _query_cls entities self kwargs N/A no_autoflush N/A N/A self N/A N/A N/A Return a context manager that disables autoflush.

        e.g.::

            with session.no_autoflush:

                some_object = SomeClass()
                session.add(some_object)
                # won't autoflush
                some_object.related_thing = session.query(SomeRelated).first()

        Operations that proceed within the ``with:`` block
        will not be subject to flushes occurring upon query
        access.  This is useful when initializing a series
        of objects which involve existing database queries,
        where the uncompleted object should not yet be flushed.

        .. versionadded:: 0.7.6

         N/A autoflush N/A self autoflush N/A N/A self autoflush False N/A N/A self N/A N/A self autoflush autoflush N/A property N/A util contextmanager _autoflush N/A N/A self N/A N/A N/A N/A N/A self autoflush N/A N/A self _flushing N/A N/A N/A N/A N/A N/A self flush N/A N/A N/A N/A sa_exc StatementError N/A e N/A N/A N/A N/A e add_detail raised as a result of Query-invoked autoflush; consider using a session.no_autoflush block if this flush is occurring prematurely N/A N/A N/A util raise_from_cause e N/A refresh N/A N/A self instance attribute_names lockmode N/A None None N/A N/A Expire and refresh the attributes on the given instance.

        A query will be issued to the database and all attributes will be
        refreshed with their current database value.

        Lazy-loaded relational attributes will remain lazily loaded, so that
        the instance-wide refresh operation will be followed immediately by
        the lazy load of that attribute.

        Eagerly-loaded relational attributes will eagerly load within the
        single refresh operation.

        Note that a highly isolated transaction will return the same values as
        were previously read in that same transaction, regardless of changes
        in database state outside of that transaction - usage of
        :meth:`~Session.refresh` usually only makes sense if non-ORM SQL
        statement were emitted in the ongoing transaction, or if autocommit
        mode is turned on.

        :param attribute_names: optional.  An iterable collection of
          string attribute names indicating a subset of attributes to
          be refreshed.

        :param lockmode: Passed to the :class:`~sqlalchemy.orm.query.Query`
          as used by :meth:`~sqlalchemy.orm.query.Query.with_lockmode`.

        .. seealso::

            :ref:`session_expire` - introductory material

            :meth:`.Session.expire`

            :meth:`.Session.expire_all`

         N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A self _expire_state state attribute_names N/A N/A N/A N/A loading load_on_ident N/A N/A self query N/A object_mapper instance N/A state key refresh_state state lockmode lockmode only_load_props attribute_names None N/A N/A N/A N/A sa_exc InvalidRequestError N/A Could not refresh instance '%s' N/A instance_str instance N/A expire_all N/A N/A self N/A N/A N/A Expires all persistent instances within this Session.

        When any attributes on a persistent instance is next accessed,
        a query will be issued using the
        :class:`.Session` object's current transactional context in order to
        load all expired attributes for the given instance.   Note that
        a highly isolated transaction will return the same values as were
        previously read in that same transaction, regardless of changes
        in database state outside of that transaction.

        To expire individual objects and individual attributes
        on those objects, use :meth:`Session.expire`.

        The :class:`.Session` object's default behavior is to
        expire all state whenever the :meth:`Session.rollback`
        or :meth:`Session.commit` methods are called, so that new
        state can be loaded for the new transaction.   For this reason,
        calling :meth:`Session.expire_all` should not be needed when
        autocommit is ``False``, assuming the transaction is isolated.

        .. seealso::

            :ref:`session_expire` - introductory material

            :meth:`.Session.expire`

            :meth:`.Session.refresh`

         N/A state N/A N/A N/A self identity_map all_states N/A N/A N/A N/A state _expire N/A state dict N/A N/A self identity_map _modified N/A expire N/A N/A self instance attribute_names N/A None N/A N/A Expire the attributes on an instance.

        Marks the attributes of an instance as out of date. When an expired
        attribute is next accessed, a query will be issued to the
        :class:`.Session` object's current transactional context in order to
        load all expired attributes for the given instance.   Note that
        a highly isolated transaction will return the same values as were
        previously read in that same transaction, regardless of changes
        in database state outside of that transaction.

        To expire all objects in the :class:`.Session` simultaneously,
        use :meth:`Session.expire_all`.

        The :class:`.Session` object's default behavior is to
        expire all state whenever the :meth:`Session.rollback`
        or :meth:`Session.commit` methods are called, so that new
        state can be loaded for the new transaction.   For this reason,
        calling :meth:`Session.expire` only makes sense for the specific
        case that a non-ORM SQL statement was emitted in the current
        transaction.

        :param instance: The instance to be refreshed.
        :param attribute_names: optional list of string attribute names
          indicating a subset of attributes to be expired.

        .. seealso::

            :ref:`session_expire` - introductory material

            :meth:`.Session.expire`

            :meth:`.Session.refresh`

         N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A self _expire_state state attribute_names N/A _expire_state N/A N/A self state attribute_names N/A N/A N/A N/A N/A self _validate_persistent state N/A attribute_names N/A N/A N/A N/A state _expire_attributes N/A state dict attribute_names N/A N/A cascaded N/A list N/A N/A N/A N/A state manager mapper cascade_iterator refresh-expire state N/A N/A N/A self _conditional_expire state N/A N/A o m st_ dct_ cascaded N/A N/A N/A N/A self _conditional_expire st_ N/A _conditional_expire N/A N/A self state N/A N/A N/A Expire a state if persistent, else expunge if pending N/A N/A state key N/A N/A N/A N/A state _expire N/A state dict N/A N/A self identity_map _modified N/A N/A N/A state N/A self _new N/A N/A N/A N/A N/A self _new pop state N/A N/A N/A state _detach N/A prune N/A N/A self N/A N/A N/A Remove unreferenced instances cached in the identity map.

        Note that this method is only meaningful if "weak_identity_map" is set
        to False.  The default weak identity map is self-pruning.

        Removes any object in this Session's identity map that is not
        referenced in user code, modified, new or scheduled for deletion.
        Returns the number of objects pruned.

         N/A N/A N/A N/A self identity_map prune N/A N/A N/A util deprecated 0.7 The non-weak-referencing identity map feature is no longer needed. expunge N/A N/A self instance N/A N/A N/A Remove the `instance` from this ``Session``.

        This will free all internal references to the instance.  Cascading
        will be applied according to the *expunge* cascade rule.

         N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A state session_id N/A self hash_key N/A N/A N/A N/A sa_exc InvalidRequestError N/A Instance %s is not present in this Session N/A state_str state N/A cascaded N/A list N/A N/A N/A N/A state manager mapper cascade_iterator expunge state N/A N/A N/A self _expunge_state state N/A N/A o m st_ dct_ cascaded N/A N/A N/A N/A self _expunge_state st_ N/A _expunge_state N/A N/A self state N/A N/A N/A N/A state N/A self _new N/A N/A N/A N/A N/A self _new pop state N/A N/A N/A state _detach N/A N/A N/A N/A N/A self identity_map contains_state state N/A N/A N/A N/A N/A self identity_map discard state N/A N/A N/A N/A self _deleted pop state None N/A N/A N/A state _detach N/A N/A N/A self transaction N/A N/A N/A N/A N/A N/A self transaction _deleted pop state None N/A _register_newly_persistent N/A N/A self states N/A N/A N/A state states N/A N/A mapper N/A _state_mapper state N/A obj N/A N/A state obj N/A N/A obj None N/A N/A instance_key N/A N/A mapper _identity_key_from_state state N/A N/A N/A N/A N/A _none_set issubset N/A instance_key N/A 1 N/A N/A mapper allow_partial_pks N/A N/A _none_set issuperset N/A instance_key N/A 1 N/A N/A N/A N/A exc FlushError N/A Instance %s has a NULL identity key.  If this is an auto-generated value, check that the database table allows generation of new primary key values, and that the mapped Column object is configured to expect these generated values.  Ensure also that this flush() is not occurring at an inappropriate time, such aswithin a load() event. N/A state_str state N/A N/A N/A state key None N/A N/A N/A state key instance_key N/A N/A N/A N/A state key instance_key N/A N/A N/A N/A N/A self identity_map discard state N/A N/A state N/A N/A self transaction _key_switches N/A N/A orig_key N/A N/A N/A N/A self transaction _key_switches N/A state N/A 0 N/A N/A orig_key N/A state key N/A N/A N/A N/A self transaction _key_switches N/A state N/A orig_key instance_key N/A N/A state key instance_key N/A N/A N/A N/A self identity_map replace state N/A N/A N/A N/A statelib InstanceState _commit_all_states N/A N/A state N/A state dict N/A state states N/A self identity_map N/A N/A N/A self _register_altered states N/A state N/A N/A N/A set states intersection N/A self _new N/A N/A N/A N/A N/A self _new pop state N/A _register_altered N/A N/A self states N/A N/A N/A N/A N/A self _enable_transaction_accounting N/A self transaction N/A N/A state states N/A N/A N/A state N/A self _new N/A N/A N/A N/A N/A self transaction _new N/A state True N/A N/A N/A N/A N/A self transaction _dirty N/A state True N/A _remove_newly_deleted N/A N/A self states N/A N/A N/A state states N/A N/A N/A N/A self _enable_transaction_accounting N/A self transaction N/A N/A N/A N/A N/A self transaction _deleted N/A state True N/A N/A N/A N/A self identity_map discard state N/A N/A N/A N/A self _deleted pop state None N/A N/A state deleted True N/A add N/A N/A self instance _warn N/A True N/A N/A Place an object in the ``Session``.

        Its state will be persisted to the database on the next flush
        operation.

        Repeated calls to ``add()`` will be ignored. The opposite of ``add()``
        is ``expunge()``.

         N/A N/A _warn N/A self _warn_on_events N/A N/A N/A N/A self _flush_warning Session.add() N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A self _save_or_update_state state N/A add_all N/A N/A self instances N/A N/A N/A Add the given collection of instances to this ``Session``. N/A N/A self _warn_on_events N/A N/A N/A N/A self _flush_warning Session.add_all() N/A instance instances N/A N/A N/A N/A self add instance _warn False N/A _save_or_update_state N/A N/A self state N/A N/A N/A N/A N/A self _save_or_update_impl state N/A mapper N/A _state_mapper state N/A N/A o m st_ dct_ N/A N/A mapper cascade_iterator save-update state halt_on N/A self _contains_state N/A N/A N/A N/A self _save_or_update_impl st_ N/A delete N/A N/A self instance N/A N/A N/A Mark an instance as deleted.

        The database delete operation occurs upon ``flush()``.

         N/A N/A self _warn_on_events N/A N/A N/A N/A self _flush_warning Session.delete() N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A state key None N/A N/A N/A N/A sa_exc InvalidRequestError N/A Instance '%s' is not persisted N/A state_str state N/A N/A state N/A self _deleted N/A N/A N/A N/A N/A self _attach state include_before True N/A cascade_states N/A list N/A N/A N/A N/A state manager mapper cascade_iterator delete state N/A N/A N/A self _deleted N/A state N/A N/A state obj N/A N/A N/A N/A self identity_map add state N/A N/A o m st_ dct_ cascade_states N/A N/A N/A N/A self _delete_impl st_ N/A merge N/A N/A self instance load N/A True N/A N/A Copy the state of a given instance into a corresponding instance
        within this :class:`.Session`.

        :meth:`.Session.merge` examines the primary key attributes of the
        source instance, and attempts to reconcile it with an instance of the
        same primary key in the session.   If not found locally, it attempts
        to load the object from the database based on primary key, and if
        none can be located, creates a new instance.  The state of each
        attribute on the source instance is then copied to the target
        instance.  The resulting target instance is then returned by the
        method; the original source instance is left unmodified, and
        un-associated with the :class:`.Session` if not already.

        This operation cascades to associated instances if the association is
        mapped with ``cascade="merge"``.

        See :ref:`unitofwork_merging` for a detailed discussion of merging.

        :param instance: Instance to be merged.
        :param load: Boolean, when False, :meth:`.merge` switches into
         a "high performance" mode which causes it to forego emitting history
         events as well as all database access.  This flag is used for
         cases such as transferring graphs of objects into a :class:`.Session`
         from a second level cache, or to transfer just-loaded objects
         into the :class:`.Session` owned by a worker thread or process
         without re-querying the database.

         The ``load=False`` use case adds the caveat that the given
         object has to be in a "clean" state, that is, has no pending changes
         to be flushed - even if the incoming object is detached from any
         :class:`.Session`.   This is so that when
         the merge operation populates local attributes and
         cascades to related objects and
         collections, the values can be "stamped" onto the
         target object as is, without generating any history or attribute
         events, and without the need to reconcile the incoming data with
         any existing related objects or collections that might not
         be loaded.  The resulting objects from ``load=False`` are always
         produced as "clean", so it is only appropriate that the given objects
         should be "clean" as well, else this suggests a mis-use of the
         method.

         N/A N/A self _warn_on_events N/A N/A N/A N/A self _flush_warning Session.merge() N/A _recursive N/A N/A load N/A N/A N/A N/A self _autoflush N/A N/A object_mapper instance N/A autoflush N/A self autoflush N/A N/A N/A N/A self autoflush False N/A N/A N/A self _merge N/A N/A attributes instance_state instance N/A N/A attributes instance_dict instance load load _recursive _recursive N/A N/A N/A self autoflush autoflush N/A _merge N/A N/A self state state_dict load _recursive N/A True None N/A N/A mapper N/A _state_mapper state N/A N/A state _recursive N/A N/A N/A _recursive N/A state N/A new_instance False N/A key N/A state key N/A N/A key None N/A N/A N/A load N/A N/A N/A N/A sa_exc InvalidRequestError merge() with load=False option does not support objects transient (i.e. unpersisted) objects.  flush() all changes on mapped instances before merging with load=False. N/A key N/A N/A mapper _identity_key_from_state state N/A N/A key N/A self identity_map N/A N/A merged N/A N/A self identity_map N/A key N/A N/A N/A load N/A N/A N/A state modified N/A N/A N/A N/A sa_exc InvalidRequestError merge() with load=False option does not support objects marked as 'dirty'.  flush() all changes on mapped instances before merging with load=False. N/A merged N/A N/A N/A mapper class_manager new_instance N/A merged_state N/A N/A attributes instance_state merged N/A N/A merged_state key key N/A N/A N/A self _update_impl merged_state N/A new_instance True N/A N/A N/A N/A N/A N/A _none_set issubset N/A key N/A 1 N/A N/A mapper allow_partial_pks N/A N/A N/A _none_set issuperset N/A key N/A 1 N/A N/A merged N/A N/A N/A N/A self query N/A mapper class_ get N/A key N/A 1 N/A N/A merged None N/A N/A merged None N/A N/A merged N/A N/A N/A mapper class_manager new_instance N/A merged_state N/A N/A attributes instance_state merged N/A merged_dict N/A N/A attributes instance_dict merged N/A new_instance True N/A N/A N/A self _save_or_update_state merged_state N/A N/A merged_state N/A N/A attributes instance_state merged N/A merged_dict N/A N/A attributes instance_dict merged N/A N/A _recursive N/A state merged N/A N/A state merged_state N/A N/A N/A N/A mapper version_id_col None N/A N/A existing_version N/A N/A mapper _get_state_attr_by_column state state_dict N/A mapper version_id_col passive N/A attributes PASSIVE_NO_INITIALIZE N/A merged_version N/A N/A mapper _get_state_attr_by_column merged_state merged_dict N/A mapper version_id_col passive N/A attributes PASSIVE_NO_INITIALIZE N/A N/A N/A existing_version N/A attributes PASSIVE_NO_RESULT N/A merged_version N/A attributes PASSIVE_NO_RESULT N/A existing_version merged_version N/A N/A N/A N/A exc StaleDataError N/A Version id '%s' on merged state %s does not match existing version '%s'. Leave the version attribute unset when merging to update the most recent version. N/A existing_version N/A state_str merged_state merged_version N/A N/A merged_state load_path N/A state load_path N/A N/A merged_state load_options N/A state load_options N/A prop N/A mapper iterate_properties N/A N/A N/A N/A prop merge self state state_dict merged_state merged_dict load _recursive N/A N/A load N/A N/A N/A N/A merged_state _commit_all merged_dict N/A self identity_map N/A new_instance N/A N/A N/A N/A N/A N/A merged_state manager dispatch load merged_state None N/A merged N/A _validate_persistent N/A N/A self state N/A N/A N/A N/A N/A N/A N/A self identity_map contains_state state N/A N/A N/A N/A sa_exc InvalidRequestError N/A Instance '%s' is not persistent within this Session N/A state_str state N/A _save_impl N/A N/A self state N/A N/A N/A N/A N/A state key None N/A N/A N/A N/A sa_exc InvalidRequestError N/A Object '%s' already has an identity - it can't be registered as pending N/A state_str state N/A N/A N/A self _before_attach state N/A N/A state N/A self _new N/A N/A N/A N/A self _new N/A state N/A N/A state obj N/A N/A state insert_order N/A len N/A self _new N/A N/A N/A self _attach state N/A _update_impl N/A N/A self state discard_existing N/A False N/A N/A N/A N/A N/A N/A self identity_map contains_state state N/A state N/A self _deleted N/A N/A N/A N/A N/A state key None N/A N/A N/A N/A sa_exc InvalidRequestError N/A Instance '%s' is not persisted N/A state_str state N/A N/A state deleted N/A N/A N/A N/A sa_exc InvalidRequestError N/A Instance '%s' has been deleted.  Use the make_transient() function to send this object back to the transient state. N/A state_str state N/A N/A N/A self _before_attach state N/A N/A N/A N/A self _deleted pop state None N/A discard_existing N/A N/A N/A N/A N/A self identity_map replace state N/A N/A N/A N/A N/A self identity_map add state N/A N/A N/A self _attach state N/A _save_or_update_impl N/A N/A self state N/A N/A N/A N/A N/A state key None N/A N/A N/A N/A self _save_impl state N/A N/A N/A N/A self _update_impl state N/A _delete_impl N/A N/A self state N/A N/A N/A N/A state N/A self _deleted N/A N/A N/A N/A N/A state key None N/A N/A N/A N/A N/A self _attach state include_before True N/A N/A N/A self _deleted N/A state N/A N/A state obj N/A N/A N/A N/A self identity_map add state N/A enable_relationship_loading N/A N/A self obj N/A N/A N/A Associate an object with this :class:`.Session` for related
        object loading.

        .. warning::

            :meth:`.enable_relationship_loading` exists to serve special
            use cases and is not recommended for general use.

        Accesses of attributes mapped with :func:`.relationship`
        will attempt to load a value from the database using this
        :class:`.Session` as the source of connectivity.  The values
        will be loaded based on foreign key values present on this
        object - it follows that this functionality
        generally only works for many-to-one-relationships.

        The object will be attached to this session, but will
        **not** participate in any persistence operations; its state
        for almost all purposes will remain either "transient" or
        "detached", except for the case of relationship loading.

        Also note that backrefs will often not work as expected.
        Altering a relationship-bound attribute on the target object
        may not fire off a backref event, if the effective value
        is what was already loaded from a foreign-key-holding value.

        The :meth:`.Session.enable_relationship_loading` method is
        similar to the ``load_on_pending`` flag on :func:`.relationship`.
        Unlike that flag, :meth:`.Session.enable_relationship_loading` allows
        an object to remain transient while still being able to load
        related items.

        To make a transient object associated with a :class:`.Session`
        via :meth:`.Session.enable_relationship_loading` pending, add
        it to the :class:`.Session` using :meth:`.Session.add` normally.

        :meth:`.Session.enable_relationship_loading` does not improve
        behavior when the ORM is used normally - object references should be
        constructed at the object level, not at the foreign key level, so
        that they are present in an ordinary way before flush()
        proceeds.  This method is not intended for general use.

        .. versionadded:: 0.8

        .. seealso::

            ``load_on_pending`` at :func:`.relationship` - this flag
            allows per-relationship loading of many-to-ones on items that
            are pending.

         N/A state N/A N/A attributes instance_state obj N/A N/A N/A self _attach state include_before True N/A N/A state _load_pending True N/A _before_attach N/A N/A self state N/A N/A N/A N/A N/A N/A state session_id N/A self hash_key N/A N/A self dispatch before_attach N/A N/A N/A N/A N/A self dispatch before_attach self N/A N/A state obj N/A _attach N/A N/A self state include_before N/A False N/A N/A N/A N/A state key N/A N/A state key N/A self identity_map N/A N/A N/A N/A self identity_map contains_state state N/A N/A N/A N/A sa_exc InvalidRequestError N/A Can't attach instance %s; another instance with key %s is already present in this session. N/A N/A state_str state N/A state key N/A N/A N/A state session_id N/A N/A state session_id N/A self hash_key N/A N/A state session_id _sessions N/A N/A N/A N/A sa_exc InvalidRequestError N/A Object '%s' is already attached to session '%s' (this is '%s') N/A N/A state_str state N/A state session_id N/A self hash_key N/A N/A N/A state session_id N/A self hash_key N/A N/A N/A include_before N/A N/A self dispatch before_attach N/A N/A N/A N/A N/A self dispatch before_attach self N/A N/A state obj N/A N/A state session_id N/A self hash_key N/A N/A N/A state modified N/A N/A state _strong_obj None N/A N/A N/A state _strong_obj N/A N/A state obj N/A N/A N/A self dispatch after_attach N/A N/A N/A N/A N/A self dispatch after_attach self N/A N/A state obj N/A __contains__ N/A N/A self instance N/A N/A N/A Return True if the instance is associated with this session.

        The instance may be pending or persistent within the Session for a
        result of True.

         N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A self _contains_state state N/A __iter__ N/A N/A self N/A N/A N/A Iterate over all pending or persistent instances within this
        Session.

         N/A N/A iter N/A N/A list N/A N/A N/A self _new values N/A list N/A N/A N/A self identity_map values N/A _contains_state N/A N/A self state N/A N/A N/A N/A N/A state N/A self _new N/A N/A N/A self identity_map contains_state state N/A flush N/A N/A self objects N/A None N/A N/A Flush all the object changes to the database.

        Writes out all pending object creations, deletions and modifications
        to the database as INSERTs, DELETEs, UPDATEs, etc.  Operations are
        automatically ordered by the Session's unit of work dependency
        solver.

        Database operations will be issued in the current transactional
        context and do not affect the state of the transaction, unless an
        error occurs, in which case the entire transaction is rolled back.
        You may flush() as often as you like within a transaction to move
        changes from Python to the database's transaction buffer.

        For ``autocommit`` Sessions with no active manual transaction, flush()
        will create a transaction on the fly that surrounds the entire set of
        operations int the flush.

        :param objects: Optional; restricts the flush operation to operate
          only on elements that are in the given collection.

          This feature is for an extremely narrow set of use cases where
          particular objects may need to be operated upon before the
          full flush() occurs.  It is not intended for general use.

         N/A N/A self _flushing N/A N/A N/A N/A sa_exc InvalidRequestError Session is already flushing N/A N/A N/A self _is_clean N/A N/A N/A N/A N/A N/A self _flushing True N/A N/A N/A self _flush objects N/A N/A N/A self _flushing False N/A _flush_warning N/A N/A self method N/A N/A N/A N/A N/A util warn N/A Usage of the '%s' operation is not currently supported within the execution stage of the flush process. Results may not be consistent.  Consider using alternative event listeners or connection-level operations instead. method N/A _is_clean N/A N/A self N/A N/A N/A N/A N/A N/A N/A N/A self identity_map check_modified N/A N/A self _deleted N/A N/A self _new N/A _flush N/A N/A self objects N/A None N/A N/A dirty N/A self _dirty_states N/A N/A N/A dirty N/A N/A self _deleted N/A N/A self _new N/A N/A N/A N/A N/A N/A self identity_map _modified clear N/A N/A flush_context N/A UOWTransaction self N/A N/A N/A self dispatch before_flush N/A N/A N/A N/A N/A self dispatch before_flush self flush_context objects N/A dirty N/A self _dirty_states N/A deleted N/A set N/A self _deleted N/A new N/A set N/A self _new N/A dirty N/A N/A N/A set dirty difference deleted N/A objects N/A N/A objset N/A set N/A o objects N/A N/A N/A N/A state N/A N/A attributes instance_state o N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError o N/A N/A N/A objset add state N/A N/A objset None N/A processed N/A set N/A objset N/A N/A proc N/A N/A N/A N/A N/A N/A new union dirty intersection objset difference deleted N/A N/A proc N/A N/A N/A N/A new union dirty difference deleted N/A state proc N/A N/A is_orphan N/A N/A N/A N/A _state_mapper state _is_orphan state N/A state has_identity N/A N/A N/A flush_context register_object state isdelete is_orphan N/A N/A N/A processed add state N/A objset N/A N/A proc N/A N/A N/A N/A deleted intersection objset difference processed N/A N/A proc N/A N/A deleted difference processed N/A state proc N/A N/A N/A N/A flush_context register_object state isdelete True N/A N/A N/A flush_context has_work N/A N/A N/A N/A flush_context transaction transaction N/A N/A self begin subtransactions True N/A N/A N/A N/A self _warn_on_events True N/A N/A N/A N/A N/A flush_context execute N/A N/A N/A self _warn_on_events False N/A N/A N/A N/A self dispatch after_flush self flush_context N/A N/A N/A flush_context finalize_flush_changes N/A N/A N/A objects N/A N/A self identity_map _modified N/A N/A len_ N/A len N/A N/A self identity_map _modified N/A N/A N/A N/A statelib InstanceState _commit_all_states N/A N/A state N/A state dict N/A state N/A N/A self identity_map _modified instance_dict N/A self identity_map N/A N/A N/A util warn N/A Attribute history events accumulated on %d previously clean instances within inner-flush event handlers have been reset, and will not result in database updates. Consider using set_committed_value() within inner-flush event handlers to avoid this warning. len_ N/A N/A N/A N/A self dispatch after_flush_postexec self flush_context N/A N/A N/A transaction commit N/A N/A N/A N/A N/A N/A util safe_reraise N/A N/A N/A N/A transaction rollback _capture_exception True N/A is_modified N/A N/A self instance include_collections passive N/A True True N/A N/A Return ``True`` if the given instance has locally
        modified attributes.

        This method retrieves the history for each instrumented
        attribute on the instance and performs a comparison of the current
        value to its previously committed value, if any.

        It is in effect a more expensive and accurate
        version of checking for the given instance in the
        :attr:`.Session.dirty` collection; a full test for
        each attribute's net "dirty" status is performed.

        E.g.::

            return session.is_modified(someobject)

        .. versionchanged:: 0.8
            When using SQLAlchemy 0.7 and earlier, the ``passive``
            flag should **always** be explicitly set to ``True``,
            else SQL loads/autoflushes may proceed which can affect
            the modified state itself:
            ``session.is_modified(someobject, passive=True)``\ .
            In 0.8 and above, the behavior is corrected and
            this flag is ignored.

        A few caveats to this method apply:

        * Instances present in the :attr:`.Session.dirty` collection may
          report ``False`` when tested with this method.  This is because
          the object may have received change events via attribute mutation,
          thus placing it in :attr:`.Session.dirty`, but ultimately the state
          is the same as that loaded from the database, resulting in no net
          change here.
        * Scalar attributes may not have recorded the previously set
          value when a new value was applied, if the attribute was not loaded,
          or was expired, at the time the new value was received - in these
          cases, the attribute is assumed to have a change, even if there is
          ultimately no net change against its database value. SQLAlchemy in
          most cases does not need the "old" value when a set event occurs, so
          it skips the expense of a SQL call if the old value isn't present,
          based on the assumption that an UPDATE of the scalar value is
          usually needed, and in those few cases where it isn't, is less
          expensive on average than issuing a defensive SELECT.

          The "old" value is fetched unconditionally upon set only if the
          attribute container has the ``active_history`` flag set to ``True``.
          This flag is set typically for primary key attributes and scalar
          object references that are not a simple many-to-one.  To set this
          flag for any arbitrary mapped column, use the ``active_history``
          argument with :func:`.column_property`.

        :param instance: mapped instance to be tested for pending changes.
        :param include_collections: Indicates if multivalued collections
         should be included in the operation.  Setting this to ``False`` is a
         way to detect only local-column based properties (i.e. scalar columns
         or many-to-one foreign keys) that would result in an UPDATE for this
         instance upon flush.
        :param passive:
         .. versionchanged:: 0.8
             Ignored for backwards compatibility.
             When using SQLAlchemy 0.7 and earlier, this flag should always
             be set to ``True``.

         N/A state N/A object_state instance N/A N/A N/A state modified N/A N/A False N/A dict_ N/A state dict N/A attr N/A N/A state manager attributes N/A N/A N/A N/A N/A include_collections N/A hasattr N/A attr impl get_collection N/A N/A hasattr N/A attr impl get_history N/A N/A N/A N/A added unchanged deleted N/A N/A N/A attr impl get_history state dict_ passive N/A attributes NO_CHANGE N/A N/A added deleted N/A N/A True N/A N/A False N/A is_active N/A N/A self N/A N/A N/A True if this :class:`.Session` is in "transaction mode" and
        is not in "partial rollback" state.

        The :class:`.Session` in its default mode of ``autocommit=False``
        is essentially always in "transaction mode", in that a
        :class:`.SessionTransaction` is associated with it as soon as
        it is instantiated.  This :class:`.SessionTransaction` is immediately
        replaced with a new one as soon as it is ended, due to a rollback,
        commit, or close operation.

        "Transaction mode" does *not* indicate whether
        or not actual database connection resources are in use;  the
        :class:`.SessionTransaction` object coordinates among zero or more
        actual database transactions, and starts out with none, accumulating
        individual DBAPI connections as different data sources are used
        within its scope.   The best way to track when a particular
        :class:`.Session` has actually begun to use DBAPI resources is to
        implement a listener using the :meth:`.SessionEvents.after_begin`
        method, which will deliver both the :class:`.Session` as well as the
        target :class:`.Connection` to a user-defined event listener.

        The "partial rollback" state refers to when an "inner" transaction,
        typically used during a flush, encounters an error and emits a
        rollback of the DBAPI connection.  At this point, the
        :class:`.Session` is in "partial rollback" and awaits for the user to
        call :meth:`.Session.rollback`, in order to close out the
        transaction stack.  It is in this "partial rollback" period that the
        :attr:`.is_active` flag returns False.  After the call to
        :meth:`.Session.rollback`, the :class:`.SessionTransaction` is
        replaced with a new one and :attr:`.is_active` returns ``True`` again.

        When a :class:`.Session` is used in ``autocommit=True`` mode, the
        :class:`.SessionTransaction` is only instantiated within the scope
        of a flush call, or when :meth:`.Session.begin` is called.  So
        :attr:`.is_active` will always be ``False`` outside of a flush or
        :meth:`.Session.begin` block in this mode, and will be ``True``
        within the :meth:`.Session.begin` block as long as it doesn't enter
        "partial rollback" state.

        From all the above, it follows that the only purpose to this flag is
        for application frameworks that wish to detect is a "rollback" is
        necessary within a generic error handling routine, for
        :class:`.Session` objects that would otherwise be in
        "partial rollback" mode.  In a typical integration case, this is also
        not necessary as it is standard practice to emit
        :meth:`.Session.rollback` unconditionally within the outermost
        exception catch.

        To track the transactional state of a :class:`.Session` fully,
        use event listeners, primarily the :meth:`.SessionEvents.after_begin`,
        :meth:`.SessionEvents.after_commit`,
        :meth:`.SessionEvents.after_rollback` and related events.

         N/A N/A N/A self transaction N/A N/A self transaction is_active N/A property N/A identity_map None N/A A mapping of object identities to objects themselves.

    Iterating through ``Session.identity_map.values()`` provides
    access to the full set of persistent objects (i.e., those
    that have row identity) currently in the session.

    .. seealso::

        :func:`.identity_key` - helper function to produce the keys used
        in this dictionary.

     _dirty_states N/A N/A self N/A N/A N/A The set of all persistent states considered dirty.

        This method returns all states that were modified including
        those that were possibly deleted.

         N/A N/A N/A N/A self identity_map _dirty_states N/A property dirty N/A N/A self N/A N/A N/A The set of all persistent instances considered dirty.

        E.g.::

            some_mapped_object in session.dirty

        Instances are considered dirty when they were modified but not
        deleted.

        Note that this 'dirty' calculation is 'optimistic'; most
        attribute-setting or collection modification operations will
        mark an instance as 'dirty' and place it in this set, even if
        there is no net change to the attribute's value.  At flush
        time, the value of each attribute is compared to its
        previously saved value, and if there's no net change, no SQL
        operation will occur (this is a more expensive operation so
        it's only done at flush time).

        To check if an instance has actionable net changes to its
        attributes, use the :meth:`.Session.is_modified` method.

         N/A N/A N/A util IdentitySet N/A N/A N/A state obj N/A state N/A self _dirty_states N/A state N/A self _deleted N/A property deleted N/A N/A self N/A N/A N/A The set of all instances marked as 'deleted' within this ``Session`` N/A N/A N/A util IdentitySet N/A list N/A N/A N/A self _deleted values N/A property new N/A N/A self N/A N/A N/A The set of all instances marked as 'new' within this ``Session``. N/A N/A N/A util IdentitySet N/A list N/A N/A N/A self _new values N/A property N/A sessionmaker N/A _SessionClassMethods N/A N/A A configurable :class:`.Session` factory.

    The :class:`.sessionmaker` factory generates new
    :class:`.Session` objects when called, creating them given
    the configurational arguments established here.

    e.g.::

        # global scope
        Session = sessionmaker(autoflush=False)

        # later, in a local scope, create and use a session:
        sess = Session()

    Any keyword arguments sent to the constructor itself will override the
    "configured" keywords::

        Session = sessionmaker()

        # bind an individual session to a connection
        sess = Session(bind=connection)

    The class also includes a method :meth:`.configure`, which can
    be used to specify additional keyword arguments to the factory, which
    will take effect for subsequent :class:`.Session` objects generated.
    This is usually used to associate one or more :class:`.Engine` objects
    with an existing :class:`.sessionmaker` factory before it is first
    used::

        # application starts
        Session = sessionmaker()

        # ... later
        engine = create_engine('sqlite:///foo.db')
        Session.configure(bind=engine)

        sess = Session()

    .. seealso:

        :ref:`session_getting` - introductory text on creating
        sessions using :class:`.sessionmaker`.

     __init__ N/A N/A self bind class_ autoflush autocommit expire_on_commit info N/A None Session True False True None kw N/A N/A Construct a new :class:`.sessionmaker`.

        All arguments here except for ``class_`` correspond to arguments
        accepted by :class:`.Session` directly.  See the
        :meth:`.Session.__init__` docstring for more details on parameters.

        :param bind: a :class:`.Engine` or other :class:`.Connectable` with
         which newly created :class:`.Session` objects will be associated.
        :param class_: class to use in order to create new :class:`.Session`
         objects.  Defaults to :class:`.Session`.
        :param autoflush: The autoflush setting to use with newly created
         :class:`.Session` objects.
        :param autocommit: The autocommit setting to use with newly created
         :class:`.Session` objects.
        :param expire_on_commit=True: the expire_on_commit setting to use
         with newly created :class:`.Session` objects.
        :param info: optional dictionary of information that will be available
         via :attr:`.Session.info`.  Note this dictionary is *updated*, not
         replaced, when the ``info`` parameter is specified to the specific
         :class:`.Session` construction operation.

         .. versionadded:: 0.9.0

        :param \**kw: all other keyword arguments are passed to the
         constructor of newly created :class:`.Session` objects.

         N/A N/A kw N/A bind bind N/A N/A kw N/A autoflush autoflush N/A N/A kw N/A autocommit autocommit N/A N/A kw N/A expire_on_commit expire_on_commit N/A N/A info None N/A N/A N/A kw N/A info info N/A N/A self kw kw N/A N/A self class_ N/A type N/A class_ __name__ N/A class_ N/A N/A __call__ N/A N/A self N/A local_kw N/A N/A Produce a new :class:`.Session` object using the configuration
        established in this :class:`.sessionmaker`.

        In Python, the ``__call__`` method is invoked on an object when
        it is "called" in the same way as a function::

            Session = sessionmaker()
            session = Session()  # invokes sessionmaker.__call__()

         N/A N/A k v N/A N/A N/A self kw items N/A N/A N/A N/A k info N/A info local_kw N/A N/A d N/A N/A v copy N/A N/A N/A d update N/A local_kw N/A info N/A N/A local_kw N/A info d N/A N/A N/A N/A local_kw setdefault k v N/A N/A N/A self class_ local_kw N/A configure N/A N/A self N/A new_kw N/A N/A (Re)configure the arguments for this sessionmaker.

        e.g.::

            Session = sessionmaker()

            Session.configure(bind=create_engine('sqlite://'))
         N/A N/A N/A N/A self kw update new_kw N/A __repr__ N/A N/A self N/A N/A N/A N/A %s(class_=%r,%s) N/A N/A N/A self __class__ __name__ N/A N/A self class_ __name__ N/A N/A ,  join N/A N/A %s=%r N/A k v N/A N/A k v N/A N/A N/A self kw items N/A N/A make_transient N/A N/A instance N/A N/A N/A Make the given instance 'transient'.

    This will remove its association with any
    session and additionally will remove its "identity key",
    such that it's as though the object were newly constructed,
    except retaining its values.   It also resets the
    "deleted" flag on the state if this object
    had been explicitly deleted by its session.

    Attributes which were "expired" or deferred at the
    instance level are reverted to undefined, and
    will not trigger any loads.

     N/A state N/A N/A attributes instance_state instance N/A s N/A _state_session state N/A s N/A N/A N/A N/A s _expunge_state state N/A N/A N/A N/A state callables clear N/A N/A state key N/A N/A N/A state key N/A N/A state deleted N/A N/A N/A state deleted N/A make_transient_to_detached N/A N/A instance N/A N/A N/A Make the given transient instance 'detached'.

    All attribute history on the given instance
    will be reset as though the instance were freshly loaded
    from a query.  Missing attributes will be marked as expired.
    The primary key attributes of the object, which are required, will be made
    into the "key" of the instance.

    The object can then be added to a session, or merged
    possibly with the load=False flag, at which point it will look
    as if it were loaded that way, without emitting SQL.

    This is a special use case function that differs from a normal
    call to :meth:`.Session.merge` in that a given persistent state
    can be manufactured without any SQL calls.

    .. versionadded:: 0.9.5

    .. seealso::

        :func:`.make_transient`

     N/A state N/A N/A attributes instance_state instance N/A N/A N/A state session_id N/A state key N/A N/A N/A N/A sa_exc InvalidRequestError Given object must be transient N/A N/A state key N/A N/A N/A state mapper _identity_key_from_state state N/A N/A state deleted N/A N/A N/A state deleted N/A N/A N/A state _commit_all N/A state dict N/A N/A N/A state _expire_attributes N/A state dict N/A state unloaded N/A object_session N/A N/A instance N/A N/A N/A Return the :class:`.Session` to which the given instance belongs.

    This is essentially the same as the :attr:`.InstanceState.session`
    accessor.  See that attribute for details.

     N/A N/A N/A state N/A N/A attributes instance_state instance N/A N/A N/A N/A exc NO_STATE N/A N/A N/A N/A exc UnmappedInstanceError instance N/A N/A N/A _state_session state N/A N/A _new_sessionid N/A N/A util counter