<html>
<head>
<!-- Template generated by Exclaimer Signature Manager Exchange Edition on 01:03:17 Thursday, 4 December 2014 -->
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<style type="text/css">P.ImprintUniqueID {
        MARGIN: 0cm 0cm 0pt
}
LI.ImprintUniqueID {
        MARGIN: 0cm 0cm 0pt
}
DIV.ImprintUniqueID {
        MARGIN: 0cm 0cm 0pt
}
TABLE.ImprintUniqueIDTable {
        MARGIN: 0cm 0cm 0pt
}
DIV.Section1 {
        page: Section1
}
.ExternalClass * {
        LINE-HEIGHT: 100%
}
</style>
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<p class="ImprintUniqueID"></p>
<div>Hi Folks</div>
<div>I’m new to the list.  So please forgive possibly naive questions.</div>
<div><br>
</div>
<div>Looking at sos200.py we have</div>
<div>
<div>    def __getitem__(self,id):</div>
<div>        ''' check contents dictionary to allow dict like access to service observational offerings'''</div>
<div>        if name in self.__getattribute__('contents').keys():</div>
<div>            return self.__getattribute__('contents')[id]</div>
<div>        else:</div>
<div>            raise KeyError, "No Observational Offering with id: %s" % id</div>
</div>
<div><br>
</div>
<div><br>
</div>
<div>Is the use of ‘name’ here correct?  Should it be ‘id’ ? </div>
<div><br>
</div>
<div>If you run it then you get </div>
<div><span class="ansired"><br>
</span></div>
<div><span class="ansired">NameError</span>: global name 'name' is not defined</div>
<div><br>
</div>
<div>Thanks Andrew</div>
<div><br>
</div>
<div><br>
</div>
<br>
<table class="ImprintUniqueIDTable" style="BORDER-COLLAPSE: collapse" cellspacing="0" cellpadding="0" border="0">
<tbody>
<tr>
<td style="FONT-SIZE: 18pt; FONT-FAMILY: Arial; COLOR: #333333" valign="top"><font style="font-family:Calibri;font-size:12pt;color:#1F497D;font-weight:normal;">Andrew Watkins</font></td>
</tr>
<tr height="2">
<td height="1"><font style="font-family:Calibri;font-size:10pt;color:#1F497D;">Systems Development Manager</font><br>
</td>
</tr>
</tbody>
</table>
<table class="ImprintUniqueIDTable" style="HEIGHT: 1px; BORDER-COLLAPSE: collapse; WIDTH: 96.43%" height="1" cellspacing="0" cellpadding="0" border="0">
<tbody>
<tr>
<td><font style="font-family:Calibri;font-size:10pt;color:#1F497D;">+64-9-375-2069</font><font style="font-family:Calibri;font-size:10pt;color:#1F497D;"> |
</font><font style="font-family:Calibri;font-size:10pt;color:#1F497D;">+64-27-703-1007</font><font style="font-family:Calibri;font-size:10pt;color:#1F497D;"> |
</font><font style="font-family:Calibri;font-size:10pt;color:#1F497D;">41 Market Place, Viaduct Harbour, Auckland</font><font style="font-family:Calibri;font-size:10pt;color:#1F497D;text-decoration:none;"> |
</font><span style="font-family:Calibri;font-size:10pt;color:#0066CC;text-decoration:underline;"><a href="http://www.niwa.co.nz" title="" target="" style="font-family:Calibri;font-size:10pt;color:#0066CC;text-decoration:underline;"><span style="font-family:Calibri; font-size:10pt; color:#0066CC; text-decoration:underline;">www.niwa.co.nz</span></a></span></td>
</tr>
</tbody>
</table>
<table class="ImprintUniqueIDTable" style="BORDER-COLLAPSE: collapse; PADDING-BOTTOM: 5px; PADDING-TOP: 5px" height="91" cellspacing="0" cellpadding="0" width="500" border="0">
<tbody>
<tr>
<td style="WIDTH: 541px" height="91" valign="top" width="475" align="left"><a href="http://www.niwa.co.nz" target=""><img width="538" height="66" style="border: 0px Solid ; " src="cid:image062f7f.JPG@6044ec63.46b69754" alt="NIWA"></a></td>
</tr>
<tr>
</tr>
</tbody>
</table>
<table class="ImprintUniqueIDTable" style="BORDER-COLLAPSE: collapse" cellspacing="0" cellpadding="0" width="500" border="0">
<tbody>
</tbody>
</table>
<br>
<br>
<br>
<p></p>
</body>
</html>