Files
ServerSync/lib/invoke/__pycache__/config.cpython-314.pyc

589 lines
53 KiB
Plaintext
Raw Normal View History

2026-02-12 02:28:23 +02:00
+
t<10>i<EFBFBD><69><00><00><><00>^RIt^RIt^RIt^RIt^RIHt^RIHt^RIHtH t H
t
^RIH t ^RI H t HtHtHtHtHtHt^RIHt^RIHtHt^R IHt^R
IHt^R IHtHt^R I H!t!RRlt%!RR4t&!RR]&4t'!RR](4t)RRlt*RRlt+RRlt,RRlt-RRlt.R R!lt/R# ]"d
^R I#H$t!L[i;i)"<22>N)<01>spec_from_loader)<01>PathLike)<03>join<69>splitext<78>
expanduser)<01>
ModuleType)<07>Any<6E>Dict<63>Iterator<6F>Optional<61>Tuple<6C>Type<70>Union)<01> Environment)<02>UnknownFileType<70>UnpicklableConfigMember)<01>Local)<01>WINDOWS)<02>debug<75>yaml)<01>SourceFileLoader)<01>_SourceFileLoaderc<00>^<00>V^8<>dQhR\R\R\\\3,/#)<04><00>name<6D>path<74>return<72><03>strr
r )<01>formats"<22>4/tmp/pip-target-zhdecbcm/lib/python/invoke/config.py<70> __annotate__r"s)<00><00><15><15>c<EFBFBD><15><13><15><14>c<EFBFBD>3<EFBFBD>h<EFBFBD><1E><15>c<00><><00>\PPV4'g/#\RV4p\ R4p\ RV4VnVPV4\V4#)<01>mod) <09>osr<00>existsrrr<00>__spec__<5F> exec_module<6C>vars)rr<00>loaderr%s&& r!<00> load_sourcer,sV<00><00> <0A>7<EFBFBD>7<EFBFBD>><3E>><3E>$<24> <1F> <1F><11> <09> <1D>e<EFBFBD>T<EFBFBD> *<2A>F<EFBFBD>
<14>U<EFBFBD>
<1B>C<EFBFBD>#<23>E<EFBFBD>6<EFBFBD>2<>C<EFBFBD>L<EFBFBD>
<EFBFBD><16><16>s<EFBFBD><1B> <0F><03>9<EFBFBD>r#c<00><>aa<01>]tRt^$toRt]!RP 44];QJd".RRP 44FNK 5M!RRP 444,t]R]!43V3RlRll4t V3RlR lt
V3R
lV3R llt V3R lR lt V3RlRlt V3RlRltV3RlRltV3RlRltV3RlRltV3RlRltV3RlRltV3RlRlt]V3RlRl4t]V3R lR!l4tV3R"lR#ltV3R$lR%ltV3R&lR'ltV3R(lR)ltV3R*lR+ltV3R,lR-ltV3R.lR/ltV3R0lR1ltV3R2lR3lt R4t!Vt"V;t##)5<> DataProxya<79>
Helper class implementing nested dict+attr access for `.Config`.
Specifically, is used both for `.Config` itself, and to wrap any other
dicts assigned as config values (recursively).
.. warning::
All methods (of this object or in subclasses) must take care to
initialize new attributes via ``self._set(name='value')``, or they'll
run into recursion errors!
.. versionadded:: 1.0
z<EFBFBD>
get
has_key
items
iteritems
iterkeys
itervalues
keys
values
c#<08>D"<00>TFpRPV4x<00>K R#5i)z__{}__N)r )<02>.0<EFBFBD>xs& r!<00> <genexpr><3E>DataProxy.<genexpr>As'<00><00><00>
<EFBFBD><10><01> <15>O<EFBFBD>O<EFBFBD>A<EFBFBD> <1E> <1E><10>s<00> z>
cmp
contains
iter
sizeof
Nc<00>h<<01>V^8<>dQhRS[S[S[3,RS[R,RS[S[R3,RR/#)r<00>data<74>rootr.<00>keypath.r)r
rr r r )r <00> __classdict__s"<22>r!r"<00>DataProxy.__annotate__MsH<00><><00> <13> <13><12>3<EFBFBD><03>8<EFBFBD>n<EFBFBD> <13><17>{<7B>#<23> <13><17>s<EFBFBD>C<EFBFBD>x<EFBFBD><1F> <13>
<15> r#c <0C><><00>V!4pVPVR7VPVR7VPVR7V#)a<>
Alternate constructor for 'baby' DataProxies used as sub-dict values.
Allows creating standalone DataProxy objects while also letting
subclasses like `.Config` define their own ``__init__`` without
muddling the two.
:param dict data:
This particular DataProxy's personal data. Required, it's the Data
being Proxied.
:param root:
Optional handle on a root DataProxy/Config which needs notification
on data updates.
:param tuple keypath:
Optional tuple describing the path of keys leading to this
DataProxy's location inside the ``root`` structure. Required if
``root`` was given (and vice versa.)
.. versionadded:: 1.0
<EFBFBD><01>_config<69><01>_root)<01>_keypath<74><01>_set)<05>clsr5r6r7<00>objs&&&& r!<00> from_data<74>DataProxy.from_dataLs:<00><00>:<12>e<EFBFBD><03> <0B><08><08><14><08><1E> <0B><08><08>t<EFBFBD><08><1C> <0B><08><08>'<27><08>"<22><12>
r#c<00>&<<01>V^8<>dQhRS[RS[/#<00>r<00>keyr<00>rr )r r8s"<22>r!r"r9os<00><><00>&<26>&<26>s<EFBFBD>&<26>s<EFBFBD>&r#c
<08><00>VPV4# \d<>YP9d\TPT4u#RP T4p\ TP4Uu.uFq3PR4'dKTNK MuupippTRP \\TPP4444, pTRP T4, p\T4hi;i)z)No attribute or config key found for {!r}<7D>_z
Valid keys: {!r}z
Valid real attributes: {!r}) <0A>_get<65>KeyError<6F>_proxies<65>getattrr<r <00>dir<69> __class__<5F>
startswith<EFBFBD>sorted<65>list<73>keys<79>AttributeError)<05>selfrH<00>errr1<00>attrss&& r!<00> __getattr__<5F>DataProxy.__getattr__os<><00><00>
&<26><17>9<EFBFBD>9<EFBFBD>S<EFBFBD>><3E> !<21><><17> &<26><12>m<EFBFBD>m<EFBFBD>#<23><1E>t<EFBFBD>|<7C>|<7C>S<EFBFBD>1<>1<>=<3D>D<>D<>S<EFBFBD>I<>C<EFBFBD> #<23>D<EFBFBD>N<EFBFBD>N<EFBFBD> 3<>M<> 3<>1<EFBFBD><<3C><<3C><03>;L<>Q<EFBFBD>Q<EFBFBD> 3<><33>M<>E<EFBFBD>M<> <0F>)<29>0<>0<><16>t<EFBFBD>D<EFBFBD>L<EFBFBD>L<EFBFBD>-<2D>-<2D>/<2F>0<>1<><0E> <0E>C<EFBFBD> <10>4<>;<3B>;<3B>E<EFBFBD>B<> B<>C<EFBFBD> <20><13>%<25> %<25> &<26>s"<00><00>1C?<03>(C?<03>.B<06> B<06>A.C?c<00>*<<01>V^8<>dQhRS[RS[RR/#<00>rrH<00>valuerNrI)r r8s"<22>r!r"r9<00>s"<00><><00> ,<2C> ,<2C>s<EFBFBD> ,<2C>3<EFBFBD> ,<2C>4<EFBFBD> ,r#c<08>^<<01>V\V49pV'gW V&R#\SV` W4R#<00>N)rP<00>super<65> __setattr__)rWrHr^<00> has_real_attrrQs&&& <20>r!rb<00>DataProxy.__setattr__<5F>s,<00><><00><1C>s<EFBFBD>4<EFBFBD>y<EFBFBD>(<28> <0A><1C><1E><13>I<EFBFBD> <11>G<EFBFBD> <1F><03> +r#c<00>F<<01>V^8<>dQhRS[S[S[S[3,,/#<00>rr)r r
rr )r r8s"<22>r!r"r9<00>s!<00><><00>"<22>"<22>(<28>4<EFBFBD><03>S<EFBFBD><08>><3E>2<>"r#c<08>,<00>\VP4#r`)<02>iterr<<00>rWs&r!<00>__iter__<5F>DataProxy.__iter__<5F>s<00><00><14>D<EFBFBD>L<EFBFBD>L<EFBFBD>!<21>!r#c<00>&<<01>V^8<>dQhRS[RS[/#)r<00>otherr)<02>object<63>bool)r r8s"<22>r!r"r9<00>s<00><><00> /<2F> /<2F>F<EFBFBD> /<2F>t<EFBFBD> /r#c<08>|<00>\VRR4p\V\4'dTp\VPV8H4#)r<N)rO<00>
isinstance<EFBFBD>dictror<)rWrm<00> other_vals&& r!<00>__eq__<5F>DataProxy.__eq__<5F>s:<00><00> <1C>E<EFBFBD>9<EFBFBD>d<EFBFBD>3<> <09> <16>e<EFBFBD>T<EFBFBD> "<22> "<22><1D>I<EFBFBD><13>D<EFBFBD>L<EFBFBD>L<EFBFBD>I<EFBFBD>-<2D>.<2E>.r#c<00> <<01>V^8<>dQhRS[/#rf)<01>int)r r8s"<22>r!r"r9<00>s<00><><00>!<21>!<21><13>!r#c<08>,<00>\VP4#r`)<02>lenr<ris&r!<00>__len__<5F>DataProxy.__len__<5F>s<00><00><12>4<EFBFBD><<3C><<3C> <20> r#c<00>*<<01>V^8<>dQhRS[RS[RR/#r]<00>r)r r8s"<22>r!r"r9<00>s"<00><><00>0<>0<>s<EFBFBD>0<>3<EFBFBD>0<>4<EFBFBD>0r#c<08>D<00>W PV&VPW4R#r`)r<<00>_track_modification_of)rWrHr^s&&&r!<00> __setitem__<5F>DataProxy.__setitem__<5F>s<00><00>!<21> <0C> <0C>S<EFBFBD><19> <0C>#<23>#<23>C<EFBFBD>/r#c<00>&<<01>V^8<>dQhRS[RS[/#rGrI)r r8s"<22>r!r"r9<00>s<00><><00><1E><1E>s<EFBFBD><1E>s<EFBFBD>r#c<08>$<00>VPV4#r`)rL<00>rWrHs&&r!<00> __getitem__<5F>DataProxy.__getitem__<5F>s<00><00><13>y<EFBFBD>y<EFBFBD><13>~<7E>r#c<00>&<<01>V^8<>dQhRS[RS[/#rGrI)r r8s"<22>r!r"r9<00>s<00><><00><15><15><03><15><03>r#c<08><00>VR9d \V4hVPV,p\V\4'dMV3p\ VR4'dVP
V,p\ VRV4p\PW$VR7pV#)<05> __setstate__r?r>)r5r6r7)r<>) rVr<rqrr<00>hasattrr?rOr.rD)rWrHr^r7r6s&& r!rL<00>DataProxy._get<65>s<><00><00> <0F>#<23> #<23> <20><13>%<25> %<25><14> <0C> <0C>S<EFBFBD>!<21><05> <15>e<EFBFBD>T<EFBFBD> "<22> "<22><1B>f<EFBFBD>G<EFBFBD><16>t<EFBFBD>Z<EFBFBD>(<28>(<28><1E>-<2D>-<2D>'<27>1<><07><1B>4<EFBFBD><17>$<24>/<2F>D<EFBFBD><1D>'<27>'<27>U<EFBFBD>w<EFBFBD>'<27>O<>E<EFBFBD><14> r#c<00>*<<01>V^8<>dQhRS[RS[RR/#<00>r<00>args<67>kwargsrN<>r )r r8s"<22>r!r"r9<00>s"<00><><00>1<>1<>#<23>1<><13>1<><14>1r#c <0C><><00>V'd\P!V.VO5!VP4Fwr4\PWV4K R#)a|
Convenience workaround of default 'attrs are config keys' behavior.
Uses `object.__setattr__` to work around the class' normal proxying
behavior, but is less verbose than using that directly.
Has two modes (which may be combined if you really want):
- ``self._set('attrname', value)``, just like ``__setattr__``
- ``self._set(attname=value)`` (i.e. kwargs), even less typing.
N)rnrb<00>items)rWr<>r<>rHr^s&*, r!rA<00>DataProxy._set<65>s<<00><00> <10> <12> <1E> <1E>t<EFBFBD> +<2B>d<EFBFBD> +<2B> <20>,<2C>,<2C>.<2E>J<EFBFBD>C<EFBFBD> <12> <1E> <1E>t<EFBFBD>%<25> 0<>)r#c<00> <<01>V^8<>dQhRS[/#rfr})r r8s"<22>r!r"r9<00>s<00><><00>H<01>H<01>#<23>Hr#c<08>b<00>RPVPPVP4#)z<{}: {}>)r rQ<00>__name__r<ris&r!<00>__repr__<5F>DataProxy.__repr__<5F>s#<00><00><19> <20> <20><14><1E><1E>!8<>!8<>$<24>,<2C>,<2C>G<>Gr#c<00>&<<01>V^8<>dQhRS[RS[/#rG<00>rro)r r8s"<22>r!r"r9<00>s<00><><00>#<23>#<23><03>#<23><04>#r#c<08><00>WP9#r`r;r<>s&&r!<00> __contains__<5F>DataProxy.__contains__<5F>s<00><00><12>l<EFBFBD>l<EFBFBD>"<22>"r#c<00> <<01>V^8<>dQhRS[/#rf<00>ro)r r8s"<22>r!r"r9<00>s<00><><00>&<26>&<26>$<24>&r#c<08><00>\VR4#r=<00>r<>ris&r!<00>_is_leaf<61>DataProxy._is_leaf<61>s<00><00><16>t<EFBFBD>W<EFBFBD>%<25>%r#c<00> <<01>V^8<>dQhRS[/#rfr<>)r r8s"<22>r!r"r9<00>s<00><><00>(<28>(<28>$<24>(r#c<08><00>\VR4#)<01>_modifyr<79>ris&r!<00>_is_root<6F>DataProxy._is_root<6F>s<00><00><16>t<EFBFBD>Y<EFBFBD>'<27>'r#c<00>$<<01>V^8<>dQhRS[RR/#<00>rrHrNr})r r8s"<22>r!r"r9<00>s<00><><00> D<01> D<01>S<EFBFBD> D<01>T<EFBFBD> Dr#c<08><><00>RpVP'dVPpMVP'dTpVe(VP\ VR\ 44V4R#R#<00>Nr?)r<>r>r<><00>_removerO<00>tuple)rWrH<00>targets&& r!<00>_track_removal_of<6F>DataProxy._track_removal_of<6F>sM<00><00>
<16><06> <0F>=<3D>=<3D>=<3D><19>Z<EFBFBD>Z<EFBFBD>F<EFBFBD> <11>]<5D>]<5D>]<5D><19>F<EFBFBD> <11> <1D> <12>N<EFBFBD>N<EFBFBD>7<EFBFBD>4<EFBFBD><1A>U<EFBFBD>W<EFBFBD>=<3D>s<EFBFBD> C<> r#c<00>*<<01>V^8<>dQhRS[RS[RR/#r]r})r r8s"<22>r!r"r9<00>s'<00><><00>K<01>K<01>#<23>K<01>c<EFBFBD>K<01>d<EFBFBD>Kr#c<08><><00>RpVP'dVPpMVP'dTpVe(VP\ VR\ 44W4R#R#r<>)r<>r>r<>r<>rOr<>)rWrHr^r<>s&&& r!r<00> DataProxy._track_modification_of<6F>sK<00><00><15><06> <0F>=<3D>=<3D>=<3D><19>Z<EFBFBD>Z<EFBFBD>F<EFBFBD> <11>]<5D>]<5D>]<5D><19>F<EFBFBD> <11> <1D> <12>N<EFBFBD>N<EFBFBD>7<EFBFBD>4<EFBFBD><1A>U<EFBFBD>W<EFBFBD>=<3D>s<EFBFBD> J<> r#c<00>$<<01>V^8<>dQhRS[RR/#r<>r})r r8s"<22>r!r"r9<00>s<00><><00>$<24>$<24>s<EFBFBD>$<24>t<EFBFBD>$r#c<08>B<00>VPVVPV4R#r`)r<r<>r<>s&&r!<00> __delitem__<5F>DataProxy.__delitem__<5F>s<00><00> <10>L<EFBFBD>L<EFBFBD><13> <1D> <0C><1E><1E>s<EFBFBD>#r#c<00>$<<01>V^8<>dQhRS[RR/#)rrrNr})r r8s"<22>r!r"r9<00>s<00><><00>+<2B>+<2B><03>+<2B><04>+r#c<08>D<00>W9dWR#\PW4R#r`)rn<00> __delattr__)rWrs&&r!r<><00>DataProxy.__delattr__<5F>s<00><00> <10><<3C><14>
<EFBFBD> <12> <1E> <1E>t<EFBFBD> *r#c<00><<01>V^8<>dQhRR/#<00>rrN<>)r r8s"<22>r!r"r9<00>s<00><><00><1A><1A>t<EFBFBD>r#c<08>N<00>\VP44pVFpWK R#r`)rTrU)rWrUrHs& r!<00>clear<61>DataProxy.clear<61>s!<00><00><13>D<EFBFBD>I<EFBFBD>I<EFBFBD>K<EFBFBD> <20><04><17>C<EFBFBD><14> <09>r#c<00>&<<01>V^8<>dQhRS[RS[/#<00>rr<>rr<>)r r8s"<22>r!r"r9s<00><><00><13><13><13><13><13>r#c<08><><00>T;'dV^,VP9pVPP!V!pV'gV#VPV^,4V#<00>r)r<<00>popr<70>)rWr<><00> key_existed<65>rets&* r!r<><00> DataProxy.popsS<00><00><1A>6<>6<>t<EFBFBD>A<EFBFBD>w<EFBFBD>$<24>,<2C>,<2C>6<> <0B><13>l<EFBFBD>l<EFBFBD><1E><1E><04>%<25><03><1B><16>J<EFBFBD> <0C><1E><1E>t<EFBFBD>A<EFBFBD>w<EFBFBD>'<27><12>
r#c<00> <<01>V^8<>dQhRS[/#rfr<>)r r8s"<22>r!r"r9s<00><><00><13><13><13>r#c<08>j<00>VPP4pVPV^,4V#r<>)r<<00>popitemr<6D>)rWr<>s& r!r<><00>DataProxy.popitems+<00><00><12>l<EFBFBD>l<EFBFBD>"<22>"<22>$<24><03> <0C><1E><1E>s<EFBFBD>1<EFBFBD>v<EFBFBD>&<26><12>
r#c<00>&<<01>V^8<>dQhRS[RS[/#r<>r<>)r r8s"<22>r!r"r9s<00><><00> <13> <13><03> <13><03> r#c<08><><00>T;'dV^,VP9pVPP!V!pV'dV#VwrEVPWE4V#r<>)r<<00>
setdefaultr)rWr<>r<>r<>rH<00>defaults&* r!r<><00>DataProxy.setdefaultsT<00><00><1A>6<>6<>t<EFBFBD>A<EFBFBD>w<EFBFBD>$<24>,<2C>,<2C>6<> <0B><12>l<EFBFBD>l<EFBFBD>%<25>%<25>t<EFBFBD>,<2C><03> <16><16>J<EFBFBD><1C> <0C><03> <0C>#<23>#<23>C<EFBFBD>1<><12>
r#c<00>*<<01>V^8<>dQhRS[RS[RR/#r<>r<>)r r8s"<22>r!r"r9)s"<00><><00> ,<2C> ,<2C>C<EFBFBD> ,<2C>3<EFBFBD> ,<2C>4<EFBFBD> ,r#c<08><00>V'd VP4F wr4W@V&K R#V'dRV^,p\V\4'dVF pWS,W&K R#VFpV^,W^,&K R#R#)rN)r<>rqrr)rWr<>r<>rHr^<00>arg<72>pairs&*, r!<00>update<74>DataProxy.update)sj<00><00> <11>$<24>l<EFBFBD>l<EFBFBD>n<EFBFBD>
<EFBFBD><03>!<21>S<EFBFBD> <09>-<2D> <11><16>q<EFBFBD>'<27>C<EFBFBD><19>#<23>t<EFBFBD>$<24>$<24><1E>C<EFBFBD> #<23><08>D<EFBFBD>I<EFBFBD><1F> <20>D<EFBFBD>$(<28><11>G<EFBFBD>D<EFBFBD>a<EFBFBD><17>M<EFBFBD> <20>r#r<>)$r<><00>
__module__<EFBFBD> __qualname__<5F>__firstlineno__<5F>__doc__r<5F><00>splitrN<00> classmethodrDrZrbrjrtrzr<>r<>rLrAr<>r<><00>propertyr<79>r<>r<>rr<>r<>r<>r<>r<>r<>r<><00>__static_attributes__<5F>__classdictcell__<5F> __classcell__)rQr8s@@r!r.r.$s<><00><><00><00> <08> <0E> <08> <0E><05><07>
<EFBFBD> <10>%<25>
<EFBFBD><08>
<0E><05><07> <10>
<EFBFBD>%<25>%<25>
<EFBFBD><08>
<0E><05><07> <10>
<EFBFBD>
<EFBFBD>
<EFBFBD> <0A>0<11>'+<2B>#(<28>7<EFBFBD> <13> <13><11> <13>D&<26>&<26>( ,<2C> ,<2C>"<22>"<22>
/<2F> /<2F>!<21>!<21>0<>0<><1E><1E><15><15>(1<>1<>"H<01>H<01>#<23>#<23><0E>&<26><0E>&<26><0E>(<28><0E>(<28> D<01> D<01>K<01>K<01>$<24>$<24>+<2B>+<2B><1A><1A>
<13><13>"<13><13>
<13> <13> ,<2C> ,<2C> ,r#r.c<00>a<00>]tRtRtoRtRtRtRt]V3RlRl4t R4V3RlRllt
V3R lR
lt R5V3R lR llt R5V3R lRllt R5V3RlRlltR5V3RlRlltR5V3RlRlltV3RlRltR5V3RlRlltV3RlRltR5V3RlRlltV3RlRltR6V3RlR lltV3R!lR"lt]tV3R#lR$ltV3R%lR&ltV3R'lR(ltV3R)lR*ltR7V3R+lR,lltR7V3R-lR.lltV3R/lR0ltV3R1lR2lt R3t!Vt"R#)8<>Configi9a
Invoke's primary configuration handling class.
See :doc:`/concepts/configuration` for details on the configuration system
this class implements, including the :ref:`configuration hierarchy
<config-hierarchy>`. The rest of this class' documentation assumes
familiarity with that document.
**Access**
Configuration values may be accessed and/or updated using dict syntax::
config['foo']
or attribute syntax::
config.foo
Nesting works the same way - dict config values are turned into objects
which honor both the dictionary protocol and the attribute-access method::
config['foo']['bar']
config.foo.bar
**A note about attribute access and methods**
This class implements the entire dictionary protocol: methods such as
``keys``, ``values``, ``items``, ``pop`` and so forth should all function
as they do on regular dicts. It also implements new config-specific methods
such as `load_system`, `load_collection`, `merge`, `clone`, etc.
.. warning::
Accordingly, this means that if you have configuration options sharing
names with these methods, you **must** use dictionary syntax (e.g.
``myconfig['keys']``) to access the configuration data.
**Lifecycle**
At initialization time, `.Config`:
- creates per-level data structures;
- stores any levels supplied to `__init__`, such as defaults or overrides,
as well as the various config file paths/filename patterns;
- and loads config files, if found (though typically this just means system
and user-level files, as project and runtime files need more info before
they can be found and loaded.)
- This step can be skipped by specifying ``lazy=True``.
At this point, `.Config` is fully usable - and because it pre-emptively
loads some config files, those config files can affect anything that
comes after, like CLI parsing or loading of task collections.
In the CLI use case, further processing is done after instantiation, using
the ``load_*`` methods such as `load_overrides`, `load_project`, etc:
- the result of argument/option parsing is applied to the overrides level;
- a project-level config file is loaded, as it's dependent on a loaded
tasks collection;
- a runtime config file is loaded, if its flag was supplied;
- then, for each task being executed:
- per-collection data is loaded (only possible now that we have
collection & task in hand);
- shell environment data is loaded (must be done at end of process due
to using the rest of the config as a guide for interpreting env var
names.)
At this point, the config object is handed to the task being executed, as
part of its execution `.Context`.
Any modifications made directly to the `.Config` itself after this point
end up stored in their own (topmost) config level, making it easier to
debug final values.
Finally, any *deletions* made to the `.Config` (e.g. applications of
dict-style mutators like ``pop``, ``clear`` etc) are also tracked in their
own structure, allowing the config object to honor such method calls
without mutating the underlying source data.
**Special class attributes**
The following class-level attributes are used for low-level configuration
of the config system itself, such as which file paths to load. They are
primarily intended for overriding by subclasses.
- ``prefix``: Supplies the default value for ``file_prefix`` (directly) and
``env_prefix`` (uppercased). See their descriptions for details. Its
default value is ``"invoke"``.
- ``file_prefix``: The config file 'basename' default (though it is not a
literal basename; it can contain path parts if desired) which is appended
to the configured values of ``system_prefix``, ``user_prefix``, etc, to
arrive at the final (pre-extension) file paths.
Thus, by default, a system-level config file path concatenates the
``system_prefix`` of ``/etc/`` with the ``file_prefix`` of ``invoke`` to
arrive at paths like ``/etc/invoke.json``.
Defaults to ``None``, meaning to use the value of ``prefix``.
- ``env_prefix``: A prefix used (along with a joining underscore) to
determine which environment variables are loaded as the env var
configuration level. Since its default is the value of ``prefix``
capitalized, this means env vars like ``INVOKE_RUN_ECHO`` are sought by
default.
Defaults to ``None``, meaning to use the value of ``prefix``.
.. versionadded:: 1.0
<EFBFBD>invokeNc<00>6<<01>V^8<>dQhRS[S[S[3,/#rf<00>r
rr )r r8s"<22>r!r"<00>Config.__annotate__<5F>s<00><><00>P
<EFBFBD>P
<EFBFBD>T<EFBFBD>#<23>s<EFBFBD>(<28>^<5E>P
r#c <0C><00>\'d"\PPRR4pMRpR/RRbRRbRRbR RbR
R bR R bR /bRR bRRbRR bRR bRR bRRbRRbRRbRVbRRbR./CRR\/RRR RR R!R /R"R#RR$R"R%RR&R R'RR(R /R)R*R //#)+aR
Return the core default settings for Invoke.
Generally only for use by `.Config` internals. For descriptions of
these values, see :ref:`default-values`.
Subclasses may choose to override this method, calling
``Config.global_defaults`` and applying `.merge_dicts` to the result,
to add to or modify these values.
.. versionadded:: 1.0
<EFBFBD>COMSPECzcmd.exez /bin/bash<73>run<75> asynchronousF<73>disown<77>dry<72>echo<68>
echo_stdinN<EFBFBD>encoding<6E>env<6E>
err_stream<EFBFBD>fallbackT<6B>hide<64> in_stream<61>
out_stream<EFBFBD> echo_formatz{command}<30>pty<74> replace_env<6E>shell<6C>warn<72>watchers<72>runners<72>local<61>sudo<64>password<72>promptz[sudo] password: <20>user<65>tasks<6B>auto_dash_names<65>collection_name<6D>dedupe<70>executor_class<73>ignore_unknown_help<6C> search_root<6F>timeouts<74>command)rr&<00>environ<6F>getr)r<>s r!<00>global_defaults<74>Config.global_defaults<74>sf<00><00>" <13>7<EFBFBD><16>J<EFBFBD>J<EFBFBD>N<EFBFBD>N<EFBFBD>9<EFBFBD>i<EFBFBD>8<>E<EFBFBD>
 <20>E<EFBFBD>( <12><0E><1E><05><0E><18>%<25><0E><16>u<EFBFBD><0E><17><05> <0E>
<1D>d<EFBFBD> <0E> <1B>D<EFBFBD> <0E><16>r<EFBFBD><0E><1D>d<EFBFBD><0E><1B>D<EFBFBD><0E><17><04><0E><1C>T<EFBFBD><0E><1D>d<EFBFBD><0E><1E>;<3B><0E><16>u<EFBFBD><0E><1E>u<EFBFBD><0E> <18><15>!<0E>"<17><05>#<0E>$<1B>B<EFBFBD>%<0E>. <16><07><15>'<27> <12><1A>D<EFBFBD><18>-<2D><16><04><0E>
<14>!<21>4<EFBFBD>!<21>7<EFBFBD><18>$<24> <20>$<24>%<25>u<EFBFBD><1D>t<EFBFBD> <0E> <17><19>D<EFBFBD>)<29>o8
<EFBFBD>8
r#c<00><><<01>V^8<>dQhRS[S[S[S[3,,RS[S[S[S[3,,RS[S[,RS[S[,RS[S[,RS[S[,RS[/#)r<00> overrides<65>defaults<74> system_prefix<69> user_prefix<69>project_location<6F> runtime_path<74>lazy)r r
rr rro)r r8s"<22>r!r"r<>s<><00><><00>O<15>O<15><1B>D<EFBFBD><13>c<EFBFBD><18>N<EFBFBD>+<2B>O<15><1B>4<EFBFBD><03>S<EFBFBD><08>><3E>*<2A>O<15> <20><03>}<7D> O<15>
<1E>c<EFBFBD>]<5D> O<15> #<23>8<EFBFBD>,<2C> O<15><1F>x<EFBFBD>(<28>O<15><13>Or#c <0C><><00>VP/R7VPRR7Vf\VP44pVPVR7VP/R7Vf\'gRpVPVR7VPRR7VPRR 7VP/R
7VfR pVPVR 7VPRR 7VPRR7VP/R7VP V4VP
pVf VP pRPVP44pVPVR7VP/R7VPV4Vf/pVPVR7VP/R7VP/R7V'gVP4VP4R#)ao
Creates a new config object.
:param dict defaults:
A dict containing default (lowest level) config data. Default:
`global_defaults`.
:param dict overrides:
A dict containing override-level config data. Default: ``{}``.
:param str system_prefix:
Base path for the global config file location; combined with the
prefix and file suffixes to arrive at final file path candidates.
Default: ``/etc/`` (thus e.g. ``/etc/invoke.yaml`` or
``/etc/invoke.json``).
:param str user_prefix:
Like ``system_prefix`` but for the per-user config file. These
variables are joined as strings, not via path-style joins, so they
may contain partial file paths; for the per-user config file this
often means a leading dot, to make the final result a hidden file
on most systems.
Default: ``~/.`` (e.g. ``~/.invoke.yaml``).
:param str project_location:
Optional directory path of the currently loaded `.Collection` (as
loaded by `.Loader`). When non-empty, will trigger seeking of
per-project config files in this directory.
:param str runtime_path:
Optional file path to a runtime configuration file.
Used to fill the penultimate slot in the config hierarchy. Should
be a full file path to an existing file, not a directory path or a
prefix.
:param bool lazy:
Whether to automatically load some of the lower config levels.
By default (``lazy=False``), ``__init__`` automatically calls
`load_system` and `load_user` to load system and user config files,
respectively.
For more control over what is loaded when, you can say
``lazy=True``, and no automatic loading is done.
.. note::
If you give ``defaults`` and/or ``overrides`` as ``__init__``
kwargs instead of waiting to use `load_defaults` or
`load_overrides` afterwards, those *will* still end up 'loaded'
immediately.
r;)<01>_file_suffixesN<73><01> _defaults<74><01> _collectionz/etc/)<01>_system_prefix)<01> _system_path)<01> _system_found)<01>_systemz~/.)<01> _user_prefix)<01>
_user_path)<01> _user_found)<01>_userz{}_)<01> _env_prefix<69><01>_env<6E><01>
_overrides)<01>_modifications)<01>
_deletions)r<00>yml<6D>json<6F>py) rA<00> copy_dictrr<00>set_project_location<6F>
env_prefix<EFBFBD>prefixr <00>upper<65>set_runtime_path<74>load_base_conf_files<65>merge) rWrrrrrrrr4s &&&&&&&& r!<00>__init__<5F>Config.__init__s<><00><00>D <0A> <09> <09>"<22> <09><1D> <0A> <09> <09>!><3E> <09>?<3F> <14> <1B> <20><14>!5<>!5<>!7<>8<>H<EFBFBD> <0C> <09> <09>H<EFBFBD> <09>%<25> <0A> <09> <09>b<EFBFBD> <09>!<21> <19> <20><17><17>#<23>M<EFBFBD> <0C> <09> <09><1D> <09>/<2F> <0C> <09> <09>t<EFBFBD> <09>$<24> <0A> <09> <09><04> <09>%<25> <0C> <09> <09>"<22> <09><1D> <17> <1E><1F>K<EFBFBD> <0C> <09> <09>{<7B> <09>+<2B> <0C> <09> <09>T<EFBFBD> <09>"<22> <0A> <09> <09>d<EFBFBD> <09>#<23> <0C> <09> <09><02> <09><1B> <0A>!<21>!<21>"2<>3<><1A>_<EFBFBD>_<EFBFBD>
<EFBFBD> <15> <1D><1D><1B><1B>J<EFBFBD><1A>\<5C>\<5C>*<2A>"2<>"2<>"4<>5<>
<EFBFBD> <0C> <09> <09>j<EFBFBD> <09>)<29> <0C> <09> <09>r<EFBFBD> <09><1A> <0A><1D><1D>l<EFBFBD>+<2B> <15> <1C><1A>I<EFBFBD> <0C> <09> <09>Y<EFBFBD> <09>'<27> <0A> <09> <09><12> <09>$<24> <0A> <09> <09>R<EFBFBD> <09> <20><14> <10> %<25> %<25> '<27> <0A>
<EFBFBD>
<EFBFBD> r#c<00><<01>V^8<>dQhRR/#r<>r<>)r r8s"<22>r!r"r<><00>s<00><><00>$<24>$<24>d<EFBFBD>$r#c<08>N<00>VPRR7VPRR7R#)F)r9N)<02> load_system<65> load_userris&r!r8<00>Config.load_base_conf_files<65>s!<00><00> <0C><18><18>u<EFBFBD><18>%<25> <0C><0E><0E>U<EFBFBD><0E>#r#c<00>@<<01>V^8<>dQhRS[S[S[3,RS[RR/#<00>rr5r9rN<>r
rr ro)r r8s"<22>r!r"r<><00>s*<00><><00><19><19>$<24>s<EFBFBD>C<EFBFBD>x<EFBFBD>.<2E><19><14><19><14>r#c <0C>^<00>VPVR7V'dVP4R#R#)a
Set or replace the 'defaults' configuration level, from ``data``.
:param dict data: The config data to load as the defaults level.
:param bool merge:
Whether to merge the loaded data into the central config. Default:
``True``.
:returns: ``None``.
.. versionadded:: 1.0
rN<>rAr9<00>rWr5r9s&&&r!<00> load_defaults<74>Config.load_defaults<74>s#<00><00> <0A> <09> <09>D<EFBFBD> <09>!<21> <10> <10>J<EFBFBD>J<EFBFBD>L<EFBFBD> r#c<00>@<<01>V^8<>dQhRS[S[S[3,RS[RR/#rBrC)r r8s"<22>r!r"r<><00>s*<00><><00><19><19>4<EFBFBD><03>S<EFBFBD><08>><3E><19>$<24><19>$<24>r#c <0C>^<00>VPVR7V'dVP4R#R#)a
Set or replace the 'overrides' configuration level, from ``data``.
:param dict data: The config data to load as the overrides level.
:param bool merge:
Whether to merge the loaded data into the central config. Default:
``True``.
:returns: ``None``.
.. versionadded:: 1.0
r+NrErFs&&&r!<00>load_overrides<65>Config.load_overrides<65>s#<00><00> <0A> <09> <09>T<EFBFBD> <09>"<22> <10> <10>J<EFBFBD>J<EFBFBD>L<EFBFBD> r#c<00>$<<01>V^8<>dQhRS[RR/#<00>rr9rNr<4E>)r r8s"<22>r!r"r<><00>s<00><><00>6<>6<><14>6<><14>6r#c <0C>,<00>VPRVR7R#)aC
Load a system-level config file, if possible.
Checks the configured ``_system_prefix`` path, which defaults to
``/etc``, and will thus load files like ``/etc/invoke.yml``.
:param bool merge:
Whether to merge the loaded data into the central config. Default:
``True``.
:returns: ``None``.
.. versionadded:: 1.0
<EFBFBD>system<65>r5r9N<><01>
_load_file<EFBFBD>rWr9s&&r!r><00>Config.load_system<65>s<00><00> <0A><0F><0F>x<EFBFBD>u<EFBFBD><0F>5r#c<00>$<<01>V^8<>dQhRS[RR/#rNr<>)r r8s"<22>r!r"r<><00>s<00><><00>4<>4<>t<EFBFBD>4<>t<EFBFBD>4r#c <0C>,<00>VPRVR7R#)a<
Load a user-level config file, if possible.
Checks the configured ``_user_prefix`` path, which defaults to ``~/.``,
and will thus load files like ``~/.invoke.yml``.
:param bool merge:
Whether to merge the loaded data into the central config. Default:
``True``.
:returns: ``None``.
.. versionadded:: 1.0
rrQNrRrTs&&r!r?<00>Config.load_user<65>s<00><00> <0A><0F><0F>v<EFBFBD>U<EFBFBD><0F>3r#c<00>$<<01>V^8<>dQhRS[RR/#rNr<>)r r8s"<22>r!r"r<><00>s<00><><00>7<>7<>$<24>7<>$<24>7r#c <0C>,<00>VPRVR7R#)a)
Load a project-level config file, if possible.
Checks the configured ``_project_prefix`` value derived from the path
given to `set_project_location`, which is typically set to the
directory containing the loaded task collection.
Thus, if one were to run the CLI tool against a tasks collection
``/home/myuser/code/tasks.py``, `load_project` would seek out files
like ``/home/myuser/code/invoke.yml``.
:param bool merge:
Whether to merge the loaded data into the central config. Default:
``True``.
:returns: ``None``.
.. versionadded:: 1.0
<EFBFBD>projectrQNrRrTs&&r!<00> load_project<63>Config.load_project<63>s<00><00>( <0A><0F><0F>y<EFBFBD><05><0F>6r#c<00>4<<01>V^8<>dQhRS[S[,RR/#)rrrN)r r)r r8s"<22>r!r"r<><00>s <00><><00> '<27> '<27>X<EFBFBD>h<EFBFBD>%7<> '<27>D<EFBFBD> 'r#c <0C>r<00>VPVR7VP/R7VPRR7R#)z:
Set the runtime config file path.
.. versionadded:: 1.0
)<01> _runtime_path)<01>_runtimeN)<01>_runtime_foundr@)rWrs&&r!r7<00>Config.set_runtime_path<74>s0<00><00> <0A> <09> <09><04> <09>%<25> <0C> <09> <09>2<EFBFBD> <09><1E> <0A> <09> <09><14> <09>&r#c<00>$<<01>V^8<>dQhRS[RR/#rNr<>)r r8s"<22>r!r"r<>s<00><><00>F<01>F<01>$<24>F<01>$<24>Fr#c <0C>.<00>VPRRVR7R#)ap
Load a runtime-level config file, if one was specified.
When the CLI framework creates a `Config`, it sets ``_runtime_path``,
which is a full path to the requested config file. This method attempts
to load that file.
:param bool merge:
Whether to merge the loaded data into the central config. Default:
``True``.
:returns: ``None``.
.. versionadded:: 1.0
<EFBFBD>runtimeT)r5<00>absoluter9NrRrTs&&r!<00> load_runtime<6D>Config.load_runtimes<00><00> <0A><0F><0F>y<EFBFBD>4<EFBFBD>u<EFBFBD><0F>Er#c<00><<01>V^8<>dQhRR/#r<>r<>)r r8s"<22>r!r"r<>s<00><><00><15><15><04>r#c <0C>
<00>\R4VP4\R4\VPVPR7pVP VP 4R7\R4VP4R#)a9
Load values from the shell environment.
`.load_shell_env` is intended for execution late in a `.Config`
object's lifecycle, once all other sources (such as a runtime config
file or per-collection configurations) have been loaded. Loading from
the shell is not terrifically expensive, but must be done at a specific
point in time to ensure the "only known config keys are loaded from the
env" behavior works correctly.
See :ref:`env-vars` for details on this design decision and other info
re: how environment variables are scanned and loaded.
.. versionadded:: 1.0
z*Running pre-merge for shell env loading...zDone with pre-merge.)<02>configr5r)z0Loaded shell environment, triggering final mergeN)rr9rr<r(rA<00>load)rWr+s& r!<00>load_shell_env<6E>Config.load_shell_envs[<00><00>" <0E>:<3A>;<3B> <0C>
<EFBFBD>
<EFBFBD> <0C> <0A>$<24>%<25><1C>D<EFBFBD>L<EFBFBD>L<EFBFBD><14>9I<39>9I<39>J<><06> <0C> <09> <09>v<EFBFBD>{<7B>{<7B>}<7D> <09>%<25> <0A>@<40>A<> <0C>
<EFBFBD>
<EFBFBD> r#c<00>@<<01>V^8<>dQhRS[S[S[3,RS[RR/#rBrC)r r8s"<22>r!r"r<>+s-<00><><00><19><19><18><13>c<EFBFBD><18>N<EFBFBD><19>+/<2F><19> <0A>r#c <0C>t<00>\R4VPVR7V'dVP4R#R#)z<>
Update collection-driven config data.
`.load_collection` is intended for use by the core task execution
machinery, which is responsible for obtaining collection-driven data.
See :ref:`collection-configuration` for details.
.. versionadded:: 1.0
z Loading collection configurationrN)rrAr9rFs&&&r!<00>load_collection<6F>Config.load_collection+s,<00><00> <0E>0<>1<> <0C> <09> <09>d<EFBFBD> <09>#<23> <10> <10>J<EFBFBD>J<EFBFBD>L<EFBFBD> r#c<00><<<01>V^8<>dQhRS[S[S[R3,RR/#)rrNr)rrr)r r8s"<22>r!r"r<><s'<00><><00><1F><1F><15>x<EFBFBD><13>d<EFBFBD>/B<>)C<><1F><04>r#c <0C><><00>RpVe \VR4pVPVR7VPRR7VPRR7VP/R7R#)z<>
Set the directory path where a project-level config file may be found.
Does not do any file loading on its own; for that, see `load_project`.
.. versionadded:: 1.0
N<EFBFBD>)<01>_project_prefix)<01> _project_path)<01>_project_found)<01>_project)rrA)rWr<00>project_prefixs&& r!r3<00>Config.set_project_location<sT<00><00><1E><0E> <0F> <1B>!<21>$<24><02>^<5E>N<EFBFBD> <0C> <09> <09>.<2E> <09>1<> <0C> <09> <09><04> <09>%<25> <0A> <09> <09><14> <09>&<26> <0C> <09> <09>2<EFBFBD> <09>r#c<00>0<<01>V^8<>dQhRS[RS[RS[RR/#)rr5rgr9rNr<4E>)r r8s"<22>r!r"r<>Rs-<00><><00>=<19>=<19><19>=<19>%)<29>=<19>:><3E>=<19> <0A>=r#c <08>6<00>RPV4pRPV4pRPV4pVPpVf VPp\W4eR#V'd\W4pVfR#V.p MS\VRPV44p
V
fR#VPU u.uFp RP W<>,V 34NK p p V F<>p \ V 4p \V 4^,PR4p \VRPV 44pTPYn!T 44TPY\4TPTR4M \W4fVPVR
4R#V'dVP4R#R#uup i \d)Rp\TPX Y<>P44hi;i \d;pTP^8Xd$R p\TPT 44Rp?EKAhRp?ii;i) <0B> _{}_found<6E>_{}_path<74>_{}Nz
_{}_prefix<69>.z_load_{}zUConfig files of type {!r} (from file {!r}) are not supported! Please use one of: {!r}TzDidn't see any {}, skipping.F)r <00> file_prefixr5rOrrrr<00>lstriprVrrA<00>IOError<6F>errnorr9)rWr5rgr9<00>foundrr5<00>midfix<69> absolute_path<74>paths<68> path_prefixr1<00>filepath<74>type_r+<00>msg<73>erXs&&&& r!rS<00>Config._load_fileRs<><00><00><1C>"<22>"<22>6<EFBFBD>*<2A><05><19> <20> <20><16>(<28><04><14>|<7C>|<7C>F<EFBFBD>#<23><04><15>!<21>!<21><06> <11>><3E><19>[<5B>[<5B>F<EFBFBD> <12>4<EFBFBD> <1F> +<2B> <12> <13>#<23>D<EFBFBD>/<2F>M<EFBFBD><1C>$<24><16>"<22>O<EFBFBD>E<EFBFBD>!<21>$<24> <0C>(;<3B>(;<3B>F<EFBFBD>(C<>D<>K<EFBFBD><1B>"<22><16><1E>,<2C>,<2C><0E>,<2C>A<EFBFBD><14><08><08>+<2B>.<2E><01>2<>3<>,<2C> <12><0E>
<1E>H<EFBFBD>!<21>(<28>+<2B>H<EFBFBD> <1A><16>$<24>X<EFBFBD>.<2E>q<EFBFBD>1<>8<>8<><13>=<3D>E<EFBFBD>$<24>T<EFBFBD>:<3A>+<<3C>+<<3C>U<EFBFBD>+C<>D<>F<EFBFBD><15> <09> <09>$<24><06>x<EFBFBD> 0<>1<><14> <09> <09>$<24>)<29><14> <09> <09>%<25><14>&<26><15>#<1E>4 <13>4<EFBFBD> <1E> &<26> <10>I<EFBFBD>I<EFBFBD>e<EFBFBD>U<EFBFBD> #<23> <12> <10>J<EFBFBD>J<EFBFBD>L<EFBFBD><13><>E<0E><>&<26><16>q<>C<EFBFBD>)<29><1B>
<EFBFBD>
<EFBFBD>5<EFBFBD>(<28>4G<34>4G<34>H<><16><16><16><><1B> <1A><14>7<EFBFBD>7<EFBFBD>a<EFBFBD><<3C>8<>C<EFBFBD><19>#<23>*<2A>*<2A>X<EFBFBD>.<2E>/<2F>/<2F><19><>  <1A>s6<00>+"F<04>!<F<02>:G<02>3G<05>G<02> H<05>-H<05>H<05>Hc<00>&<<01>V^8<>dQhRS[RS[/#<00>rrr<00>rr )r r8s"<22>r!r"r<><00>s<00><><00>&<26>&<26>x<EFBFBD>&<26>C<EFBFBD>&r#c<08><><00>\V4;_uu_4p\P!V4uuRRR4# +'giR#;ir`)<03>openr<00> safe_load<61>rWr<00>fds&& r!<00>
_load_yaml<EFBFBD>Config._load_yaml<6D>s%<00><00> <11>$<24>Z<EFBFBD>Z<EFBFBD>2<EFBFBD><17>><3E>><3E>"<22>%<25><18>Z<EFBFBD>Z<EFBFBD>Z<EFBFBD><5A> <00>5<05> A c<00>&<<01>V^8<>dQhRS[RS[/#r<>r<>)r r8s"<22>r!r"r<><00>s<00><><00>!<21>!<21>x<EFBFBD>!<21>C<EFBFBD>!r#c<08><><00>\V4;_uu_4p\P!V4uuRRR4# +'giR#;ir`)r<>r0rmr<>s&& r!<00>
_load_json<EFBFBD>Config._load_json<6F>s$<00><00> <11>$<24>Z<EFBFBD>Z<EFBFBD>2<EFBFBD><17>9<EFBFBD>9<EFBFBD>R<EFBFBD>=<3D><18>Z<EFBFBD>Z<EFBFBD>Z<EFBFBD>r<EFBFBD>c<00><<<01>V^8<>dQhRS[RS[S[S[3,/#r<>r)r r8s"<22>r!r"r<><00>s#<00><><00><14><14>S<EFBFBD><14>T<EFBFBD>#<23>s<EFBFBD>(<28>^<5E>r#c<08><00>/p\RV4P4F^wr4VPR4'dK\V\P
4'dRp\ VPV44hWBV&K` V#)r%<00>__z<5F>'{}' is a module, which can't be used as a config value. (Are you perhaps giving a tasks file instead of a config file by mistake?))r,r<>rRrq<00>typesrrr )rWrr5rHr^rXs&& r!<00>_load_py<70>Config._load_py<70>su<00><00><11><04>&<26>u<EFBFBD>d<EFBFBD>3<>:<3A>:<3A><<3C>J<EFBFBD>C<EFBFBD><13>~<7E>~<7E>d<EFBFBD>#<23>#<23><18> <1A>%<25><15>!1<>!1<>2<>2<>\<02><03>-<2D>c<EFBFBD>j<EFBFBD>j<EFBFBD><13>o<EFBFBD>><3E>><3E><1D><13>I<EFBFBD>=<3D><14> r#c<00><<01>V^8<>dQhRR/#r<>r<>)r r8s"<22>r!r"r<><00>s<00><><00>2<>2<>t<EFBFBD>2r#c <0C><00>\R4VP/R7\RPVP44\ VP
VP4\RPVP 44\ VP
VP 4VPRR4VPRR4VPR R
4\R PVP44\ VP
VP4VPR R 4\RPVP44\ VP
VP4\RPVP44\ VP
VP4\RPVP44\VP
VP4R#)z<
Merge all config sources, in order.
.. versionadded:: 1.0
z9Merging config sources in order onto new empty _config...r;zDefaults: {!r}zCollection-driven: {!r}rPz System-widerzPer-userr[z Per-projectz!Environment variable config: {!r}rf<00>RuntimezOverrides: {!r}zModifications: {!r}zDeletions: {!r}N) rrAr r<00> merge_dictsr<r<00> _merge_filer*r,r-r.<00>
obliterateris&r!r9<00> Config.merge<67>s_<00><00> <0E>I<>J<> <0C> <09> <09>"<22> <09><1D> <0A><1E>%<25>%<25>d<EFBFBD>n<EFBFBD>n<EFBFBD>5<>6<><13>D<EFBFBD>L<EFBFBD>L<EFBFBD>$<24>.<2E>.<2E>1<> <0A>'<27>.<2E>.<2E>t<EFBFBD>/?<3F>/?<3F>@<40>A<><13>D<EFBFBD>L<EFBFBD>L<EFBFBD>$<24>"2<>"2<>3<> <0C><18><18><18>=<3D>1<> <0C><18><18><16><1A>,<2C> <0C><18><18><19>M<EFBFBD>2<> <0A>1<>8<>8<><14><19><19>C<>D<><13>D<EFBFBD>L<EFBFBD>L<EFBFBD>$<24>)<29>)<29>,<2C> <0C><18><18><19>I<EFBFBD>.<2E> <0A><1F>&<26>&<26>t<EFBFBD><EFBFBD><EFBFBD>7<>8<><13>D<EFBFBD>L<EFBFBD>L<EFBFBD>$<24>/<2F>/<2F>2<> <0A>#<23>*<2A>*<2A>4<EFBFBD>+><3E>+><3E>?<3F>@<40><13>D<EFBFBD>L<EFBFBD>L<EFBFBD>$<24>"5<>"5<>6<> <0A><1F>&<26>&<26>t<EFBFBD><EFBFBD><EFBFBD>7<>8<><12>4<EFBFBD><<3C><<3C><14><1F><1F>1r#c<00>*<<01>V^8<>dQhRS[RS[RR/#)rr<00>descrNr})r r8s"<22>r!r"r<><00>s"<00><><00>9<>9<><03>9<>3<EFBFBD>9<>4<EFBFBD>9r#c<08><><00>VR, p\VRPV44p\VRPV44p\VRPV44pVf\RPV44R#V'd4\RPW$V44\VPV4R#\RPV44R#)z config filerr<>r<>Nz${} has not been loaded yet, skippingz {} ({}): {!r}z{} not found, skipping)rOr rr<>r<)rWrr<>r<>rr5s&&& r!r<><00>Config._merge_file<6C>s<><00><00> <0C><0E><1E><04><17><04>k<EFBFBD>0<>0<><14>6<>7<><05><16>t<EFBFBD>Z<EFBFBD>.<2E>.<2E>t<EFBFBD>4<>5<><04><16>t<EFBFBD>U<EFBFBD>\<5C>\<5C>$<24>/<2F>0<><04> <10>=<3D> <11>8<>?<3F>?<3F><04>E<> F<> <12> <11>/<2F>(<28>(<28><14>T<EFBFBD>:<3A> ;<3B> <17><04> <0C> <0C>d<EFBFBD> +<2B>
<12>*<2A>1<>1<>$<24>7<> 8r#c<00>B<<01>V^8<>dQhRS[S[R,,RR/#<00>r<00>intor<6F>r)r r)r r8s"<22>r!r"r<><00>s(<00><><00>V<13>V<13>(<28>4<EFBFBD><08>><3E>2<>V<13>h<EFBFBD>Vr#c <0C><><00>Vf VPMTpV!R/VPVR7BpRP4FrpRPV4p\ W4p\ V\ 4'g)VPV\P!V44K]\\ W44V4Kt VP4VP4V#)a 
Return a copy of this configuration object.
The new object will be identical in terms of configured sources and any
loaded (or user-manipulated) data, but will be a distinct object with
as little shared mutable state as possible.
Specifically, all `dict` values within the config are recursively
recreated, with non-dict leaf values subjected to `copy.copy` (note:
*not* `copy.deepcopy`, as this can cause issues with various objects
such as compiled regexen or threading locks, often found buried deep
within rich aggregates like API or DB clients).
The only remaining config values that may end up shared between a
config and its clone are thus those 'rich' objects that do not
`copy.copy` cleanly, or compound non-dict objects (such as lists or
tuples).
:param into:
A `.Config` subclass that the new clone should be "upgraded" to.
Used by client libraries which have their own `.Config` subclasses
that e.g. define additional defaults; cloning "into" one of these
subclasses ensures that any new keys/subtrees are added gracefully,
without overwriting anything that may have been pre-defined.
Default: ``None`` (just clone into another regular `.Config`).
:returns:
A `.Config`, or an instance of the class given to ``into``.
.. versionadded:: 1.0
)r<>a<>
collection
system_prefix
system_path
system_found
system
user_prefix
user_path
user_found
user
project_prefix
project_path
project_found
project
env_prefix
env
runtime_path
runtime_found
runtime
overrides
modifications
r<>r<>) rQ<00>_clone_init_kwargsr<73>r rOrqrrrA<00>copyr<79>r8r9)rWr<><00>klass<73>newr<00>my_datas&& r!<00>clone<6E> Config.clone<6E>s<><00><00>F#'<27>,<2C><04><0E><0E>D<EFBFBD><05><14>9<>d<EFBFBD>-<2D>-<2D>4<EFBFBD>-<2D>8<>9<><03> <0C>* <12>E<EFBFBD>G<EFBFBD>+<14>D<EFBFBD>,<19><<3C><<3C><04>%<25>D<EFBFBD><1D>d<EFBFBD>)<29>G<EFBFBD><1E>g<EFBFBD>t<EFBFBD>,<2C>,<2C><13><08><08><14>t<EFBFBD>y<EFBFBD>y<EFBFBD><17>1<>2<><1C>G<EFBFBD>C<EFBFBD>.<2E><07>8<>A<14>F <0C> <20> <20>"<22> <0C> <09> <09> <0B><12>
r#c<00>Z<<01>V^8<>dQhRS[S[R,,RS[S[S[3,/#r<>)r rr
rr )r r8s"<22>r!r"r<>1s.<00><><00>
<EFBFBD>
<EFBFBD><1C>T<EFBFBD>(<28>^<5E>,<2C>
<EFBFBD> <0A>c<EFBFBD>3<EFBFBD>h<EFBFBD><1E>
r#c <0C><><00>\VP4pVe\W!P44\ VRR7#)ai
Supply kwargs suitable for initializing a new clone of this object.
Note that most of the `.clone` process involves copying data between
two instances instead of passing init kwargs; however, sometimes you
really do want init kwargs, which is why this method exists.
:param into: The value of ``into`` as passed to the calling `.clone`.
:returns: A `dict`.
T)rr)r2rr<>rrr)rWr<><00> new_defaultss&& r!r<><00>Config._clone_init_kwargs1s><00><00>"!<21><14><1E><1E>0<> <0C> <0F> <1B> <17> <0C>&:<3A>&:<3A>&<<3C> =<3D><13>!<21><16> 
<EFBFBD>
r#c<00>D<<01>V^8<>dQhRS[S[R3,RS[RS[RR/#)rr7.rHr^rN<>r r)r r8s"<22>r!r"r<>Ns1<00><><00><15><15>u<EFBFBD>S<EFBFBD>#<23>X<EFBFBD><EFBFBD><15>S<EFBFBD><15><13><15><14>r#c <0C><><00>\VPW3,4VPp\V4pV'd&VP ^4pWd9d/WF&WF,pK-W4V&VP 4R#)a;
Update our user-modifications config level with new data.
:param tuple keypath:
The key path identifying the sub-dict being updated. May be an
empty tuple if the update is occurring at the topmost level.
:param str key:
The actual key receiving an update.
:param value:
The value being written.
N)<06>exciser.r-rTr<>r9)rWr7rHr^r5<00> keypath_list<73>subkeys&&&& r!r<><00>Config._modifyNsb<00><00> <0F>t<EFBFBD><EFBFBD><EFBFBD><07>&<26> 0<>1<><13>"<22>"<22><04><1B>G<EFBFBD>}<7D> <0C><1A>!<21>%<25>%<25>a<EFBFBD>(<28>F<EFBFBD><15>!<21>!<21><04> <0C><17><<3C>D<EFBFBD><19>S<EFBFBD> <09> <0C>
<EFBFBD>
<EFBFBD> r#c<00>><<01>V^8<>dQhRS[S[R3,RS[RR/#)rr7.rHrNr<4E>)r r8s"<22>r!r"r<>ls*<00><><00><15><15>u<EFBFBD>S<EFBFBD>#<23>X<EFBFBD><EFBFBD><15>S<EFBFBD><15>T<EFBFBD>r#c <0C><><00>VPp\V4pV'd6VP^4pWS9dW5,pVfR#K//W5&W5,pK=RW2&VP4R#)z#
Like `._modify`, but for removal.
N)r.rTr<>r9)rWr7rHr5r<>r<>s&&& r!r<><00>Config._removelsf<00><00><14><EFBFBD><EFBFBD><04><1B>G<EFBFBD>}<7D> <0C><1A>!<21>%<25>%<25>a<EFBFBD>(<28>F<EFBFBD><15>~<7E><1B>|<7C><04><18><<3C><1A> <20> "<22><04> <0C><1B>|<7C><04><19><04> <09> <0C>
<EFBFBD>
<EFBFBD> r#r<>)NNNNNNF)T)FTr`)#r<>r<>r<>r<>r<>r5r<>r4<00> staticmethodrr:r8rGrKr>r?r\r7rhrnrrr3rSr<><00> _load_ymlr<6C>r<>r9r<>r<>r<>r<>r<>r<>r<>)r8s@r!r<>r<>9s<00><><00><00>m<08>^<16>F<EFBFBD><16>K<EFBFBD><15>J<EFBFBD><11>P
<EFBFBD><12>P
<EFBFBD>dO<15>O<15>b$<24>$<24>
<19><19>$<19><19>$6<>6<>"4<>4<>"7<>7<>, '<27> '<27>F<01>F<01>$<15><15>2<19><19>"<1F><1F>,=<19>=<19>~&<26>&<26><1B>I<EFBFBD>!<21>!<21><14><14>$2<>2<>29<>9<>&V<13>V<13>p
<EFBFBD>
<EFBFBD>:<15><15><<15>r#r<>c<00><00>]tRtRtRtR#)<04>AmbiguousMergeErrori<72>r<>N)r<>r<>r<>r<>r<>r<>r#r!r<>r<><00>s<00><00>r#r<>c<00><><00>V^8<>dQhR\\\3,R\\\3,R\\\3,/#)r<00>base<73>updatesrr<>)r s"r!r"r"<00>s<<00><00>8<10>8<10>
<0E>s<EFBFBD>C<EFBFBD>x<EFBFBD>.<2E>8<10>#'<27><03>S<EFBFBD><08>><3E>8<10> <09>#<23>s<EFBFBD>(<28>^<5E>8r#c<04>x<00>T;'g/P4EFwr#W 9d<>\V\4'dC\W,\4'd\W,V4KR\ W,V4h\W,\4'd\ W,V4h\ VR4'dW0V&K<>\ P !V4W&K<>\V\4'd\V4W&K<>\ VR4'dW0V&EK\ P !V4W&EK V#)a
Recursively merge dict ``updates`` into dict ``base`` (mutating ``base``.)
* Values which are themselves dicts will be recursed into.
* Values which are a dict in one input and *not* a dict in the other input
(e.g. if our inputs were ``{'foo': 5}`` and ``{'foo': {'bar': 5}}``) are
irreconciliable and will generate an exception.
* Non-dict leaf values are run through `copy.copy` to avoid state bleed.
.. note::
This is effectively a lightweight `copy.deepcopy` which offers
protection from mismatched types (dict vs non-dict) and avoids some
core deepcopy problems (such as how it explodes on certain object
types).
:returns:
The value of ``base``, which is mostly useful for wrapper functions
like `copy_dict`.
.. versionadded:: 1.0
<EFBFBD>fileno)r<>rqrrr<><00> _merge_errorr<72>r<>r2)r<>r<>rHr^s&& r!r<>r<><00>s<><00><00>2<1F>}<7D>}<7D>"<22>+<2B>+<2B>-<2D>
<EFBFBD><03> <0F>;<3B><19>%<25><14>&<26>&<26><1D>d<EFBFBD>i<EFBFBD><14>.<2E>.<2E><1F><04> <09>5<EFBFBD>1<>&<26>t<EFBFBD>y<EFBFBD>%<25>8<>8<><1D>d<EFBFBD>i<EFBFBD><14>.<2E>.<2E>&<26>t<EFBFBD>y<EFBFBD>%<25>8<>8<><1D>U<EFBFBD>H<EFBFBD>-<2D>-<2D> %<25><13>I<EFBFBD> $<24> <09> <09>%<25> 0<>D<EFBFBD>I<EFBFBD>
<1A>%<25><14>&<26>&<26>%<25>e<EFBFBD>,<2C><04> <09><19><15><08>)<29>)<29>!<21>S<EFBFBD> <09>!<21>I<EFBFBD>I<EFBFBD>e<EFBFBD>,<2C><04> <09>=.<2E>> <10>Kr#c<00><<00>V^8<>dQhR\R\R\/#)r<00>origr<67>r)rnr<>)r s"r!r"r"<00>s"<00><00><06><06>v<EFBFBD><06>F<EFBFBD><06>/B<>r#c<00>\<00>\RP\V4\V444#)zCan't cleanly merge {} with {})r<>r <00>_format_mismatch)r<>r<>s&&r!r<>r<><00>s-<00><00> <1E>(<28>/<2F>/<2F> <1C>T<EFBFBD> "<22>$4<>S<EFBFBD>$9<>
<EFBFBD> <06>r#c<00>0<00>V^8<>dQhR\R\/#)rr1r)rnr)r s"r!r"r"<00>s<00><00>*<2A>*<2A><06>*<2A>3<EFBFBD>*r#c<00>8<00>RP\V4V4#)z {} ({!r}))r <00>type)r1s&r!r<>r<><00>s<00><00> <16> <1D> <1D>d<EFBFBD>1<EFBFBD>g<EFBFBD>q<EFBFBD> )<29>)r#c<00>t<00>V^8<>dQhR\\\3,R\\\3,/#)r<00>sourcerr<>)r s"r!r"r"<00>s*<00><00> #<23> #<23>d<EFBFBD>3<EFBFBD><03>8<EFBFBD>n<EFBFBD> #<23><14>c<EFBFBD>3<EFBFBD>h<EFBFBD><1E> #r#c<04><00>\/V4#)z<>
Return a fresh copy of ``source`` with as little shared state as possible.
Uses `merge_dicts` under the hood, with an empty ``base`` dict; see its
documentation for details on behavior.
.. versionadded:: 1.0
)r<>)r<>s&r!r2r2<00>s<00><00> <17>r<EFBFBD>6<EFBFBD> "<22>"r#c<00>p<00>V^8<>dQhR\\\3,R\\R3,RR/#)r<00>dict_r7.rN)r
rr r )r s"r!r"r"<00>s1<00><00><1B><1B>$<24>s<EFBFBD>C<EFBFBD>x<EFBFBD>.<2E><1B>5<EFBFBD><13>c<EFBFBD><18>?<3F><1B>t<EFBFBD>r#c<04><><00>Tp\V4pVP4pV'd$VP^4pWR9dR#W%,pK+WB9dW$R#R#)zd
Remove key pointed at by ``keypath`` from nested dict ``dict_``, if exists.
.. versionadded:: 1.0
N)rTr<>)r<>r7r5r<><00>leaf_keyrHs&& r!r<>r<><00>sR<00><00> <11>D<EFBFBD><17><07>=<3D>L<EFBFBD><1B><1F><1F>!<21>H<EFBFBD>
<16><1A><1E><1E>q<EFBFBD>!<21><03> <0E>?<3F> <12><13>y<EFBFBD><04><0F><17> <10>N<EFBFBD>r#c<00>x<00>V^8<>dQhR\\\3,R\\\3,RR/#)rr<><00> deletionsrNr<4E>)r s"r!r"r"<00>s1<00><00> <1A> <1A>T<EFBFBD>#<23>s<EFBFBD>(<28>^<5E> <1A><04>S<EFBFBD>#<23>X<EFBFBD><0E> <1A>4<EFBFBD> r#c<04><><00>VP4F7wr#\V\4'd\W,W,4K5WK9 R#)z\
Remove all (nested) keys mentioned in ``deletions``, from ``base``.
.. versionadded:: 1.0
N)r<>rqrrr<>)r<>r<>rHr^s&& r!r<>r<><00>s9<00><00>  <20>o<EFBFBD>o<EFBFBD>'<27>
<EFBFBD><03> <15>e<EFBFBD>T<EFBFBD> "<22> "<22> <17>t<EFBFBD>y<EFBFBD>)<29>.<2E> 1<><14> <09>(r#)0r<30>r0r&r<><00>importlib.utilrr<00>os.pathrrrr<00>typingr r
r r r rrr<>r<00>
exceptionsrrr<>r<00> terminalsr<00>utilrr<00>importlib.machineryr<00> ImportError<6F>importlib._bootstraprr,r.r<><00>
ValueErrorr<EFBFBD>r<>r<>r<>r2r<>r<>r<>r#r!<00><module>r<>s<><00><01> <0B> <0B> <09> <0C>+<2B><17>.<2E>.<2E><1C>D<>D<>D<><1C>@<40><1A><1E><1D><06>4<><15>R,<2C>R,<2C>jP <15>Y<EFBFBD>P <15>f <09>*<2A> <09>8<10>v<06>*<2A> #<23><1B>& <1A><>E'<13><06><06><06>s<00>"B4<00>4 C<03>C