Module ImportFrom alias Import alias ImportFrom alias alias ImportFrom alias alias alias alias ImportFrom alias alias ImportFrom alias ImportFrom alias alias Import alias alias ImportFrom alias FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If Call NameLoad NameLoad NameLoad body Return NameLoad orelse If Call NameLoad NameLoad NameLoad body Assign NameStore NameLoad orelse Assign NameStore Call AttributeLoad NameLoad attr Str Assign NameStore Call NameLoad NameLoad If NameLoad body Return Call NameLoad NameLoad NameLoad Raise NameLoad NameLoad decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign AttributeStore NameLoad attr AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Dict Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr If BoolOpAnd NameLoad Call NameLoad NameLoad NameLoad body If UnaryOpNot NameLoad body Assign AttributeStore NameLoad attr AttributeStore NameLoad attr NameLoad orelse Assign AttributeStore NameLoad attr NameLoad If Call NameLoad NameLoad NameLoad body Assign AttributeStore NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad Str If CompareIs AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call NameLoad Str attr Call NameLoad NameLoad NameLoad AttributeLoad NameLoad attr orelse Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr orelse If Call NameLoad NameLoad NameLoad body Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr orelse Raise Call AttributeLoad NameLoad attr Call AttributeLoad Str attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If BoolOpAnd UnaryOpNot Call NameLoad NameLoad Str NameLoad AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr If UnaryOpNot NameLoad body Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr attr Assign SubscriptStore NameLoad Index Str AttributeLoad NameLoad attr Delete SubscriptDel NameLoad Index Str Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr orelse Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str keyword Num If UnaryOpNot NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call NameLoad Str attr Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad If BoolOpAnd CompareEq AttributeLoad NameLoad attr Str CompareEq AttributeLoad NameLoad attr Str body ImportFrom alias Assign NameStore NameLoad orelse Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr For NameStore NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Dict Str Str Str AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str keyword NameLoad keyword Str If NameLoad body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad orelse Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr ListLoad If Call NameLoad NameLoad Str body Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body If UnaryOpNot Call NameLoad NameLoad Str NameLoad body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot Call AttributeLoad NameLoad attr NameLoad body Expr Call AttributeLoad NameLoad attr BoolOpOr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults Str NameLoad body Expr Str If AttributeLoad AttributeLoad NameLoad attr attr body Return NameLoad Return Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults Str NameLoad body Expr Str If AttributeLoad AttributeLoad NameLoad attr attr body Return NameLoad Return BoolOpOr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad NameLoad keyword NameLoad Call AttributeLoad NameLoad attr NameLoad keyword NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign NameStore Call NameLoad Call AttributeLoad Str attr NameLoad AttributeLoad NameLoad attr BoolOpOr AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr NameLoad Raise Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If AttributeLoad AttributeLoad NameLoad attr attr body Return If CompareNotEq NameLoad NameLoad body Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad If Call NameLoad AttributeLoad NameLoad attr Str Num body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr For NameStore Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Str Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad If Call NameLoad NameLoad Str body Expr Call NameLoad NameLoad Str Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If AttributeLoad AttributeLoad NameLoad attr attr body Return If CompareNotEq NameLoad NameLoad body Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad If BoolOpOr Call AttributeLoad NameLoad attr Str UnaryOpNot Call AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Return Expr Call AttributeLoad NameLoad attr Str Str Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr If CompareNotEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr If AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Return 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 NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str Assign NameStore ListLoad If UnaryOpNot NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad For NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareIn AttributeLoad NameLoad attr BoolOpOr AttributeLoad AttributeLoad NameLoad attr attr ListLoad body Return If NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad AttributeLoad NameLoad attr Str Str Call AttributeLoad Str attr BinOpMult ListLoad Str Call NameLoad NameLoad Call NameLoad BinOpAdd ListLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad orelse Expr Call AttributeLoad AttributeLoad NameLoad attr attr BinOpMod Str TupleLoad AttributeLoad NameLoad attr Str Str TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call NameLoad NameLoad For NameStore Call AttributeLoad NameLoad attr body Expr Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str FunctionDef arguments args defaults body Assign NameStore Call AttributeLoad NameLoad attr For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body If CompareEq NameLoad NameLoad body Assign SubscriptStore NameLoad Index NameLoad Str Return NameLoad decorator_list If CompareEq Call AttributeLoad AttributeLoad NameLoad attr attr Str Str body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr If AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Call NameLoad orelse If BoolOpAnd Call AttributeLoad NameLoad attr UnaryOpNot Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Call AttributeLoad AttributeLoad NameLoad attr attr Call NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str AttributeLoad NameLoad attr For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body If CompareNotEq NameLoad Str body Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str TupleLoad AttributeLoad NameLoad attr NameLoad NameLoad If CompareIn AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr body Delete SubscriptDel AttributeLoad AttributeLoad NameLoad attr attr Index AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad Assign AttributeStore NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr If UnaryOpNot AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr If UnaryOpNot AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr For NameStore Call AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr If UnaryOpNot AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr If UnaryOpNot AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body If CompareEq AttributeLoad NameLoad attr NameLoad body Assign AttributeStore NameLoad attr Num For NameStore Call AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr If Call AttributeLoad NameLoad attr body For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Expr Call AttributeLoad NameLoad attr For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str If BoolOpOr AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr body Return Assign NameStore Call AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr If NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore Call AttributeLoad AttributeLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr attr attr If NameLoad body For NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body If UnaryOpNot Call NameLoad NameLoad Str body Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr ListLoad For NameStore Call AttributeLoad NameLoad attr body If BoolOpAnd CompareIn AttributeLoad NameLoad attr NameLoad CompareGt AttributeLoad NameLoad attr Num AttributeLoad NameLoad attr body If CompareNotIn AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body If UnaryOpNot NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Return CompareIn AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body If AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore AttributeLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr attr orelse Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr Return NameLoad decorator_list FunctionDef arguments args NameParam defaults body If AttributeLoad AttributeLoad NameLoad attr attr body Return Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword NameLoad Expr Call AttributeLoad NameLoad attr NameLoad For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword NameLoad Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr If Call NameLoad NameLoad NameLoad body For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign NameStore NameLoad Assign AttributeStore NameLoad attr Str If UnaryOpNot Call AttributeLoad NameLoad attr Str body If AttributeLoad AttributeLoad NameLoad attr attr body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr Str If BoolOpAnd Call NameLoad NameLoad CompareNotEq Call NameLoad NameLoad Call NameLoad AttributeLoad NameLoad attr body Assign NameStore NameLoad orelse Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad Str attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword NameLoad If UnaryOpNot NameLoad body Expr Call AttributeLoad NameLoad attr Call NameLoad Str orelse Assign NameStore SubscriptLoad NameLoad Index Num Assign NameStore Call NameLoad AttributeLoad NameLoad attr If BoolOpAnd NameLoad CompareNotEq NameLoad Call NameLoad AttributeLoad NameLoad attr body Assign NameStore NameLoad Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr If NameLoad body Expr Call AttributeLoad NameLoad attr BinOpAdd BinOpAdd Call NameLoad Str BinOpMod Str TupleLoad NameLoad AttributeLoad NameLoad attr Call NameLoad Str keyword AttributeLoad NameLoad attr orelse Expr Call AttributeLoad NameLoad attr Num decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str If UnaryOpNot AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr Num If CompareEq NameLoad Num body If CompareEq AttributeLoad NameLoad attr Num body Assign AttributeStore NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Num body Assign AttributeStore NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str orelse Raise AttributeLoad NameLoad attr Call NameLoad Str orelse If CompareEq NameLoad Num body If CompareEq AttributeLoad NameLoad attr Num body Assign AttributeStore NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Num body Assign AttributeStore NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str orelse Raise AttributeLoad NameLoad attr Call NameLoad Str orelse If CompareEq NameLoad Num body Raise AttributeLoad NameLoad attr Call NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str For NameStore Call AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body If AttributeLoad AttributeLoad NameLoad attr attr body Return Expr Call AttributeLoad NameLoad attr For NameStore Call AttributeLoad NameLoad attr body If BoolOpAnd Call AttributeLoad NameLoad attr AttributeLoad Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr attr body Continue Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body If AttributeLoad AttributeLoad NameLoad attr attr body Return Assign NameStore Call AttributeLoad NameLoad attr For NameStore Call AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr If UnaryOpNot NameLoad body Return For TupleStore NameStore NameStore NameLoad body Expr Call NameLoad NameLoad If AttributeLoad AttributeLoad NameLoad attr attr body Print Call AttributeLoad Call AttributeLoad NameLoad attr attr Str Raise Call AttributeLoad NameLoad attr Call AttributeLoad Str attr GeneratorExp SubscriptLoad NameLoad Index Num comprehension NameStore NameLoad decorator_list FunctionDef arguments args NameParam defaults body If AttributeLoad AttributeLoad NameLoad attr attr body Return Assign TupleStore NameStore NameStore Call AttributeLoad NameLoad attr For NameStore Call AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr keyword AttributeLoad AttributeLoad NameLoad attr attr Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num Expr Call AttributeLoad NameLoad attr SubscriptLoad NameLoad Index Num If NameLoad body Assign NameStore Call AttributeLoad Str attr GeneratorExp SubscriptLoad NameLoad Index Num comprehension NameStore NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call NameLoad Str attr NameLoad AttributeLoad NameLoad attr If NameLoad body Assign NameStore Call AttributeLoad Str attr GeneratorExp SubscriptLoad NameLoad Index Num comprehension NameStore NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call NameLoad Str attr NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str Assign NameStore ListLoad For NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str Dict Str Str body If NameLoad body If CompareEq AttributeLoad NameLoad attr NameLoad body Return Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr If Call NameLoad NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Expr Str If CompareIn Str NameLoad body Delete SubscriptDel NameLoad Index Str If BoolOpAnd Call NameLoad NameLoad NameLoad Call NameLoad Call NameLoad NameLoad NameLoad Str body Assign NameStore Lambda arguments args NameParam defaults vararg kwarg Call Call NameLoad NameLoad NameLoad NameLoad NameLoad orelse Assign NameStore Lambda arguments args NameParam defaults vararg kwarg NameLoad Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr Str Return Call Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Return NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr Num Expr Call AttributeLoad NameLoad attr decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr Num Expr Call AttributeLoad NameLoad attr decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr If AttributeLoad AttributeLoad NameLoad attr attr body Return If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str If UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr If UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body Expr Call AttributeLoad NameLoad attr Str orelse If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Str Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Call AttributeLoad Call AttributeLoad NameLoad attr attr Str AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body For NameStore BinOpAdd Call AttributeLoad AttributeLoad NameLoad attr attr Call AttributeLoad AttributeLoad NameLoad attr attr body If Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr body Assign NameStore IfExp CompareEq AttributeLoad NameLoad attr Str AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr If CompareEq AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Str attr keyword NameLoad keyword NameLoad decorator_list Expr Call NameLoad NameLoad For NameStore Call AttributeLoad NameLoad attr body Expr Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If Call NameLoad AttributeLoad NameLoad attr Str NameLoad body Assign AttributeStore NameLoad attr Call AttributeLoad NameLoad attr ListLoad AttributeLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Str Dict Str Str Str AttributeLoad NameLoad attr AttributeLoad NameLoad attr AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr keyword NameLoad If BoolOpAnd UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr Str UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr Str UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr Str body Expr Call AttributeLoad NameLoad attr Str Dict Str AttributeLoad NameLoad attr keyword NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str ImportFrom alias alias If UnaryOpNot AttributeLoad AttributeLoad NameLoad attr attr body Expr Call NameLoad NameLoad keyword Str Expr Call NameLoad NameLoad keyword Str decorator_list FunctionDef arguments args NameParam defaults body Expr Str Assign AttributeStore NameLoad attr NameLoad Return NameLoad decorator_list NameLoad FunctionDef arguments args NameParam defaults body Expr Str FunctionDef arguments args NameParam NameParam defaults body If Call NameLoad NameLoad NameLoad body If UnaryOpNot Call AttributeLoad NameLoad attr Str body Assign AttributeStore NameLoad attr Dict Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad orelse Assign AttributeStore NameLoad attr BoolOpOr NameLoad Call AttributeLoad NameLoad attr Str decorator_list FunctionDef arguments args NameParam defaults vararg body FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Expr Call NameLoad NameLoad Call NameLoad NameLoad NameLoad NameLoad For NameStore NameLoad body Expr Call NameLoad NameLoad Call NameLoad NameLoad NameLoad NameLoad NameLoad Return AttributeLoad NameLoad attr decorator_list Return NameLoad decorator_list FunctionDef arguments args NameParam defaults vararg kwarg body Assign NameStore ListLoad Assign NameStore AttributeLoad NameLoad attr Assign NameStore Call AttributeLoad NameLoad attr For NameStore BinOpAdd Call AttributeLoad Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Dict attr NameLoad ListLoad Call AttributeLoad Call AttributeLoad NameLoad attr Str Dict attr NameLoad ListLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call NameLoad NameLoad NameLoad Return Call NameLoad NameLoad NameLoad NameLoad NameLoad decorator_list Return NameLoad decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Assign NameStore Call NameLoad NameLoad NameLoad NameLoad If UnaryOpNot NameLoad body Raise Call NameLoad Call AttributeLoad Str attr NameLoad orelse If UnaryOpNot Call NameLoad NameLoad Str NameLoad body Raise Call NameLoad Call AttributeLoad Str attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body Expr Str Assign NameStore Dict Str Str Str Call NameLoad Str Call NameLoad Str Call NameLoad Str If UnaryOpNot NameLoad body Assign NameStore NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If UnaryOpNot Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad If AttributeLoad NameLoad attr body Assign NameStore Call NameLoad Call AttributeLoad Str attr AttributeLoad NameLoad attr NameLoad NameLoad NameLoad orelse Assign NameStore Call NameLoad Call AttributeLoad Str attr NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad keyword BoolOpOr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot BoolOpAnd Call NameLoad Call AttributeLoad NameLoad attr NameLoad NameLoad CompareGt Call NameLoad Call AttributeLoad NameLoad attr NameLoad Num body Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Expr Call AttributeLoad NameLoad attr Call AttributeLoad Call NameLoad Str attr NameLoad BoolOpOr NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot NameLoad body Assign NameStore GeneratorExp AttributeLoad NameLoad attr comprehension NameStore Call AttributeLoad AttributeLoad NameLoad attr attr Str Dict Str ListLoad Str ListLoad Str Str Str For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Call NameLoad Call AttributeLoad NameLoad attr NameLoad Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad Str attr keyword AttributeLoad NameLoad attr keyword AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam NameParam NameParam defaults NameLoad NameLoad NameLoad NameLoad body Expr Str Assign NameStore Call AttributeLoad Call AttributeLoad NameLoad attr Dict Str Str Str Str Str Str Str Str Str Str Str BoolOpOr NameLoad AttributeLoad AttributeLoad NameLoad attr attr NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr BoolOpOr NameLoad NameLoad NameLoad NameLoad attr keyword NameLoad Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults NameLoad body Expr Str If UnaryOpNot NameLoad body Assign NameStore AttributeLoad AttributeLoad NameLoad attr attr If AttributeLoad AttributeLoad NameLoad attr attr body If AttributeLoad NameLoad attr body Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr orelse Assign NameStore ListLoad If CompareNotIn NameLoad NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad Expr Call AttributeLoad NameLoad attr Str Call AttributeLoad NameLoad attr NameLoad keyword NameLoad Assign AttributeStore AttributeLoad AttributeLoad NameLoad attr attr attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Return Call AttributeLoad Call AttributeLoad NameLoad attr Call NameLoad AttributeLoad NameLoad attr attr decorator_list FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad NameLoad Str NameLoad If NameLoad body Return Call AttributeLoad NameLoad attr NameLoad orelse Return ListLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body If UnaryOpNot Call AttributeLoad NameLoad attr Str body Expr Call AttributeLoad NameLoad attr Str Dict Assign SubscriptStore Call AttributeLoad NameLoad attr Str Index NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body If BoolOpOr AttributeLoad AttributeLoad NameLoad attr attr UnaryOpNot Call AttributeLoad AttributeLoad NameLoad attr attr Str body Return Assign NameStore Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad AttributeLoad NameLoad attr attr Assign NameStore Call AttributeLoad NameLoad attr AttributeLoad AttributeLoad NameLoad attr attr If UnaryOpNot BoolOpAnd NameLoad NameLoad body Return Expr Call AttributeLoad AttributeLoad NameLoad attr attr Str Dict Str Str Str Str AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad NameLoad decorator_list decorator_list
N/A __future__ unicode_literals N/A frappe frappe _ msgprint frappe.utils flt cstr now get_datetime_str frappe.model.base_document BaseDocument get_controller frappe.model.naming set_new_name werkzeug.exceptions NotFound Forbidden N/A hashlib json frappe.model optional_fields get_doc N/A N/A arg1 arg2 N/A None N/A N/A returns a frappe.model.Document object.

	:param arg1: Document dict or DocType name.
	:param arg2: [optional] document name.

	There are two ways to call `get_doc`

		# will fetch the latest user object (with child table) from the database
		user = get_doc("User", "test@example.com")

		# create a new object
		user = get_doc({
			"doctype":"User"
			"email_id": "test@example.com",
			"user_roles: [
				{"role": "System Manager"}
			]
		})
	 N/A N/A isinstance arg1 BaseDocument N/A N/A arg1 N/A N/A N/A isinstance arg1 basestring N/A N/A doctype arg1 N/A N/A doctype N/A N/A arg1 get doctype N/A controller N/A get_controller doctype N/A controller N/A N/A N/A controller arg1 arg2 N/A ImportError arg1 N/A Document N/A BaseDocument N/A N/A All controllers inherit from `Document`. __init__ N/A N/A self arg1 arg2 N/A None N/A N/A Constructor.

		:param arg1: DocType name as string or document **dict**
		:param arg2: Document name, if `arg1` is DocType name.

		If DocType name and document name are passed, the object will load
		all values (including child documents) from the database.
		 N/A N/A self doctype N/A self name None N/A N/A self _default_new_docs N/A N/A N/A self flags N/A N/A frappe _dict N/A N/A arg1 N/A isinstance arg1 basestring N/A N/A N/A arg2 N/A N/A N/A self doctype N/A self name arg1 N/A N/A N/A self doctype arg1 N/A N/A isinstance arg2 dict N/A N/A N/A self name N/A N/A N/A frappe db get_value arg1 arg2 name N/A N/A N/A self name None N/A N/A N/A N/A frappe throw N/A N/A N/A _ {0} {1} not found format N/A _ arg1 arg2 N/A frappe DoesNotExistError N/A N/A N/A self name arg2 N/A N/A N/A self load_from_db N/A N/A N/A isinstance arg1 dict N/A N/A N/A N/A N/A super Document self __init__ arg1 N/A N/A N/A self init_valid_columns N/A N/A N/A N/A frappe DataError N/A N/A Document({0}, {1}) format arg1 arg2 N/A reload N/A N/A self N/A N/A N/A Reload document from database N/A N/A N/A self load_from_db N/A load_from_db N/A N/A self N/A N/A N/A Load document and children from database and create properties
		from fields N/A N/A N/A N/A getattr self _metaclass False N/A N/A self meta issingle N/A N/A single_doc N/A N/A N/A frappe db get_singles_dict N/A self doctype N/A N/A single_doc N/A N/A single_doc N/A N/A N/A N/A frappe new_doc N/A self doctype as_dict N/A N/A single_doc N/A name N/A self doctype N/A N/A single_doc N/A __islocal N/A N/A N/A N/A super Document self __init__ single_doc N/A N/A N/A self init_valid_columns N/A N/A N/A self _fix_numeric_types N/A N/A d N/A N/A N/A frappe db get_value N/A self doctype N/A self name * as_dict 1 N/A N/A d N/A N/A N/A N/A frappe throw N/A N/A N/A _ {0} {1} not found format N/A _ N/A self doctype N/A self name N/A frappe DoesNotExistError N/A N/A N/A N/A super Document self __init__ d N/A N/A N/A N/A self name DocType N/A N/A self doctype DocType N/A frappe.model.meta doctype_table_fields N/A table_fields doctype_table_fields N/A N/A table_fields N/A N/A N/A self meta get_table_fields N/A df table_fields N/A N/A children N/A N/A N/A frappe db get_values N/A df options N/A parent parenttype parentfield N/A self name N/A self doctype N/A df fieldname * as_dict True order_by idx asc N/A children N/A N/A N/A N/A self set N/A df fieldname children N/A N/A N/A N/A self set N/A df fieldname N/A N/A N/A hasattr self __setup__ N/A N/A N/A N/A self __setup__ N/A get_latest N/A N/A self N/A N/A N/A N/A N/A getattr self latest None N/A N/A N/A self latest N/A N/A frappe get_doc N/A self doctype N/A self name N/A N/A self latest N/A check_permission N/A N/A self permtype permlabel N/A None N/A N/A Raise `frappe.PermissionError` if not permitted N/A N/A N/A N/A self has_permission permtype N/A N/A N/A N/A self raise_no_permission_to N/A permlabel permtype N/A has_permission N/A N/A self permtype verbose N/A read False N/A N/A Call `frappe.has_permission` if `self.flags.ignore_permissions`
		is not set.

		:param permtype: one of `read`, `write`, `submit`, `cancel`, `delete` N/A N/A N/A self flags ignore_permissions N/A N/A True N/A N/A N/A frappe has_permission N/A self doctype permtype self verbose verbose N/A has_website_permission N/A N/A self permtype verbose N/A read False N/A N/A Call `frappe.has_website_permission` if `self.flags.ignore_permissions`
		is not set.

		:param permtype: one of `read`, `write`, `submit`, `cancel`, `delete` N/A N/A N/A self flags ignore_permissions N/A N/A True N/A N/A N/A N/A frappe has_website_permission N/A self doctype permtype self verbose verbose N/A N/A self has_permission permtype verbose verbose N/A raise_no_permission_to N/A N/A self perm_type N/A N/A N/A Raise `frappe.PermissionError`. N/A msg N/A _ N/A N/A No permission to {0} {1} {2} format perm_type N/A self doctype N/A N/A self name N/A N/A N/A frappe msgprint msg N/A N/A N/A frappe PermissionError msg N/A insert N/A N/A self ignore_permissions N/A None N/A N/A Insert the document in the database (as a new document).
		This will check for user permissions and execute `before_insert`,
		`validate`, `on_update`, `after_insert` methods if they are written.

		:param ignore_permissions: Do not check permissions if True. N/A N/A N/A self flags in_print N/A N/A N/A N/A ignore_permissions None N/A N/A N/A N/A self flags ignore_permissions ignore_permissions N/A N/A N/A self set __islocal True N/A N/A N/A self check_permission create N/A N/A N/A self _set_defaults N/A N/A N/A self set_user_and_timestamp N/A N/A N/A self set_docstatus N/A N/A N/A self check_if_latest N/A N/A N/A self run_method before_insert N/A N/A N/A self set_new_name N/A N/A N/A self set_parent_in_children N/A N/A N/A self validate_higher_perm_levels N/A N/A N/A self flags in_insert True N/A N/A N/A self run_before_save_methods N/A N/A N/A self _validate N/A N/A N/A self set_docstatus N/A N/A N/A self flags in_insert False N/A N/A getattr N/A self meta issingle 0 N/A N/A N/A N/A self update_single N/A N/A self get_valid_dict N/A N/A N/A N/A self db_insert N/A d N/A N/A self get_all_children N/A N/A N/A N/A d db_insert N/A N/A N/A self run_method after_insert N/A N/A N/A self flags in_insert True N/A N/A N/A self run_post_save_methods N/A N/A N/A self flags in_insert False N/A N/A hasattr self __islocal N/A N/A N/A delattr self __islocal N/A self N/A save N/A N/A self ignore_permissions N/A None N/A N/A Save the current document in the database in the **DocType**'s table or
		`tabSingles` (for single types).

		This will check for user permissions and execute
		`validate` before updating, `on_update` after updating triggers.

		:param ignore_permissions: Do not check permissions if True. N/A N/A N/A self flags in_print N/A N/A N/A N/A ignore_permissions None N/A N/A N/A N/A self flags ignore_permissions ignore_permissions N/A N/A N/A N/A self get __islocal N/A N/A N/A self get name N/A N/A N/A N/A self insert N/A N/A N/A N/A self check_permission write save N/A N/A N/A self set_user_and_timestamp N/A N/A N/A self set_docstatus N/A N/A N/A self check_if_latest N/A N/A N/A self set_parent_in_children N/A N/A N/A self validate_higher_perm_levels N/A N/A N/A self run_before_save_methods N/A N/A N/A self _action cancel N/A N/A N/A N/A self _validate N/A N/A N/A self _action update_after_submit N/A N/A N/A N/A self validate_update_after_submit N/A N/A N/A self set_docstatus N/A N/A N/A self meta issingle N/A N/A N/A N/A self update_single N/A N/A self get_valid_dict N/A N/A N/A N/A self db_update N/A N/A N/A self update_children N/A N/A N/A self run_post_save_methods N/A self N/A update_children N/A N/A self N/A N/A N/A update child tables N/A df N/A N/A N/A self meta get_table_fields N/A N/A N/A N/A self update_child_table N/A df fieldname df N/A update_child_table N/A N/A self fieldname df N/A None N/A N/A sync child table for given fieldname N/A rows N/A N/A N/A df N/A N/A df N/A N/A N/A self meta get_field fieldname N/A d N/A N/A self get N/A df fieldname N/A N/A N/A N/A d db_update N/A N/A N/A rows append N/A d name N/A N/A N/A df options N/A N/A N/A self flags ignore_children_type N/A N/A N/A N/A rows N/A N/A N/A N/A N/A frappe db sql N/A delete from `tab%s` where parent=%s and parenttype=%s and
				name not in (%s) N/A N/A df options %s %s N/A N/A , join N/A N/A %s N/A len rows N/A tuple N/A N/A N/A self name N/A self doctype rows N/A N/A N/A N/A N/A frappe db sql N/A delete from `tab%s` where parent=%s and parenttype=%s N/A N/A df options %s %s N/A N/A self name N/A self doctype N/A set_new_name N/A N/A self N/A N/A N/A Calls `frappe.naming.se_new_name` for parent and child docs. N/A N/A set_new_name self N/A d N/A N/A self get_all_children N/A N/A N/A set_new_name d N/A set_title_field N/A N/A self N/A N/A N/A Set title field based on template get_values N/A N/A N/A N/A N/A values N/A N/A self as_dict N/A N/A key value N/A N/A values iteritems N/A N/A N/A value None N/A N/A N/A values N/A key N/A values N/A N/A N/A N/A N/A N/A self meta get title_field title N/A N/A df N/A N/A N/A self meta get_field N/A N/A self meta title_field N/A N/A df options N/A N/A N/A N/A self set N/A df fieldname N/A N/A N/A df options format N/A get_values N/A N/A N/A N/A N/A self is_new N/A N/A N/A self get N/A df fieldname N/A df default N/A N/A N/A N/A self set N/A df fieldname N/A N/A N/A df default format N/A get_values N/A update_single N/A N/A self d N/A N/A N/A Updates values for Single type Document in `tabSingles`. N/A N/A N/A N/A frappe db sql delete from tabSingles where doctype=%s N/A self doctype N/A N/A field value N/A N/A d iteritems N/A N/A N/A field doctype N/A N/A N/A N/A N/A frappe db sql insert into tabSingles(doctype, field, value)
					values (%s, %s, %s) N/A N/A self doctype field value N/A N/A N/A self doctype N/A N/A frappe db value_cache N/A N/A N/A N/A N/A frappe db value_cache N/A N/A self doctype N/A set_user_and_timestamp N/A N/A self N/A N/A N/A N/A self _original_modified N/A self modified N/A N/A self modified N/A now N/A N/A self modified_by N/A N/A frappe session user N/A N/A N/A self creation N/A N/A N/A self creation N/A self modified N/A N/A N/A self owner N/A N/A N/A self owner N/A self modified_by N/A d N/A N/A self get_all_children N/A N/A N/A d modified N/A self modified N/A N/A d modified_by N/A self modified_by N/A N/A N/A d owner N/A N/A N/A d owner N/A self owner N/A N/A N/A d creation N/A N/A N/A d creation N/A self creation N/A set_docstatus N/A N/A self N/A N/A N/A N/A N/A self docstatus None N/A N/A N/A self docstatus 0 N/A d N/A N/A self get_all_children N/A N/A N/A d docstatus N/A self docstatus N/A _validate N/A N/A self N/A N/A N/A N/A N/A self _validate_mandatory N/A N/A N/A self _validate_links N/A N/A N/A self _validate_selects N/A N/A N/A self _validate_constants N/A N/A N/A self _validate_length N/A N/A N/A self _sanitize_content N/A children N/A N/A self get_all_children N/A d children N/A N/A N/A N/A d _validate_selects N/A N/A N/A d _validate_constants N/A N/A N/A d _validate_length N/A N/A N/A d _sanitize_content N/A N/A N/A self is_new N/A N/A fieldname optional_fields N/A N/A N/A N/A self set fieldname None N/A N/A N/A self _extract_images_from_text_editor N/A d children N/A N/A N/A N/A d _extract_images_from_text_editor N/A validate_higher_perm_levels N/A N/A self N/A N/A N/A If the user does not have permissions at permlevel > 0, then reset the values to original / default N/A N/A N/A N/A self flags ignore_permissions N/A N/A frappe flags in_install N/A N/A N/A has_access_to N/A N/A self get_permlevel_access N/A high_permlevel_fields N/A N/A N/A self meta get_high_permlevel_fields N/A high_permlevel_fields N/A N/A N/A N/A self reset_values_if_no_permlevel_access has_access_to high_permlevel_fields N/A df N/A N/A N/A self meta get_table_fields N/A N/A high_permlevel_fields N/A N/A N/A N/A N/A frappe get_meta N/A df options meta get_high_permlevel_fields N/A high_permlevel_fields N/A N/A d N/A N/A self get N/A df fieldname N/A N/A N/A N/A d reset_values_if_no_permlevel_access has_access_to high_permlevel_fields N/A get_permlevel_access N/A N/A self N/A N/A N/A N/A N/A hasattr self _has_access_to N/A N/A user_roles N/A N/A frappe get_roles N/A N/A self _has_access_to N/A N/A perm N/A N/A self get_permissions N/A N/A N/A N/A N/A perm role user_roles N/A N/A perm permlevel 0 N/A perm write N/A N/A N/A N/A perm permlevel N/A self _has_access_to N/A N/A N/A N/A N/A self _has_access_to append N/A perm permlevel N/A N/A self _has_access_to N/A has_permlevel_access_to N/A N/A self fieldname df N/A None N/A N/A N/A df N/A N/A df N/A N/A N/A self meta get_field fieldname N/A N/A N/A df permlevel N/A N/A self get_permlevel_access N/A get_permissions N/A N/A self N/A N/A N/A N/A N/A self meta istable N/A N/A permissions N/A N/A N/A frappe get_meta N/A self parenttype permissions N/A N/A permissions N/A N/A self meta permissions N/A permissions N/A _set_defaults N/A N/A self N/A N/A N/A N/A N/A frappe flags in_import N/A N/A N/A new_doc N/A N/A frappe new_doc N/A self doctype as_dict True N/A N/A N/A self update_if_missing new_doc N/A df N/A N/A N/A self meta get_table_fields N/A N/A new_doc N/A N/A frappe new_doc N/A df options as_dict True N/A value N/A N/A self get N/A df fieldname N/A N/A isinstance value list N/A N/A d value N/A N/A N/A N/A d update_if_missing new_doc N/A check_if_latest N/A N/A self N/A N/A N/A Checks if `modified` timestamp provided by document being updated is same as the
		`modified` timestamp in the database. If there is a different, the document has been
		updated in the database after the current copy was read. Will throw an error if
		timestamps don't match.

		Will also validate document transitions (Save > Submit > Cancel) calling
		`self.check_docstatus_transition`. N/A conflict False N/A N/A self _action save N/A N/A N/A N/A self get __islocal N/A N/A N/A N/A self meta issingle N/A N/A modified N/A N/A N/A frappe db get_value N/A self doctype N/A self name modified N/A N/A N/A cstr modified N/A N/A cstr modified N/A cstr N/A self _original_modified N/A N/A conflict True N/A N/A tmp N/A N/A N/A frappe db sql N/A N/A select modified, docstatus from `tab{0}`
					where name = %s for update format N/A self doctype N/A self name as_dict True N/A N/A tmp N/A N/A N/A N/A frappe throw N/A _ Record does not exist N/A N/A tmp N/A tmp N/A 0 N/A modified N/A cstr N/A tmp modified N/A N/A modified N/A modified N/A cstr N/A self _original_modified N/A N/A conflict True N/A N/A N/A self check_docstatus_transition N/A tmp docstatus N/A conflict N/A N/A N/A N/A frappe msgprint N/A N/A N/A _ Error: Document has been modified after you have opened it N/A  (%s, %s).  N/A modified N/A self modified N/A _ Please refresh to get the latest document. raise_exception N/A frappe TimestampMismatchError N/A N/A N/A N/A self check_docstatus_transition 0 N/A check_docstatus_transition N/A N/A self docstatus N/A N/A N/A Ensures valid `docstatus` transition.
		Valid transitions are (number in brackets is `docstatus`):

		- Save (0) > Save (0)
		- Save (0) > Submit (1)
		- Submit (1) > Submit (1)
		- Submit (1) > Cancel (2) N/A N/A N/A self docstatus N/A N/A N/A self docstatus 0 N/A N/A docstatus 0 N/A N/A N/A N/A self docstatus 0 N/A N/A N/A self _action save N/A N/A N/A N/A self docstatus 1 N/A N/A N/A self _action submit N/A N/A N/A self check_permission submit N/A N/A N/A frappe DocstatusTransitionError N/A _ Cannot change docstatus from 0 to 2 N/A N/A N/A docstatus 1 N/A N/A N/A N/A self docstatus 1 N/A N/A N/A self _action update_after_submit N/A N/A N/A self check_permission submit N/A N/A N/A N/A self docstatus 2 N/A N/A N/A self _action cancel N/A N/A N/A self check_permission cancel N/A N/A N/A frappe DocstatusTransitionError N/A _ Cannot change docstatus from 1 to 0 N/A N/A N/A docstatus 2 N/A N/A N/A frappe ValidationError N/A _ Cannot edit cancelled document N/A set_parent_in_children N/A N/A self N/A N/A N/A Updates `parent` and `parenttype` property in all children. N/A d N/A N/A self get_all_children N/A N/A N/A d parent N/A self name N/A N/A d parenttype N/A self doctype N/A validate_update_after_submit N/A N/A self N/A N/A N/A N/A N/A self flags ignore_validate_update_after_submit N/A N/A N/A N/A N/A self _validate_update_after_submit N/A d N/A N/A self get_all_children N/A N/A N/A N/A N/A d is_new N/A N/A N/A N/A self meta get_field N/A d parentfield allow_on_submit N/A N/A N/A N/A N/A d _validate_update_after_submit N/A _validate_mandatory N/A N/A self N/A N/A N/A N/A N/A self flags ignore_mandatory N/A N/A N/A missing N/A N/A self _get_missing_mandatory_fields N/A d N/A N/A self get_all_children N/A N/A N/A N/A missing extend N/A N/A d _get_missing_mandatory_fields N/A N/A missing N/A N/A N/A N/A fieldname msg missing N/A N/A N/A msgprint msg N/A N/A N/A frappe flags print_messages N/A N/A N/A N/A N/A N/A self as_json encode utf-8 N/A N/A N/A frappe MandatoryError N/A N/A ,  join N/A N/A each N/A 0 N/A each missing N/A _validate_links N/A N/A self N/A N/A N/A N/A N/A self flags ignore_links N/A N/A N/A N/A invalid_links cancelled_links N/A N/A self get_invalid_links N/A d N/A N/A self get_all_children N/A N/A result N/A N/A d get_invalid_links is_submittable N/A N/A self meta is_submittable N/A N/A N/A invalid_links extend N/A result N/A 0 N/A N/A N/A cancelled_links extend N/A result N/A 1 N/A invalid_links N/A N/A msg N/A N/A ,  join N/A N/A each N/A 2 N/A each invalid_links N/A N/A N/A frappe throw N/A N/A N/A _ Could not find {0} format msg N/A frappe LinkValidationError N/A cancelled_links N/A N/A msg N/A N/A ,  join N/A N/A each N/A 2 N/A each cancelled_links N/A N/A N/A frappe throw N/A N/A N/A _ Cannot link cancelled document: {0} format msg N/A frappe CancelledLinkError N/A get_all_children N/A N/A self parenttype N/A None N/A N/A Returns all children documents from **Table** type field in a list. N/A ret N/A N/A df N/A N/A N/A self meta get fields N/A fieldtype Table N/A N/A parenttype N/A N/A N/A N/A df options parenttype N/A N/A N/A N/A self get N/A df fieldname N/A value N/A N/A self get N/A df fieldname N/A N/A isinstance value list N/A N/A N/A N/A ret extend value N/A ret N/A run_method N/A N/A self method N/A args kwargs N/A N/A run standard triggers, plus those in hooks N/A N/A flags kwargs N/A N/A N/A kwargs N/A flags N/A N/A N/A hasattr self method N/A hasattr N/A getattr self method __call__ N/A N/A fn N/A N/A N/A self N/A args kwargs N/A N/A getattr self method args kwargs N/A N/A fn N/A N/A N/A self N/A args kwargs None N/A N/A fn __name__ N/A N/A method encode utf-8 N/A N/A N/A N/A Document hook fn self args kwargs N/A whitelist N/A N/A f N/A N/A N/A N/A f whitelisted True N/A f N/A staticmethod submit N/A N/A self N/A N/A N/A Submit the document. Sets `docstatus` = 1, then saves. N/A N/A self docstatus 1 N/A N/A N/A self save N/A N/A whitelist __func__ cancel N/A N/A self N/A N/A N/A Cancel the document. Sets `docstatus` = 2, then saves. N/A N/A self docstatus 2 N/A N/A N/A self save N/A N/A whitelist __func__ delete N/A N/A self N/A N/A N/A Delete document. N/A N/A N/A frappe delete_doc N/A self doctype N/A self name flags N/A self flags N/A run_before_save_methods N/A N/A self N/A N/A N/A Run standard methods before  `INSERT` or `UPDATE`. Standard Methods are:

		- `validate`, `before_save` for **Save**.
		- `validate`, `before_submit` for **Submit**.
		- `before_cancel` for **Cancel**
		- `before_update_after_submit` for **Update after Submit**

		Will also update title_field if set N/A N/A N/A self set_title_field N/A N/A N/A self reset_seen N/A N/A N/A self flags ignore_validate N/A N/A N/A N/A N/A self _action save N/A N/A N/A N/A self run_method validate N/A N/A N/A self run_method before_save N/A N/A N/A N/A self _action submit N/A N/A N/A N/A self run_method validate N/A N/A N/A self run_method before_submit N/A N/A N/A N/A self _action cancel N/A N/A N/A N/A self run_method before_cancel N/A N/A N/A N/A self _action update_after_submit N/A N/A N/A N/A self run_method before_update_after_submit N/A run_post_save_methods N/A N/A self N/A N/A N/A Run standard methods after `INSERT` or `UPDATE`. Standard Methods are:

		- `on_update` for **Save**.
		- `on_update`, `on_submit` for **Submit**.
		- `on_cancel` for **Cancel**
		- `update_after_submit` for **Update after Submit** N/A N/A N/A self _action save N/A N/A N/A N/A self run_method on_update N/A N/A N/A N/A self _action submit N/A N/A N/A N/A self run_method on_update N/A N/A N/A self run_method on_submit N/A N/A N/A N/A self flags ignore_submit_comment N/A N/A N/A N/A self add_comment Submitted N/A N/A N/A N/A self _action cancel N/A N/A N/A N/A self run_method on_cancel N/A N/A N/A self check_no_back_links_exist N/A N/A N/A N/A self flags ignore_submit_comment N/A N/A N/A N/A self add_comment Cancelled N/A N/A N/A N/A self _action update_after_submit N/A N/A N/A N/A self run_method on_update_after_submit N/A N/A N/A self run_method on_change N/A N/A N/A self update_timeline_doc N/A N/A N/A self clear_cache N/A N/A N/A self notify_update N/A N/A self latest None N/A clear_cache N/A N/A self N/A N/A N/A N/A N/A N/A N/A frappe cache hdel last_modified N/A self doctype N/A N/A N/A self clear_linked_with_cache N/A clear_linked_with_cache N/A N/A self N/A N/A N/A cache N/A N/A frappe cache _clear_cache N/A N/A d N/A N/A N/A df N/A N/A N/A N/A d meta get_link_fields N/A N/A N/A d meta get_dynamic_link_fields N/A N/A N/A N/A d get N/A df fieldname N/A N/A doctype N/A N/A N/A df fieldtype Link N/A df options N/A N/A d get N/A df options N/A name N/A N/A d get N/A df fieldname N/A N/A N/A df fieldtype Dynamic Link N/A N/A N/A N/A cache hdel linked_doctypes doctype N/A N/A N/A cache delete_value N/A N/A user:*:linked_with:{doctype}:{name} format doctype doctype name name N/A N/A N/A _clear_cache self N/A d N/A N/A self get_all_children N/A N/A N/A _clear_cache d N/A reset_seen N/A N/A self N/A N/A N/A Clear _seen property and set current user as seen N/A N/A getattr N/A self meta track_seen False N/A N/A N/A self _seen N/A N/A json dumps N/A N/A N/A frappe session user N/A notify_update N/A N/A self N/A N/A N/A Publish realtime that the current document is modified N/A N/A N/A frappe publish_realtime doc_update N/A modified doctype name N/A self modified N/A self doctype N/A self name doctype N/A self doctype docname N/A self name after_commit True N/A N/A N/A N/A N/A N/A self meta get read_only N/A N/A N/A N/A self meta get issingle N/A N/A N/A N/A self meta get istable N/A N/A N/A N/A frappe publish_realtime list_update N/A doctype N/A self doctype after_commit True N/A check_no_back_links_exist N/A N/A self N/A N/A N/A Check if document links to any active document before Cancel. frappe.model.delete_doc check_if_doc_is_linked check_if_doc_is_dynamically_linked N/A N/A N/A N/A self flags ignore_links N/A N/A N/A check_if_doc_is_linked self method Cancel N/A N/A check_if_doc_is_dynamically_linked self method Cancel N/A whitelist N/A N/A f N/A N/A N/A Decorator: Whitelist method to be called remotely via REST API. N/A N/A f whitelisted True N/A f N/A staticmethod hook N/A N/A f N/A N/A N/A Decorator: Make method `hookable` (i.e. extensible by another app).

		Note: If each hooked method returns a value (dict), then all returns are
		collated in one dict and returned. Ideally, don't return values in hookable
		methods, set properties in the document. add_to_return_value N/A N/A self new_return_value N/A N/A N/A N/A isinstance new_return_value dict N/A N/A N/A N/A N/A self get _return_value N/A N/A N/A self _return_value N/A N/A N/A N/A N/A self _return_value update new_return_value N/A N/A N/A self _return_value N/A new_return_value N/A N/A self get _return_value N/A compose N/A N/A fn N/A hooks N/A runner N/A N/A self method N/A args kwargs N/A N/A N/A add_to_return_value self N/A fn self args kwargs N/A f hooks N/A N/A N/A add_to_return_value self N/A f self method args kwargs N/A N/A self _return_value N/A N/A runner N/A composer N/A N/A self N/A args kwargs N/A N/A hooks N/A N/A method N/A f __name__ N/A doc_events N/A N/A frappe get_doc_hooks N/A handler N/A N/A N/A N/A N/A doc_events get N/A self doctype N/A get method N/A N/A N/A N/A N/A doc_events get * N/A get method N/A N/A N/A N/A N/A hooks append N/A N/A frappe get_attr handler N/A composed N/A compose f hooks N/A N/A composed self method args kwargs N/A N/A composer N/A staticmethod is_whitelisted N/A N/A self method N/A N/A N/A fn N/A getattr self method None N/A N/A fn N/A N/A N/A NotFound N/A N/A Method {0} not found format method N/A N/A N/A N/A getattr fn whitelisted False N/A N/A N/A Forbidden N/A N/A Method {0} not whitelisted format method N/A validate_value N/A N/A self fieldname condition val2 doc raise_exception N/A None None N/A N/A Check that value of fieldname should be 'condition' val2
			else throw Exception. N/A error_condition_map N/A in not in ^ N/A _ one of N/A _ none of N/A _ beginning with N/A N/A doc N/A N/A doc self N/A val1 N/A N/A doc get_value fieldname N/A df N/A N/A N/A doc meta get_field fieldname N/A val2 N/A N/A doc cast val2 df N/A N/A N/A N/A frappe compare val1 condition val2 N/A N/A label N/A N/A N/A doc meta get_label fieldname N/A condition_str N/A N/A error_condition_map get condition condition N/A N/A doc parentfield N/A N/A msg N/A _ N/A N/A Incorrect value in row {0}: {1} must be {2} {3} format N/A doc idx label condition_str val2 N/A N/A msg N/A _ N/A N/A Incorrect value: {0} must be {1} {2} format label condition_str val2 N/A N/A msgprint msg raise_exception N/A raise_exception True N/A validate_table_has_rows N/A N/A self parentfield raise_exception N/A None N/A N/A Raise exception if Table field is empty. N/A N/A N/A N/A isinstance N/A N/A self get parentfield list N/A N/A len N/A N/A self get parentfield 0 N/A N/A label N/A N/A N/A self meta get_label parentfield N/A N/A N/A frappe throw N/A N/A N/A _ Table {0} cannot be empty format label N/A raise_exception N/A frappe EmptyTableError N/A round_floats_in N/A N/A self doc fieldnames N/A None N/A N/A Round floats for all `Currency`, `Float`, `Percent` fields for the given doc.

		:param doc: Document whose numeric properties are to be rounded.
		:param fieldnames: [Optional] List of fields to be rounded. N/A N/A fieldnames N/A N/A fieldnames N/A N/A df fieldname N/A df N/A N/A N/A doc meta get fields N/A fieldtype N/A in N/A Currency Float Percent N/A fieldname fieldnames N/A N/A N/A N/A doc set fieldname N/A flt N/A N/A doc get fieldname N/A N/A self precision fieldname N/A doc parentfield N/A get_url N/A N/A self N/A N/A N/A Returns Desk URL for this document. `/desk#Form/{doctype}/{name}` N/A N/A N/A /desk#Form/{doctype}/{name} format doctype N/A self doctype name N/A self name N/A add_comment N/A N/A self comment_type text comment_by link_doctype link_name N/A None None None None N/A N/A Add a comment to this document.

		:param comment_type: e.g. `Comment`. See Communication for more info. N/A comment N/A N/A N/A N/A frappe get_doc N/A doctype communication_type sender comment_type reference_doctype reference_name content link_doctype link_name Communication Comment N/A comment_by N/A N/A frappe session user comment_type N/A self doctype N/A self name N/A text comment_type link_doctype link_name insert ignore_permissions True N/A comment N/A add_seen N/A N/A self user N/A None N/A N/A add the given/current user to list of users who have seen this document (_seen) N/A N/A user N/A N/A user N/A N/A frappe session user N/A N/A N/A self meta track_seen N/A N/A N/A self _seen N/A N/A _seen N/A N/A json loads N/A self _seen N/A N/A _seen N/A N/A N/A user _seen N/A N/A N/A N/A _seen append user N/A N/A N/A self db_set _seen N/A N/A json dumps _seen update_modified False N/A N/A N/A N/A frappe local flags commit True N/A get_signature N/A N/A self N/A N/A N/A Returns signature (hash) for private URL. N/A N/A N/A N/A N/A hashlib sha224 N/A get_datetime_str N/A self creation hexdigest N/A get_liked_by N/A N/A self N/A N/A N/A liked_by N/A getattr self _liked_by None N/A liked_by N/A N/A N/A N/A json loads liked_by N/A N/A N/A N/A set_onload N/A N/A self key value N/A N/A N/A N/A N/A N/A self get __onload N/A N/A N/A N/A self set __onload N/A N/A N/A N/A N/A self get __onload N/A key value N/A update_timeline_doc N/A N/A self N/A N/A N/A N/A N/A N/A frappe flags in_install N/A N/A N/A N/A self meta get timeline_field N/A N/A N/A timeline_doctype N/A N/A N/A self meta get_link_doctype N/A N/A self meta timeline_field N/A timeline_name N/A N/A self get N/A N/A self meta timeline_field N/A N/A N/A timeline_doctype timeline_name N/A N/A N/A N/A N/A N/A frappe db sql update `tabCommunication`
			set timeline_doctype=%(timeline_doctype)s, timeline_name=%(timeline_name)s
			where
				reference_doctype=%(doctype)s and reference_name=%(name)s
				and (timeline_doctype is null or timeline_doctype != %(timeline_doctype)s
					or timeline_name is null or timeline_name != %(timeline_name)s) N/A doctype name timeline_doctype timeline_name N/A self doctype N/A self name timeline_doctype timeline_name N/A N/A