U if@sPddlZddlmZdZedZedZGdddeZd d d Zd d dZ dS)N) ElementTreez!{http://www.w3.org/2001/XInclude}includeZfallbackc@s eZdZdS)FatalIncludeErrorN)__name__ __module__ __qualname__r r =/opt/alt/python38/lib64/python3.8/xml/etree/ElementInclude.pyr>src Cs\|dkr.t|d}t|}W5QRXn*|s6d}t|d|d}|}W5QRX|S)NxmlrbzUTF-8r)encoding)openrparseZgetrootread)hrefrrfiledatar r r default_loaderMs rcCsh|dkr t}d}|t|krd||}|jtkr4|d}|dd}|dkr|||}|dkrrtd||ft|}|jr|jpd|j|_|||<n|dkr&||||d}|dkrtd||f|r||d }|jpd||jpd|_n|jpd||jpd|_||=qn td |n&|jt krPtd |jn t |||d }qdS) Nrrrr zcannot load %r as %rtextrrz)unknown parse type in xi:include tag (%r)z0xi:fallback tag must be child of xi:include (%r)) rlentagXINCLUDE_INCLUDEgetrcopytailrXINCLUDE_FALLBACKr)elemloaderierrZnoderr r r rcsN            )N)N) rrrZXINCLUDErr SyntaxErrorrrrr r r r 3s