/usr/lib/python2.6/site-packages
NameSizeModeActions
appdirs-1.4.0.dist-info/-0755rm
argparse-1.4.0.dist-info/-0755rm
babel/-0755rm
Babel-2.1.1.dist-info/-0755rm
Babel-2.3.4.dist-info/-0755rm
backports/-0755rm
backports.ssl_match_hostname-3.4.0.2-py2.6.egg-info/-0755rm
boto/-0755rm
boto-2.34.0-py2.6.egg-info/-0755rm
cffi-1.6.0-py2.6-linux-x86_64.egg/-0755rm
chardet/-0755rm
chardet-2.2.1-py2.6.egg-info/-0755rm
cinderclient/-0755rm
clcommon/-0755rm
cliff/-0755rm
cliff-1.15.0.dist-info/-0755rm
cliff-2.0.0.dist-info/-0755rm
clifftablib/-0755rm
cliff_tablib-1.1-py2.6.egg-info/-0755rm
cloudinit/-0755rm
cloud_init-0.7.5-py2.6.egg-info/-0755rm
cmd2-0.6.8-py2.6.egg-info/-0755rm
concurrent/-0755rm
cryptography-1.3.1-py2.6-linux-x86_64.egg/-0755rm
dateutil/-0755rm
dbus/-0755rm
debtcollector/-0755rm
debtcollector-0.8.0.dist-info/-0755rm
debtcollector-1.3.0.dist-info/-0755rm
decorator-4.0.9.dist-info/-0755rm
dict-0.0.5-py2.6.egg-info/-0755rm
distribute-0.6.10-py2.6.egg-info/-0755rm
dns/-0755rm
enum/-0755rm
enum34-1.0.4-py2.6.egg-info/-0755rm
enum34-1.1.3-py2.6.egg/-0755rm
funcsigs/-0755rm
funcsigs-1.0.2.dist-info/-0755rm
futures-3.0.3.dist-info/-0755rm
futures-3.0.5.dist-info/-0755rm
get-0.0.7-py2.6.egg-info/-0755rm
glanceclient/-0755rm
idna/-0755rm
idna-2.0.dist-info/-0755rm
idna-2.1-py2.6.egg/-0755rm
iniparse/-0755rm
iotop/-0755rm
iotop-0.3.2-py2.6.egg-info/-0755rm
ipaddress-1.0.14-py2.6.egg-info/-0755rm
ipaddress-1.0.16-py2.6.egg/-0755rm
iso8601/-0755rm
iso8601-0.1.10-py2.6.egg-info/-0755rm
iso8601-0.1.11.dist-info/-0755rm
jsonpatch-1.2-py2.6.egg-info/-0755rm
jsonpatch-1.11.dist-info/-0755rm
jsonpatch-1.13.dist-info/-0755rm
jsonpointer-1.9.dist-info/-0755rm
jsonpointer-1.10.dist-info/-0755rm
jsonschema/-0755rm
jsonschema-2.5.1.dist-info/-0755rm
keystoneauth1/-0755rm
keystoneauth1-1.1.0.dist-info/-0755rm
keystoneauth1-2.6.0.dist-info/-0755rm
keystoneclient/-0755rm
markdown/-0755rm
monotonic-0.4-py2.6.egg-info/-0755rm
monotonic-1.1.dist-info/-0755rm
ndg/-0755rm
ndg_httpsclient-0.4.0-py2.6.egg-info/-0755rm
netaddr/-0755rm
netaddr-0.7.18.dist-info/-0755rm
neutronclient/-0755rm
nose/-0755rm
nose-0.10.4-py2.6.egg-info/-0755rm
novaclient/-0755rm
oauth/-0755rm
oauth-1.0.1-py2.6.egg-info/-0755rm
openstack/-0755rm
openstackclient/-0755rm
openstacksdk-0.8.5.dist-info/-0755rm
oslo.config-2.4.0.dist-info/-0755rm
oslo.config-3.9.0.dist-info/-0755rm
oslo.i18n-2.6.0.dist-info/-0755rm
oslo.i18n-3.6.0.dist-info/-0755rm
oslo.serialization-1.9.0.dist-info/-0755rm
oslo.serialization-2.4.0.dist-info/-0755rm
oslo.utils-2.5.0.dist-info/-0755rm
oslo.utils-3.8.0.dist-info/-0755rm
oslo_config/-0755rm
oslo_i18n/-0755rm
oslo_serialization/-0755rm
oslo_utils/-0755rm
os_client_config/-0755rm
os_client_config-1.8.1.dist-info/-0755rm
os_client_config-1.17.0.dist-info/-0755rm
pbr/-0755rm
pbr-1.8.0.dist-info/-0755rm
pbr-1.9.1.dist-info/-0755rm
pip-7.1.2-py2.6.egg/-0755rm
pip-8.1.1-py2.6.egg/-0755rm
pkg_resources/-0755rm
positional/-0755rm
positional-1.1.0-py2.6.egg-info/-0755rm
post-0.0.5-py2.6.egg-info/-0755rm
prettytable-0.7.2-py2.6.egg-info/-0755rm
public-0.0.0-py2.6.egg-info/-0755rm
pyasn1/-0755rm
pyasn1-0.0.12a-py2.6.egg-info/-0755rm
pyasn1-0.1.9-py2.6.egg/-0755rm
pyasn1-0.1.9.dist-info/-0755rm
pycparser/-0755rm
pycparser-2.14-py2.6.egg/-0755rm
pycparser-2.14-py2.6.egg-info/-0755rm
pygments/-0755rm
Pygments-1.1.1-py2.6.egg-info/-0755rm
pyparsing-2.0.3.dist-info/-0755rm
pyparsing-2.1.1.dist-info/-0755rm
python_cinderclient-1.4.0.dist-info/-0755rm
python_cinderclient-1.6.0.dist-info/-0755rm
python_dateutil-1.4.1-py2.6.egg-info/-0755rm
python_glanceclient-1.1.0.dist-info/-0755rm
python_glanceclient-2.0.0.dist-info/-0755rm
python_keystoneclient-1.7.1.dist-info/-0755rm
python_keystoneclient-2.3.1.dist-info/-0755rm
python_neutronclient-3.1.0.dist-info/-0755rm
python_novaclient-2.31.0.dist-info/-0755rm
python_novaclient-4.0.0.dist-info/-0755rm
python_openstackclient-1.7.1.dist-info/-0755rm
python_openstackclient-2.4.0.dist-info/-0755rm
python_swiftclient-2.6.0.dist-info/-0755rm
python_swiftclient-3.0.0.dist-info/-0755rm
pytz/-0755rm
pytz-2015.6.dist-info/-0755rm
pytz-2016.4.dist-info/-0755rm
pyzor-1.0.0-py2.6.egg/-0755rm
query_string-0.0.5-py2.6.egg-info/-0755rm
repoze/-0755rm
repoze.lru-0.6-py2.6.egg-info/-0755rm
request-0.0.5-py2.6.egg-info/-0755rm
requests/-0755rm
requests-2.7.0.dist-info/-0755rm
requests-2.9.1.dist-info/-0755rm
requestsexceptions/-0755rm
requestsexceptions-1.1.3.dist-info/-0755rm
rhn/-0755rm
rpmUtils/-0755rm
rsa/-0755rm
rsa-3.4.2-py2.6.egg-info/-0755rm
self-0.0.5-py2.6.egg-info/-0755rm
setools/-0755rm
setuptools/-0755rm
setuptools-20.10.1.dist-info/-0755rm
six-1.9.0.dist-info/-0755rm
six-1.10.0.dist-info/-0755rm
sos/-0755rm
stevedore/-0755rm
stevedore-1.8.0.dist-info/-0755rm
stevedore-1.12.0.dist-info/-0755rm
supervisor/-0755rm
swiftclient/-0755rm
tablib/-0755rm
tablib-0.10.0.dist-info/-0755rm
unicodecsv/-0755rm
unicodecsv-0.14.1-py2.6.egg-info/-0755rm
urlgrabber/-0755rm
urllib3/-0755rm
urllib3-1.10.2-py2.6.egg-info/-0755rm
urllib3-1.12.dist-info/-0755rm
urllib3-1.15.1.dist-info/-0755rm
warlock/-0755rm
warlock-1.1.0-py2.6.egg-info/-0755rm
warlock-1.2.0-py2.6.egg-info/-0755rm
yum/-0755rm
yumutils/-0755rm
appdirs.py223740755editdlrm
appdirs.pyc206650644editdlrm
argparse.py892140644editdlrm
argparse.pyc668150644editdlrm
argparse.pyo664910644editdlrm
chardet-2.0.1-py2.6.egg-info16050644editdlrm
clsudo.py129530644editdlrm
clsudo.pyc113920644editdlrm
clsudo.pyo113920644editdlrm
cmd2.py650690644editdlrm
cmd2.pyc650190644editdlrm
configobj-4.6.0-py2.6.egg-info3120644editdlrm
configobj.py864470644editdlrm
configobj.pyc664120644editdlrm
configobj.pyo664120644editdlrm
dbus_bindings.py330644editdlrm
dbus_bindings.pyc1850644editdlrm
dbus_bindings.pyo1850644editdlrm
decorator.py157750644editdlrm
decorator.pyc144850644editdlrm
dict.py22390644editdlrm
dnspython-1.11.1-py2.6.egg-info12800644editdlrm
easy-install.pth2760644editdlrm
easy_install.py1260644editdlrm
easy_install.pyc3170644editdlrm
easy_install.pyo3170644editdlrm
get.py3220644editdlrm
hwdata.py81420644editdlrm
hwdata.pyc62830644editdlrm
hwdata.pyo62830644editdlrm
iniparse-0.3.1-py2.6.egg-info10850644editdlrm
ipaddress.py796590644editdlrm
ipaddress.pyc759000644editdlrm
jsonpatch.py159460644editdlrm
jsonpatch.pyc174810644editdlrm
jsonpatch.pyo172770644editdlrm
jsonpointer-1.0-py2.6.egg-info3020644editdlrm
jsonpointer.py66100644editdlrm
jsonpointer.pyc63680644editdlrm
jsonpointer.pyo63680644editdlrm
libproxy.py43300644editdlrm
libproxy.pyc39900644editdlrm
libproxy.pyo39900644editdlrm
lprettytable.py238490755editdlrm
lprettytable.pyc196190644editdlrm
lprettytable.pyo194720644editdlrm
Markdown-2.0.1-py2.6.egg-info13400644editdlrm
monotonic.py53450644editdlrm
monotonic.pyc54790644editdlrm
ndg_httpsclient-0.4.0-py2.6-nspkg.pth2960644editdlrm
ordereddict-1.1-py2.6.egg-info1830644editdlrm
ordereddict-1.2-py2.6.egg-info1830644editdlrm
ordereddict.py42210644editdlrm
ordereddict.pyc44210644editdlrm
ordereddict.pyo44210644editdlrm
pciutils-2.3.5-py2.6.egg-info2420644editdlrm
pkg_resources.py881960644editdlrm
pkg_resources.pyc928750644editdlrm
pkg_resources.pyo928750644editdlrm
post.py2260644editdlrm
prettytable.py542040644editdlrm
prettytable.pyc522520644editdlrm
prettytable.pyo512660644editdlrm
public.py46350644editdlrm
pyOpenSSL-0.15.1-py2.6.egg2357360644editdlrm
pyOpenSSL-16.0.0-py2.6.egg943080644editdlrm
pyparsing.py1582560644editdlrm
pyparsing.pyc1578590644editdlrm
pytz-2010h-py2.6.egg-info225770644editdlrm
query_string.py8400644editdlrm
README1190644editdlrm
repoze.lru-0.6-py2.6-nspkg.pth3070644editdlrm
request.py2070644editdlrm
requests-2.6.0-py2.6.egg-info403570644editdlrm
rhnlib-2.5.22-py2.6.egg-info3390644editdlrm
secureio.py92220644editdlrm
secureio.pyc47210644editdlrm
secureio.pyo47210644editdlrm
self.py7280644editdlrm
setuptools-0.6c11-py2.6.egg-info1440644editdlrm
setuptools-18.3.2-py2.6.egg3590330755editdlrm
setuptools-20.9.0-py2.6.egg4728320644editdlrm
setuptools.pth340644editdlrm
site.py23620644editdlrm
site.pyc17710644editdlrm
site.pyo17710644editdlrm
six.py296640644editdlrm
six.pyc293300644editdlrm
six.pyo269110644editdlrm
supervisor-2.1-py2.6.egg-info7970644editdlrm
urlgrabber-3.9.1-py2.6.egg-info22850644editdlrm
validate.py467680644editdlrm
validate.pyc473840644editdlrm
validate.pyo473840644editdlrm
Edit: /usr/lib/python2.6/site-packages/configobj.pyc (66412B)
Ic"@sddklZddkZddkZddkZeZyddkZWnej onXy&ddkl Z l Z l Z l Z WnEej o9dZ dZ dZ ei djo e Z ne Z nXhdefe 6d d fe 6d d fe 6d d fe 6Zhd d 6d d 6d d 6d d6d d 6d d6d d6d d 6d d6d d6dd6dd6dd6dd6dd6Zhe d6e d 6e d 6e d 6e e6ZdZdZdZdZdZdZdZyeWnej odZnXeZdZd Zd!Zd"d#d$d%d&d'd(d)d*d+d,d-d.d/d0d1d2d3d4fZd5Z d6Z!d7Z"h e#d86e$d96e#d:6e$d;6e$d<6ed=6e#d>6ed?6ed@6edA6e$dB6e$dC6Z%dDZ&d2e'fdEYZ(dFefdGYZ)e)Z*dHZ+d%e,fdIYZ-d&e-fdJYZ.d'e-fdKYZ/d0e0fdLYZ1d(e-fdMYZ2d)e-fdNYZ3d,e-fdOYZ4d-e4fdPYZ5d/e-fdQYZ6d.e4fdRYZ7d1e-fdSYZ8dTefdUYZ9dVe9fdWYZ:dXe9fdYYZ;he:d56e;dZ6Z<d[Z=d\e>fd]YZ?d*e?fd^YZ@d+efd_YZAeed`ZBdS(ai(t generatorsN(tBOM_UTF8t BOM_UTF16t BOM_UTF16_BEt BOM_UTF16_LEssstlittletutf_8tutf16_betutf_16tutf16_letu16tutf16sutf-16t utf_16_besutf-16bet utf_16_lesutf-16letu8tutftutf8sutf-8cCsti|idjS(NR(tBOM_LISTtgettlower(tencoding((s-/usr/lib/python2.6/site-packages/configobj.pyt match_utf8[ss'%s's"%s"s%ss '"s"""%s"""s'''%s'''ccs0d}x#|D]}|d7}||fVq WdS(senumerate for Python 2.2.iiN((tobjtititem((s-/usr/lib/python2.6/site-packages/configobj.pyt enumeratejs  s4.6.0s5$Id: configobj.py 156 2006-01-31 14:57:08Z fuzzyman $srestructuredtext ent __version__tDEFAULT_INDENT_TYPEtDEFAULT_INTERPOLATIONtConfigObjErrort NestingErrort ParseErrortDuplicateErrortConfigspecErrort ConfigObjt SimpleValtInterpolationErrortInterpolationLoopErrortMissingInterpolationOptiontRepeatSectionErrort ReloadErrort UnreprErrort UnknownTypet __docformat__tflatten_errorst configparsers i t interpolationt raise_errorst list_valuest create_emptyt file_errort configspect stringifyt indent_typeRtdefault_encodingtunreprtwrite_empty_valuescCsXd|}tdjotdnti|}|idididS(Nsa=scompiler module not availableii(tcompilertNonet ImportErrortparset getChildren(tstp((s-/usr/lib/python2.6/site-packages/configobj.pytgetObjs   cBseZRS((t__name__t __module__(((s-/usr/lib/python2.6/site-packages/configobj.pyR*stBuildercBsbeZdZdZdZdZdZdZdZdZ dZ d Z RS( cCsIt|d|iid}|djot|iin||S(Ntbuild_(tgetattrt __class__RAR:R*(tselftotm((s-/usr/lib/python2.6/site-packages/configobj.pytbuilds cCst|i|iS(N(tmapRJR=(RGRH((s-/usr/lib/python2.6/site-packages/configobj.pyt build_ListscCs|iS(N(tvalue(RGRH((s-/usr/lib/python2.6/site-packages/configobj.pyt build_ConstscCsIh}tt|i|i}x|D]}|i||((s-/usr/lib/python2.6/site-packages/configobj.pyR7scBs eZdZddddZRS(sk This is the base class for all errors that ConfigObj raises. It is a subclass of SyntaxError. tcCs&||_||_ti||dS(N(tlinet line_numbert SyntaxErrort__init__(RGtmessageRkRj((s-/usr/lib/python2.6/site-packages/configobj.pyRms  N(RARBt__doc__R:Rm(((s-/usr/lib/python2.6/site-packages/configobj.pyRscBseZdZRS(sE This error indicates a level of nesting that doesn't match. (RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyRscBseZdZRS(s This error indicates that a line is badly written. It is neither a valid ``key = value`` line, nor a valid section marker line. (RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyRscBseZdZdZRS(sW A 'reload' operation failed. This exception is a subclass of ``IOError``. cCsti|ddS(Ns#reload failed, filename is not set.(tIOErrorRm(RG((s-/usr/lib/python2.6/site-packages/configobj.pyRms(RARBRoRm(((s-/usr/lib/python2.6/site-packages/configobj.pyR( scBseZdZRS(s: The keyword or section specified already exists. (RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyR scBseZdZRS(s7 An error occured whilst parsing a configspec. (RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyR!scBseZdZRS(s,Base class for the two interpolation errors.(RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyR$"scBseZdZdZRS(s=Maximum interpolation depth exceeded in string interpolation.cCsti|d|dS(Ns*interpolation loop detected in value "%s".(R$Rm(RGtoption((s-/usr/lib/python2.6/site-packages/configobj.pyRm)s(RARBRoRm(((s-/usr/lib/python2.6/site-packages/configobj.pyR%&scBseZdZRS(sk This error indicates additional sections in a section with a ``__many__`` (repeated) section. (RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyR'/scBseZdZdZRS(s0A value specified for interpolation was missing.cCsti|d|dS(Ns%missing option "%s" in interpolation.(R$Rm(RGRq((s-/usr/lib/python2.6/site-packages/configobj.pyRm9s(RARBRoRm(((s-/usr/lib/python2.6/site-packages/configobj.pyR&6scBseZdZRS(s An error parsing in unrepr mode.(RARBRo(((s-/usr/lib/python2.6/site-packages/configobj.pyR)?stInterpolationEnginecBsAeZdZeidZdZdZdZdZ RS(s A helper class to help perform string interpolation. This class is an abstract base class; its descendants perform the actual work. s %\(([^)]*)\)scCs ||_dS(N(tsection(RGRs((s-/usr/lib/python2.6/site-packages/configobj.pyRmOscs.fd||ih}|S(Nc s |i||ifot|nd|||if<ii|}x|oi|\}}}|djo |}n||||}|i\} } di|| ||| f}| t |} ii|| }qQW|||if=|S(sxThe function that does the actual work. ``value``: the string we're trying to interpolate. ``section``: the section in which that string was found ``backtrail``: a dict to keep track of where we've been, to detect and prevent infinite recursion loops This is similar to a depth-first-search algorithm. iRiN( thas_keyRXR%t_KEYCREtsearcht _parse_matchR:tspantjointlen( tkeyRMRst backtrailtmatchtktvR>t replacementtstarttendtnew_search_start(trecursive_interpolateRG(s-/usr/lib/python2.6/site-packages/configobj.pyRUs    (Rs(RGR{RM((RRGs-/usr/lib/python2.6/site-packages/configobj.pyt interpolateTs,cCs|iii}t|ii_|i}xxtop|i|}|dj oPn|idhi|}|dj oPn|i|joPn|i}q*W||ii_|djot|n||fS(sHelper function to fetch values from owning section. Returns a 2-tuple: the value, and the section where it was found. tDEFAULTN( RstmainR.RWRVRR:RdR&(RGR{t save_interptcurrent_sectiontval((s-/usr/lib/python2.6/site-packages/configobj.pyt_fetchs$    cCs tdS(sImplementation-dependent helper function. Will be passed a match object corresponding to the interpolation key we just found (e.g., "%(foo)s" or "$foo"). Should look up that key in the appropriate config file section (using the ``_fetch()`` helper function) and return a 3-tuple: (key, value, section) ``key`` is the name of the key we're looking for ``value`` is the value found for that key ``section`` is a reference to the section where it was found ``key`` and ``section`` should be None if no further interpolation should be performed on the resulting value (e.g., if we interpolated "$$" and returned "$"). N(tNotImplementedError(RGR}((s-/usr/lib/python2.6/site-packages/configobj.pyRws( RARBRotretcompileRuRmRRRw(((s-/usr/lib/python2.6/site-packages/configobj.pyRrDs   1 "tConfigParserInterpolationcBs&eZdZeidZdZRS(sBehaves like ConfigParser.s %\(([^)]*)\)scCs1|id}|i|\}}|||fS(Ni(tgroupR(RGR}R{RMRs((s-/usr/lib/python2.6/site-packages/configobj.pyRws(RARBRoRRRuRw(((s-/usr/lib/python2.6/site-packages/configobj.pyRstTemplateInterpolationcBs9eZdZdZeideieiBZdZ RS(sBehaves like string.Template.t$s \$(?: (?P\$) | # Two $ signs (?P[_a-z][_a-z0-9]*) | # $name format {(?P[^}]*)} # ${name} format ) cCs|idp |id}|dj o#|i|\}}|||fS|iddj od|idfSd|idfS(Ntnamedtbracedtescaped(RR:Rt _delimiter(RGR}R{RMRs((s-/usr/lib/python2.6/site-packages/configobj.pyRws ( RARBRoRRRt IGNORECASEtVERBOSERuRw(((s-/usr/lib/python2.6/site-packages/configobj.pyRs ttemplatecGs|i||S(N(t__new__(tclstargs((s-/usr/lib/python2.6/site-packages/configobj.pyt __newobj__stSectioncBsOeZdZdZdZd!d!dZdZdZdZ e dZ dZ d!d Z d Zd Zd Zd Zd!dZdZdZdZdZdZeZdZdZeZde_dZdZdZee dZ dZ!dZ"dZ#dZ$dZ%d Z&RS("s A dictionary-like object that represents a section in a config file. It does string interpolation if the 'interpolation' attribute of the 'main' object is set to True. Interpolation is tried first from this object, then from the 'DEFAULT' section of this object, next from the parent and its 'DEFAULT' section, and so on until the main object is reached. A Section will behave like an ordered dictionary - following the order of the ``scalars`` and ``sections`` attributes. You can use this to change the order of members. Iteration follows the order: scalars, then sections. cCs,ti||d|ii|ddS(Nii(tdicttupdatet__dict__(RGtstate((s-/usr/lib/python2.6/site-packages/configobj.pyt __setstate__scCs(t||if}t|if|fS(N(RRRRF(RGR((s-/usr/lib/python2.6/site-packages/configobj.pyt __reduce__scCs}|djo h}nti|||_||_||_||_|ix$|iD]\}}|||A version of ``get`` that doesn't bypass string interpolation.N(tKeyError(RGR{tdefault((s-/usr/lib/python2.6/site-packages/configobj.pyRs cCs#x|D]}|||| v, remove specified key and return the corresponding value. If key is not found, d is returned if given, otherwise KeyError is raised' ( RtpopRRRRRRR.R]RR(RGR{RR((s-/usr/lib/python2.6/site-packages/configobj.pyRs    cCsL|i|i}|ptdn|d}||}||=||fS(sPops the first (key,val)s": 'popitem(): dictionary is empty'i(RRR(RGtsequenceR{R((s-/usr/lib/python2.6/site-packages/configobj.pytpopitems  cCs>ti|g|_g|_h|_h|_d|_dS(s A version of clear that also affects scalars/sections Also clears comments and configspec. Leaves other attributes alone : depth/main/parent are not affected N(RtclearRRRRR:R3(RG((s-/usr/lib/python2.6/site-packages/configobj.pyRs      cCs5y ||SWn"tj o|||<||SXdS(s:A version of setdefault that sets sequence if appropriate.N(R(RGR{R((s-/usr/lib/python2.6/site-packages/configobj.pyt setdefaults   cCst|i|i|iS(s8D.items() -> list of D's (key, value) pairs, as 2-tuples(tzipRRtvalues(RG((s-/usr/lib/python2.6/site-packages/configobj.pytitemsscCs|i|iS(sD.keys() -> list of D's keys(RR(RG((s-/usr/lib/python2.6/site-packages/configobj.pytkeysscCs-g}|i|iD]}|||q~S(s D.values() -> list of D's values(RR(RGt_[1]R{((s-/usr/lib/python2.6/site-packages/configobj.pyRscCst|iS(s=D.iteritems() -> an iterator over the (key, value) items of D(ROR(RG((s-/usr/lib/python2.6/site-packages/configobj.pyRscCst|i|iS(s.D.iterkeys() -> an iterator over the keys of D(RORR(RG((s-/usr/lib/python2.6/site-packages/configobj.pytiterkeysscCst|iS(s2D.itervalues() -> an iterator over the values of D(ROR(RG((s-/usr/lib/python2.6/site-packages/configobj.pyt itervaluessc CsPddig}|i|iD]'}|dt|t||fq~S(sx.__repr__() <==> repr(x)s{%s}s, s%s: %s(RyRRtrepr(RGRR{((s-/usr/lib/python2.6/site-packages/configobj.pyt__repr__ssx.__str__() <==> str(x)cCsh}x|D]z}||}t|to|i}nAt|tot|}n!t|tot|}n|||>> n = a.dict() >>> n == a 1 >>> n is a 0 (R]RRRRT(RGtnewdictRt this_entry((s-/usr/lib/python2.6/site-packages/configobj.pyRs  cCsqxj|iD]\\}}||jo9t||to%t|to||i|q |||>> a = '''[section1] ... option1 = True ... [[subsection]] ... more_options = False ... # end of file'''.splitlines() >>> b = '''# File is user.ini ... [section1] ... option1 = False ... # end of file'''.splitlines() >>> c1 = ConfigObj(b) >>> c2 = ConfigObj(a) >>> c2.merge(c1) >>> c2 ConfigObj({'section1': {'option1': 'False', 'subsection': {'more_options': 'False'}}}) N(RR]Rtmerge(RGRR{R((s-/usr/lib/python2.6/site-packages/configobj.pyR!s  !cCs||ijo |i}n.||ijo |i}ntd||i|}||}ti||ti||||i||i|||i |}|i |}|i |=|i |=||i |<||i |>> config = '''[XXXXsection] ... XXXXkey = XXXXvalue'''.splitlines() >>> cfg = ConfigObj(config) >>> cfg ConfigObj({'XXXXsection': {'XXXXkey': 'XXXXvalue'}}) >>> def transform(section, key): ... val = section[key] ... newkey = key.replace('XXXX', 'CLIENT1') ... section.rename(key, newkey) ... if isinstance(val, (tuple, list, dict)): ... pass ... else: ... val = val.replace('XXXX', 'CLIENT1') ... section[newkey] = val >>> cfg.walk(transform, call_on_sections=True) {'CLIENT1section': {'CLIENT1key': None}} >>> cfg ConfigObj({'CLIENT1section': {'CLIENT1key': 'CLIENT1value'}}) R/tcall_on_sections(trangeRzRt ExceptionRWRtwalk( RGtfunctionR/RtkeywargstoutRRR((s-/usr/lib/python2.6/site-packages/configobj.pyRZs>/      cCs||}|tjotS|tjotSy5t|tp tn|ii|iSWn#tj otd|nXdS(s_ Accepts a key as input. The corresponding value must be a string or the objects (``True`` or 1) or (``False`` or 0). We allow 0 and 1 to retain compatibility with Python 2.2. If the string is one of ``True``, ``On``, ``Yes``, or ``1`` it returns ``True``. If the string is one of ``False``, ``Off``, ``No``, or ``0`` it returns ``False``. ``as_bool`` is not case sensitive. Any other input will raise a ``ValueError``. >>> a = ConfigObj() >>> a['a'] = 'fish' >>> a.as_bool('a') Traceback (most recent call last): ValueError: Value "fish" is neither True nor False >>> a['b'] = 'True' >>> a.as_bool('b') 1 >>> a['b'] = 'off' >>> a.as_bool('b') 0 s$Value "%s" is neither True nor FalseN( RVRWR]RRRt_boolsRR(RGR{R((s-/usr/lib/python2.6/site-packages/configobj.pytas_bools    cCst||S(si A convenience method which coerces the specified value to an integer. If the value is an invalid literal for ``int``, a ``ValueError`` will be raised. >>> a = ConfigObj() >>> a['a'] = 'fish' >>> a.as_int('a') Traceback (most recent call last): ValueError: invalid literal for int() with base 10: 'fish' >>> a['b'] = '1' >>> a.as_int('b') 1 >>> a['b'] = '3.2' >>> a.as_int('b') Traceback (most recent call last): ValueError: invalid literal for int() with base 10: '3.2' (tint(RGR{((s-/usr/lib/python2.6/site-packages/configobj.pytas_intscCst||S(s A convenience method which coerces the specified value to a float. If the value is an invalid literal for ``float``, a ``ValueError`` will be raised. >>> a = ConfigObj() >>> a['a'] = 'fish' >>> a.as_float('a') Traceback (most recent call last): ValueError: invalid literal for float(): fish >>> a['b'] = '1' >>> a.as_float('b') 1.0 >>> a['b'] = '3.2' >>> a.as_float('b') 3.2000000000000002 (R[(RGR{((s-/usr/lib/python2.6/site-packages/configobj.pytas_floatscCs2||}t|ttfo t|S|gS(sU A convenience method which fetches the specified value, guaranteeing that it is a list. >>> a = ConfigObj() >>> a['a'] = 1 >>> a.as_list('a') [1] >>> a['a'] = (1,) >>> a.as_list('a') [1] >>> a['a'] = [1] >>> a.as_list('a') [1] (R]RTR(RGR{tresult((s-/usr/lib/python2.6/site-packages/configobj.pytas_lists  cCsH|i|}ti|||||ijo|ii|n|S(s Restore (and return) default value for the specified key. This method will only work for a ConfigObj that was created with a configspec and has been validated. If there is no default value for this key, ``KeyError`` is raised. (RRRRR(RGR{R((s-/usr/lib/python2.6/site-packages/configobj.pytrestore_defaults cCsGx|iD]}|i|q Wx|iD]}||iq+WdS(s' Recursively restore default values to all members that have them. This method will only work for a ConfigObj that was created with a configspec and has been validated. It doesn't delete or modify entries without default values. N(RRRtrestore_defaults(RGR{Rs((s-/usr/lib/python2.6/site-packages/configobj.pyR.s  N('RARBRoRRR:RmRRRRWRRRRRRRRRRRRRt__iter__RRt__str__RRRRVRRRRRRR(((s-/usr/lib/python2.6/site-packages/configobj.pyRsH      ;                T ,    cBs"eZdZeideiZeideiZeideiZeideiZ eideiZ eidZ eidZ eidZ eid Zhe e fd 6e efd 6Zhed 6ed 6ed6ed6ed6ed6ed6ed6Zd/d/edZdZd/dZdZdZdZdZdZdZdZdZdZd Z ed!Z!d"Z"d#Z#d$Z$d%Z%d&Z&d'Z'd(Z(d)Z)d*Z*d/d/d+Z+eed/d,Z,d-Z-d.Z.RS(0s2An object to read, create, and write config files.s^ # line start (\s*) # indentation ( # keyword (?:".*?")| # double quotes (?:'.*?')| # single quotes (?:[^'"=].*?) # no quotes ) \s*=\s* # divider (.*) # value (including list values and comments) $ # line end s=^ (\s*) # 1: indentation ((?:\[\s*)+) # 2: section marker open ( # 3: section name open (?:"\s*\S.*?\s*")| # at least one non-space with double quotes (?:'\s*\S.*?\s*')| # at least one non-space with single quotes (?:[^'"\s].*?) # at least one non-space unquoted ) # section name close ((?:\s*\])+) # 4: section marker close \s*(\#.*)? # 5: optional comment $s^ (?: (?: ( (?: (?: (?:".*?")| # double quotes (?:'.*?')| # single quotes (?:[^'",\#][^,\#]*?) # unquoted ) \s*,\s* # comma )* # match all list items ending in a comma (if any) ) ( (?:".*?")| # double quotes (?:'.*?')| # single quotes (?:[^'",\#\s][^,]*?)| # unquoted (?:(?infile must be a filename, file like object, or list of lines.is s s s at line %s.iis2Parsing failed with several errors. First error %s(s s s (s s s ("R]RtfilenametostpathtisfiletopenRtcloseR2RpR1twriteRRTRR"t_errorsR:t_handle_configspecR3REtMISSINGR\t _handle_bomtendswithtnewlinestrstript_parseRkRzRterrorstconfig( RGRR3thRRjRRtinfotmsgterror((s-/usr/lib/python2.6/site-packages/configobj.pyRsp          .         cCs |djo t}nd|_g|_|d|_|d|_|d|_|d|_|d|_|d|_ |d|_ |d|_ |d |_ t |_d|_|d |_|d |_g|_g|_d|_|io t |_nti|dS( NR/R.R0R1R2R4R5RR6R8R7(R:RRRR/R.R0R1R2R4R5RR6RWtBOMR R8R7tinitial_commentt final_commentR3RRR(RGR((s-/usr/lib/python2.6/site-packages/configobj.pyR s.                      c CsPddig}|i|iD]'}|dt|t||fq~S(NsConfigObj({%s})s, s%s: %s(RyRRR(RGRR{((s-/usr/lib/python2.6/site-packages/configobj.pyR@s c Csd|idj o*|iitjo|i||iSt|ttfo|d}n|}|idj o t|ii}|djofxOti D]A\}\}}|pqn|i |o|i||SqW|i||iSt |}|i |p|i||iS|t |}t|ttfo||d|ip|St|to|io|i|iS|S(s'Decode element to unicode if necessary.(RR]tstrR6R!(RGRj((s-/usr/lib/python2.6/site-packages/configobj.pyt_decode_elements  cCs#t|tp t|S|SdS(sh Used by ``stringify`` within validate, to turn non-string values into strings. N(R]RR%(RGRM((s-/usr/lib/python2.6/site-packages/configobj.pyt_strs c Cs|i}|io t|_ng}t}|}t|d}d}t}x||jo|o g}n|d7}||} | i} | p| idot}|i| qQn|p||_g}t}nt}|i i | } | dj o| i \} } }}}| o|i djo | |_ n| id}||idjo|idt||qQn||ijoLy|i||i}Wq4tj o |idt||qQq4XnR||ijo |i}n5||idjo |}n|idt|||i|}|i|o|id t||qQnt|||d |}|||<||i|<||i|R0tsinglet empty_listRCRRR((s-/usr/lib/python2.6/site-packages/configobj.pyR5s6                * c CsF|d }|d}|i|d}|i|d}|i|} | dj o$t| i} | i|| S|i|djo tnx^||joG|d7}|d7}||} | i|djo|| 7}qPqWt|i| } | djo tn| i\}} ||| |fS(s9Extract the value, where we are in a multiline situation.iiiis N(t _triple_quoteR}R:RR-RRYRl( RGRMRR;R:RVtnewvaluet single_linet multi_lineR>tretvalRjRC((s-/usr/lib/python2.6/site-packages/configobj.pyR39s2            c Cst|tpry"t|dtdtdt}Wqtj o}td|qtj o}td|qXn||_dS(sParse the configspec.R/R2RsParsing configspec failed: %ssReading configspec failed: %sN(R]R"RVRR!RpR3(RGR3RE((s-/usr/lib/python2.6/site-packages/configobj.pyR\s  cCs|i}|id}t|to6x3|iD]$}||jo|||_q2q2Wnx|iD]}|djoqhn||joQh||<|o<|ii|g|i|<|ii|d|i||idjo t|_ng}|id}|id}|djo~|i}t|_|}xc|iD]T}|i|}|i}|o|i | o||}n|i |qpWn|i|i } x!|i |i D]} | |ijoqnxa|i| D]R} |i| i} | o| i | o|| } n|i | | qW|| } |i|i| } t| to?|i |i| | i | | |i|id| q|i |i| | | | qW||joox_|iD]T}|i|}|i}|o|i | o||}n|i |qW||_n||j o|S|idjo|djo|io1g}|D]}||i|iq~}n|io]|idjpti|ii djo.|p|i dnt!|d|d>> filename = a.filename >>> a.filename = 'test.ini' >>> a.write() >>> a.filename = filename >>> a == ConfigObj('test.ini', raise_errors=True) 1 R(s# RsRRiitwbN(*R5R:RR#R.RWRR&R+RRRRRRRtlstripRmRR]RRltextendRRkRRRtencodeRRRRRR RtlinesepRyRR RR(RGtoutfileRsRtcstcsptint_valRjt stripped_lineRjRt comment_lineRRCRtlRtoutputR((s-/usr/lib/python2.6/site-packages/configobj.pyRs                 1 *  csdjoidjotdnoddkl}|_no^ii_ii_ii_ii _ ii _ ii _ qnii fd}ht }t }g} iD]} | jo | | qq~ } g} iD]!} | ijo | | qOqO~ } g}iD]!} | ijo || qq~}xiD]}|djoqn|ijp|ijoct }d}oL|ijo<ii|gi|<ii|di|>> import validate >>> vtor = validate.Validator() >>> my_ini = ''' ... option1 = True ... [section1] ... option1 = True ... [section2] ... another_option = Probably ... [section3] ... another_option = True ... [[section3b]] ... value = 3 ... value2 = a ... value3 = 11 ... ''' >>> my_cfg = ''' ... option1 = boolean() ... option2 = boolean() ... option3 = boolean(default=Bad_value) ... [section1] ... option1 = boolean() ... option2 = boolean() ... option3 = boolean(default=Bad_value) ... [section2] ... another_option = boolean() ... [section3] ... another_option = boolean() ... [[section3b]] ... value = integer ... value2 = integer ... value3 = integer(0, 10) ... [[[section3b-sub]]] ... value = string ... [section4] ... another_option = boolean() ... ''' >>> cs = my_cfg.split('\n') >>> ini = my_ini.split('\n') >>> cfg = ConfigObj(ini, configspec=cs) >>> res = cfg.validate(vtor, preserve_errors=True) >>> errors = [] >>> for entry in flatten_errors(cfg, res): ... section_list, key, error = entry ... section_list.insert(0, '[root]') ... if key is not None: ... section_list.append(key) ... else: ... section_list.append('[missing]') ... section_string = ', '.join(section_list) ... errors.append((section_string, ' = ', error)) >>> errors.sort() >>> for entry in errors: ... print entry[0], entry[1], (entry[2] or 0) [root], option2 = 0 [root], option3 = the value "Bad_value" is of the wrong type. [root], section1, option2 = 0 [root], section1, option3 = the value "Bad_value" is of the wrong type. [root], section2, another_option = the value "Probably" is of the wrong type. [root], section3, section3b, section3b-sub, [missing] = 0 [root], section3, section3b, value2 = the value "a" is of the wrong type. [root], section3, section3b, value3 = the value "11" is too big. [root], section4, [missing] = 0 N( R:RVRWR]RRRRRRR,(tcfgtrestlevelstresultsR{R((s-/usr/lib/python2.6/site-packages/configobj.pyR, s,a      (Ct __future__RtsysRRR:R9R;tcodecsRRRRt byteorderRRRRRWRXRNROR[RZRt NameErrortobjectR Rt __revision__R+t__all__RRtMAX_INTERPOL_DEPTHRVRWRR@RR*RCRhR7RlRRRRpR(R R!R$R%R'R&R)RrRRRRRRR"R#R,(((s-/usr/lib/python2.6/site-packages/configobj.pyts   &            8      w   X}