bgC .dZddlmZddlmZddlmZddlmZddlmZddlm Z ddlm Z dd lm Z dd lm Z dd lm Z dd lmZe rdd lmZe e eee efZedZddZGddeZGdde eZdS)z" Hook wrapper "result" utilities. ) annotations) TracebackType)Callable)cast) Generator)Generic)Optional)Tuple)Type) TYPE_CHECKING)TypeVar)NoReturn_Twrap_controllerDGenerator[None, _Result[_T], None] | Generator[None, object, object]msgstrreturnrcZ|j}td|j|j|j|fz)Nzwrap_controller at %r %s:%d %s)gi_code RuntimeErrorco_name co_filenameco_firstlineno)rrcos _/builddir/build/BUILD/cloudlinux-venv-1.0.7/venv/lib/python3.11/site-packages/pluggy/_result.py_raise_wrapfailrs9  B ( :r~r'8# > ?  ceZdZdZdS) HookCallErrorzHook was called incorrectly.N)__name__ __module__ __qualname____doc__rrr r &s&&&&rr czeZdZdZddZedd Zedd ZeddZ ddZ ddZ ddZ dS)_Result_result _exceptionresult _T | None exceptionBaseException | NonerNonec"||_||_dSNr()selfr+r-s r__init__z_Result.__init__-s  #r_ExcInfo | NonecF|j}|dSt|||jfSr1)r*type __traceback__)r2excs rexcinfoz_Result.excinfo5s)o ;4IIsC$56 6rc|jSr1)r*)r2s rr-z_Result.exception=s rfuncCallable[[], _T] _Result[_T]cpd}dx}} |}n#t$r }|}Yd}~nd}~wwxYw|||S)NT) BaseException)clsr;__tracebackhide__r+r-r8s r from_callz_Result.from_callAsd !! TVVFF   IIIIII s69%%%s  )$)rc"||_d|_dS)a,Force the result(s) to ``result``. If the hook was marked as a ``firstresult`` a single value should be set, otherwise set a (modified) list of results. Any exceptions found during invocation will be deleted. This overrides any previous result or exception. Nr()r2r+s r force_resultz_Result.force_resultKs rr?c"d|_||_dS)zForce the result to fail with ``exception``. This overrides any previous result or exception. .. versionadded:: 1.1.0 Nr()r2r-s rforce_exceptionz_Result.force_exceptionWs #rcd}|j}|tt|jS||j)zGet the result(s) for this hook call. If the hook was marked as a ``firstresult`` only a single value will be returned, otherwise a list of results. T)r*rrr)with_tracebackr7)r2rAr8s r get_resultz_Result.get_resultas? !o ;DL)) )$$S%677 7rN)r+r,r-r.rr/)rr4)rr.)r;r<rr=)r+rrr/)r-r?rr/)rr) r!r"r# __slots__r3propertyr9r- classmethodrBrDrFrIr%rrr'r'*s)I$$$$777X7X&&&[&    $$$$ 8 8 8 8 8 8rr'N)rrrrrr)r$ __future__rtypesrtypingrrrrr r r r r rr?_ExcInforr Exceptionr r'r%rrrRs#"""""   m$mXm5LL M WT]]    '''''I'''B8B8B8B8B8gbkB8B8B8B8B8r