<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:x="urn:schemas-microsoft-com:office:excel" xmlns:p="urn:schemas-microsoft-com:office:powerpoint" xmlns:a="urn:schemas-microsoft-com:office:access" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema" xmlns:b="urn:schemas-microsoft-com:office:publisher" xmlns:ss="urn:schemas-microsoft-com:office:spreadsheet" xmlns:c="urn:schemas-microsoft-com:office:component:spreadsheet" xmlns:odc="urn:schemas-microsoft-com:office:odc" xmlns:oa="urn:schemas-microsoft-com:office:activation" xmlns:html="http://www.w3.org/TR/REC-html40" xmlns:q="http://schemas.xmlsoap.org/soap/envelope/" xmlns:rtc="http://microsoft.com/officenet/conferencing" xmlns:D="DAV:" xmlns:Repl="http://schemas.microsoft.com/repl/" xmlns:mt="http://schemas.microsoft.com/sharepoint/soap/meetings/" xmlns:x2="http://schemas.microsoft.com/office/excel/2003/xml" xmlns:ppda="http://www.passport.com/NameSpace.xsd" xmlns:ois="http://schemas.microsoft.com/sharepoint/soap/ois/" xmlns:dir="http://schemas.microsoft.com/sharepoint/soap/directory/" xmlns:ds="http://www.w3.org/2000/09/xmldsig#" xmlns:dsp="http://schemas.microsoft.com/sharepoint/dsp" xmlns:udc="http://schemas.microsoft.com/data/udc" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:sub="http://schemas.microsoft.com/sharepoint/soap/2002/1/alerts/" xmlns:ec="http://www.w3.org/2001/04/xmlenc#" xmlns:sp="http://schemas.microsoft.com/sharepoint/" xmlns:sps="http://schemas.microsoft.com/sharepoint/soap/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:udcs="http://schemas.microsoft.com/data/udc/soap" xmlns:udcxf="http://schemas.microsoft.com/data/udc/xmlfile" xmlns:udcp2p="http://schemas.microsoft.com/data/udc/parttopart" xmlns:wf="http://schemas.microsoft.com/sharepoint/soap/workflow/" xmlns:dsss="http://schemas.microsoft.com/office/2006/digsig-setup" xmlns:dssi="http://schemas.microsoft.com/office/2006/digsig" xmlns:mdssi="http://schemas.openxmlformats.org/package/2006/digital-signature" xmlns:mver="http://schemas.openxmlformats.org/markup-compatibility/2006" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mrels="http://schemas.openxmlformats.org/package/2006/relationships" xmlns:spwp="http://microsoft.com/sharepoint/webpartpages" xmlns:ex12t="http://schemas.microsoft.com/exchange/services/2006/types" xmlns:ex12m="http://schemas.microsoft.com/exchange/services/2006/messages" xmlns:pptsl="http://schemas.microsoft.com/sharepoint/soap/SlideLibrary/" xmlns:spsl="http://microsoft.com/webservices/SharePointPortalServer/PublishedLinksService" xmlns:Z="urn:schemas-microsoft-com:" xmlns:st="&#1;" xmlns="http://www.w3.org/TR/REC-html40"><head><META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
@font-face
        {font-family:Verdana;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
h2
        {mso-style-priority:9;
        mso-style-link:"Heading 2 Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:20.5pt;
        font-family:"Times New Roman","serif";
        color:#CC0000;
        font-weight:bold;}
h3
        {mso-style-priority:9;
        mso-style-link:"Heading 3 Char";
        margin-top:6.0pt;
        margin-right:0in;
        margin-bottom:0in;
        margin-left:0in;
        margin-bottom:.0001pt;
        font-size:17.0pt;
        font-family:"Times New Roman","serif";
        color:#CC0000;
        font-weight:bold;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0in;
        mso-margin-bottom-alt:auto;
        margin-left:0in;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0in;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.Heading2Char
        {mso-style-name:"Heading 2 Char";
        mso-style-priority:9;
        mso-style-link:"Heading 2";
        color:#CC0000;
        font-weight:bold;}
span.Heading3Char
        {mso-style-name:"Heading 3 Char";
        mso-style-priority:9;
        mso-style-link:"Heading 3";
        color:#CC0000;
        font-weight:bold;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Here is the error returned from your script:<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal style='background:white'><b><span style='font-size:14.5pt;font-family:"Verdana","sans-serif";color:#CC0000'>HTTP Error 502.2 - Bad Gateway<o:p></o:p></span></b></p><p class=MsoNormal style='margin-top:6.0pt;background:white'><b><span style='font-family:"Verdana","sans-serif";color:#CC0000'>The specified CGI application misbehaved by not returning a complete set of HTTP headers. The headers it did return are &quot;Traceback (most recent call last): File &quot;C:\criticalApplications\console\pycsw\pycsw-1.0.0\test3.py&quot;, line 4, in &lt;module&gt; import sqlalchemy ImportError: No module named sqlalchemy &quot;.<o:p></o:p></span></b></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>But, in a python shell if I request the version I get &#8216;0.7.5&#8217; though as shown here:<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Python 2.7.1 (r271:86832, Nov 27 2010, 18:30:46) [MSC v.1500 32 bit (Intel)] on win32<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Type &quot;copyright&quot;, &quot;credits&quot; or &quot;license()&quot; for more information.<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>&gt;&gt;&gt; import sqlalchemy<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>&gt;&gt;&gt; sqlalchemy.__version__<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>'0.7.5'<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>&gt;&gt;&gt;<o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>And, </span><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>I see &#8220;sqlalchemy&#8217; show up in the list when I use &#8220;help(&#8216;modules&#8217;)&#8221;.</span><span style='font-size:10.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>Ideas on how best to proceed?<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'>-Bruce<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D'><o:p>&nbsp;</o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Tom Kralidis [mailto:tomkralidis@hotmail.com] <br><b>Sent:</b> Wednesday, March 14, 2012 1:32 PM<br><b>To:</b> Godfrey, Bruce; gcpp.kalxas@gmail.com<br><b>Cc:</b> pycsw-devel@lists.sourceforge.net<br><b>Subject:</b> RE: [pycsw-devel] Running on Windows 2008 Server IIS7<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p>&nbsp;</o:p></p><div><pre> <br>Bruce: thanks for the info.&nbsp; I'm wondering about the sqlalchemy issue, and the fact that it's not found is causing an error right away.&nbsp; Can you try, as a cgi script:<br> <br>#!/Python27/python -u<br> <br>import os<br>import sqlalchemy<br> <br>print 'Content-type:text/plain\n\n'<br> <br>for k,v in os.environ.iteritems():<br>&nbsp;&nbsp;&nbsp; print '%s -&gt; %s' %(k,v)<br> <br>This should run fine assuming sqlalchemy can be found in your environment in IIS, and we can see what environment variables IIS is working with at runtime.<br> <br>I don't have an IIS environment, so if you can try, that would be great.&nbsp; We can then figure out a way to patch the IIS environment variables in the codebase.<br> <br>Thanks<br> <br>..Tom<br> <br>&nbsp;<br>Date: Wed, 14 Mar 2012 12:47:35 -0700<br>From: bgodfrey@uidaho.edu<br>To: gcpp.kalxas@gmail.com<br>CC: pycsw-devel@lists.sourceforge.net<br>Subject: Re: [pycsw-devel] Running on Windows 2008 Server IIS7<br> <br>&nbsp;<br>&nbsp;<br>&nbsp;<br>.ExternalClass p.ecxMsoNormal, .ExternalClass li.ecxMsoNormal, .ExternalClass div.ecxMsoNormal<br>{margin-bottom:.0001pt;font-size:11.0pt;font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:black;}<br>.ExternalClass a:link, .ExternalClass span.ecxMsoHyperlink<br>{color:blue;text-decoration:underline;}<br>.ExternalClass a:visited, .ExternalClass span.ecxMsoHyperlinkFollowed<br>{color:purple;text-decoration:underline;}<br>.ExternalClass pre<br>{margin-bottom:.0001pt;font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black;}<br>.ExternalClass span.ecxHTMLPreformattedChar<br>{font-family:Consolas;color:black;}<br>.ExternalClass span.ecxEmailStyle19<br>{font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:windowtext;}<br>.ExternalClass span.ecxEmailStyle20<br>{font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D;}<br>.ExternalClass span.ecxEmailStyle21<br>{font-family:&quot;Calibri&quot;,&quot;sans-serif&quot;;color:#1F497D;}<br>.ExternalClass .ecxMsoChpDefault<br>{font-size:10.0pt;}<br>@page WordSection1<br>{size:8.5in 11.0in;}<br>.ExternalClass div.ecxWordSection1<br>{page:WordSection1;}<br> <br>&nbsp;I added system added environment variable for 'HTTP_HOST' and 'REQUEST_URI'.&nbsp; That appears to have gotten me further along.&nbsp; But, I have another hurdle to clear it appears.&nbsp; See below.&nbsp;I&#8217;ve got simple test python scripts working in the same web directory as cws.py.&nbsp; They can be seen here:<a href="http://dev.insideidaho.org/pycsw/test.py" target="_blank">http://dev.insideidaho.org/pycsw/test.py</a> and <a href="http://dev.insideidaho.org/pycsw/test2.py" target="_blank">http://dev.insideidaho.org/pycsw/test2.py</a>.&nbsp; So, I think (fingers crossed) that I have the web server configured correctly but maybe I am overlooking something.&nbsp;When I use the pycsw tester to try make a GetCapabilities request I get a 502 error.&nbsp; &nbsp;Pycsw tester is here: <a href="http://dev.insideidaho.org/pycsw/tester/index.html" target="_blank">http://dev.insideidaho.org/pycsw/tester/index.html</a>&nbsp;When I run pycsw on the localhost machine I get this response with more details:&nbsp;#############################BEGIN RESPONSE#################################&nbsp;&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;<a href="http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd" target="_blank">http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd</a>&quot;&gt; &lt;html xmlns=&quot;<a href="http://www.w3.org/1999/xhtml" target="_blank">http://www.w3.org/1999/xhtml</a>&quot;&gt; &lt;head&gt; &lt;title&gt;IIS 7.0 Detailed Error - 502.2 - Bad Gateway&lt;/title&gt; &lt;style type=&quot;text/css&quot;&gt; &lt;!-- body{margin:0;font-size:.7em;font-family:Verdana,Arial,Helvetica,sans-serif;background:#CBE1EF;} code{margin:0;color:#006600;font-size:1.1em;font-weight:bold;} .config_source code{font-size:.8em;color:#000000;} pre{margin:0;font-size:1.4em;word-wrap:break-word;} ul,ol{margin:10px 0 10px 40px;} ul.first,ol.first{margin-top:5px;} fieldset{padding:0 15px 10px 15px;} .summary-container fieldset{padding-bottom:5px;margin-top:4px;} legend.no-expand-all{padding:2px 15px 4px 10px;margin:0 0 0 -12px;} legend{color:#333333;padding:4px 15px 4px 10px;margin:4px 0 8px -12px;_margin-top:0px; &nbsp;border-top:1px solid #EDEDED;border-left:1px solid #EDEDED;border-right:1px solid #969696; &nbsp;border-bottom:1px solid #969696;background:#E7ECF0;font-weight:bold;font-size:1em;} a:link,a:visited{color:#007EFF;font-weight:bold;} a:hover{text-decoration:none;} h1{font-size:2.4em;margin:0;color:#FFF;} h2{font-size:1.7em;margin:0;color:#CC0000;} h3{font-size:1.4em;margin:10px 0 0 0;color:#CC0000;} h4{font-size:1.2em;margin:10px 0 5px 0; }#header{width:96%;margin:0 0 0 0;padding:6px 2% 6px 2%;font-family:&quot;trebuchet MS&quot;,Verdana,sans-serif; &nbsp;color:#FFF;background-color:#5C87B2; }#content{margin:0 0 0 2%;position:relative;} .summary-container,.content-container{background:#FFF;width:96%;margin-top:8px;padding:10px;position:relative;} .config_source{background:#fff5c4;} .content-container p{margin:0 0 10px 0; }#details-left{width:35%;float:left;margin-right:2%; }#details-right{width:63%;float:left; }#server_version{width:96%;_height:1px;min-height:1px;margin:0 0 5px 0;padding:11px 2% 8px 2%;color:#FFFFFF; &nbsp;background-color:#5A7FA5;border-bottom:1px solid #C1CFDD;border-top:1px solid #4A6C8E;font-weight:normal; &nbsp;font-size:1em;color:#FFF;text-align:right; }#server_version p{margin:5px 0;} table{margin:4px 0 4px 0;width:100%;border:none;} td,th{vertical-align:top;padding:3px 0;text-align:left;font-weight:bold;border:none;} th{width:30%;text-align:right;padding-right:2%;font-weight:normal;} thead th{background-color:#ebebeb;width:25%; }#details-right th{width:20%;} table tr.alt td,table tr.alt th{background-color:#ebebeb;} .highlight-code{color:#CC0000;font-weight:bold;font-style:italic;} .clear{clear:both;} .preferred{padding:0 5px 2px 5px;font-weight:normal;background:#006633;color:#FFF;font-size:.8em;} --&gt; &lt;/style&gt; &nbsp;&lt;/head&gt; &lt;body&gt; &lt;div id=&quot;header&quot;&gt;&lt;h1&gt;Server Error in Application &quot;DEFAULT WEB SITE/PYCSW&quot;&lt;/h1&gt;&lt;/div&gt; &lt;div id=&quot;server_version&quot;&gt;Internet Information Services 7.0&lt;BR&gt;&lt;/div&gt; &lt;div id=&quot;content&quot;&gt; &lt;div class=&quot;content-container&quot;&gt; &nbsp;&lt;fieldset&gt;&lt;legend&gt;Error Summary&lt;/legend&gt; &nbsp;&nbsp;&lt;h2&gt;HTTP Error 502.2 - Bad Gateway&lt;/h2&gt; &nbsp;&nbsp;&lt;h3&gt;The specified CGI application misbehaved by not returning a complete set of HTTP headers.&nbsp; The headers it did return are &amp;quot;Traceback (most recent call last):&nbsp; File &amp;quot;C:\criticalApplications\console\pycsw\pycsw-1.0.0\csw.py&amp;quot;, line 34, in &amp;lt;module&amp;gt;&nbsp;&nbsp;&nbsp; from server import server&nbsp; File &amp;quot;C:\criticalApplications\console\pycsw\pycsw-1.0.0\server\server.py&amp;quot;, line 40, in &amp;lt;module&amp;gt;&nbsp;&nbsp;&nbsp; import config, fes, log, profile, repository, util&nbsp; File &amp;quot;C:\criticalApplications\console\pycsw\pycsw-1.0.0\server\repository.py&amp;quot;, line 33, in &amp;lt;module&amp;gt;&nbsp;&nbsp; &nbsp;from sqlalchemy import create_engine, desc, funcImportError: No module named sqlalchemy&amp;quot;.&lt;/h3&gt; &nbsp;&lt;/fieldset&gt; &lt;/div&gt; &lt;div class=&quot;content-container&quot;&gt; &nbsp;&lt;fieldset&gt;&lt;legend&gt;Detailed Error Information&lt;/legend&gt; &nbsp;&nbsp;&lt;div id=&quot;details-left&quot;&gt; &nbsp;&nbsp;&nbsp;&lt;table border=&quot;0&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot;&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr class=&quot;alt&quot;&gt;&lt;th&gt;Module&lt;/th&gt;&lt;td&gt;CgiModule&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr&gt;&lt;th&gt;Notification&lt;/th&gt;&lt;td&gt;ExecuteRequestHandler&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr class=&quot;alt&quot;&gt;&lt;th&gt;Handler&lt;/th&gt;&lt;td&gt;Python&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr&gt;&lt;th&gt;Error Code&lt;/th&gt;&lt;td&gt;0x00000001&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/table&gt; &nbsp;&nbsp;&lt;/div&gt; &nbsp;&nbsp;&lt;div id=&quot;details-right&quot;&gt; &nbsp;&nbsp;&nbsp;&lt;table border=&quot;0&quot; cellpadding=&quot;0&quot; cellspacing=&quot;0&quot;&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr class=&quot;alt&quot;&gt;&lt;th&gt;Requested URL&lt;/th&gt;&lt;td&gt;<a href="http://dev.insideidaho.org:80/pycsw/csw.py" target="_blank">http://dev.insideidaho.org:80/pycsw/csw.py</a>&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr&gt;&lt;th&gt;Physical Path&lt;/th&gt;&lt;td&gt;C:\criticalApplications\console\pycsw\pycsw-1.0.0\csw.py&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr class=&quot;alt&quot;&gt;&lt;th&gt;Logon Method&lt;/th&gt;&lt;td&gt;Anonymous&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;tr&gt;&lt;th&gt;Logon User&lt;/th&gt;&lt;td&gt;Anonymous&lt;/td&gt;&lt;/tr&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&lt;/table&gt; &nbsp;&nbsp;&nbsp;&lt;div class=&quot;clear&quot;&gt;&lt;/div&gt; &nbsp;&nbsp;&lt;/div&gt; &nbsp;&lt;/fieldset&gt; &lt;/div&gt; &lt;div class=&quot;content-container&quot;&gt; &nbsp;&lt;fieldset&gt;&lt;legend&gt;Most likely causes:&lt;/legend&gt; &nbsp;&nbsp;&lt;ul&gt; &nbsp;&nbsp;&nbsp; &lt;li&gt;The CGI process was shut down or terminated unexpectedly before it finished processing the request.&lt;/li&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;li&gt;The CGI process has a flaw and does not return a complete set of HTTP headers.&lt;/li&gt; &lt;/ul&gt; &nbsp;&lt;/fieldset&gt; &lt;/div&gt; &lt;div class=&quot;content-container&quot;&gt; &nbsp;&lt;fieldset&gt;&lt;legend&gt;Things you can try:&lt;/legend&gt; &nbsp;&nbsp;&lt;ul&gt; &nbsp;&nbsp;&nbsp; &lt;li&gt;Check the event logs on the system to see whether the CGI process is shutting down unexpectedly.&lt;/li&gt; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;li&gt;Troubleshoot the CGI application to determine why it is not sending a complete set of HTTP headers.&lt;/li&gt; &lt;/ul&gt; &nbsp;&lt;/fieldset&gt; &lt;/div&gt; &nbsp;&nbsp;&lt;div class=&quot;content-container&quot;&gt; &nbsp;&lt;fieldset&gt;&lt;legend&gt;Links and More Information&lt;/legend&gt; &nbsp;&nbsp;This error occurs when the CGI process handling the request exits before it finishes sending the response to IIS. &nbsp;&nbsp;&lt;a href=&quot;<a href="http://go.microsoft.com/fwlink/?LinkID=62293&amp;amp;IIS70Error=502,2,0x00000001,6002" target="_blank">http://go.microsoft.com/fwlink/?LinkID=62293&amp;amp;IIS70Error=502,2,0x00000001,6002</a>&quot;&gt;View more information &amp;raquo;&lt;/a&gt;&lt;BR&gt; &nbsp;&nbsp;&nbsp;&nbsp;&lt;/fieldset&gt; &lt;/div&gt; &lt;/div&gt; &lt;/body&gt; &lt;/html&gt;&nbsp;#############################END RESPONSE#################################&nbsp;&nbsp;Note that &#8220;sqlalchemy&#8217; show up in the list when I use &#8220;help(&#8216;modules&#8217;)&#8221; &nbsp;It seems like the crux of the issue is that IIS7 doesn&#8217;t like the way the HTTP headers being returned by the pycsw script(s).&nbsp; Maybe a syntax issue?&nbsp; I&#8217;m not sure.&nbsp; I&#8217;m definitely no expert.&nbsp; Since I can run the test.py scripts I&#8217;m hoping that the web server is configured properly.&nbsp; If not I&#8217;m not quite sure where to look at this point.&nbsp; But, maybe it is still an IIS7 configuration issue.&nbsp;Ideas on how to troubleshoot this or get it working? &nbsp;Thanks much!&nbsp;-Bruce&nbsp;&nbsp;From: Angelos Tzotsos [mailto:gcpp.kalxas@gmail.com] <br>Sent: Tuesday, March 13, 2012 6:08 PM<br>To: Godfrey, Bruce<br>Cc: pycsw-devel@lists.sourceforge.net<br>Subject: Re: [pycsw-devel] Running on Windows 2008 Server IIS7&nbsp;Hi Bruce,<br> <br>Yes, it seems that this issue is Windows specific. The &quot;HTTP_HOST&quot; variable is not set in the environment variables.<br> <br>Please try this from a Python console:<br> <br>import os<br>os.environ<br> <br>and send the output.<br> <br>Thanks,<br>Angelos<br> <br>On 03/14/2012 01:29 AM, Godfrey, Bruce wrote: Hi Angelos,&nbsp;Yes, thank you, I was able to get it working using the syntax C:\\www\\pycsw&nbsp;I&#8217;ve run into this issue now:&nbsp;Traceback (most recent call last):&nbsp; File &quot;C:\criticalApplications\console\pycsw\pycsw-1.0.0\csw.py&quot;, line 40, in &lt;module&gt;&nbsp;&nbsp;&nbsp; CSW.dispatch()&nbsp; File &quot;C:\criticalApplications\console\pycsw\pycsw-1.0.0\server\server.py&quot;, line 161, in dispatch&nbsp;&nbsp;&nbsp; (os.environ['HTTP_HOST'], os.environ['REQUEST_URI'])&nbsp; File &quot;C:\Python27\lib\os.py&quot;, line 423, in __getitem__&nbsp;&nbsp;&nbsp; return self.data[key.upper()]KeyError: 'HTTP_HOST'&gt;&gt;&gt;&nbsp;&nbsp;I think I&#8217;m close but I&#8217;m not sure where to look to try to track this down.&nbsp; I wonder if it is an IIS7 issue?&nbsp;-Bruce&nbsp;From: Angelos Tzotsos [mailto:gcpp.kalxas@gmail.com] <br>Sent: Tuesday, March 13, 2012 4:22 PM<br>To: pycsw-devel@lists.sourceforge.net<br>Subject: Re: [pycsw-devel] Running on Windows 2008 Server IIS7&nbsp;Hello Bruce,<br> <br>Did you try the windows path like c:\path\to\pycsw ?<br> <br>Regards,<br>Angelos<br> <br>On 03/13/2012 04:44 AM, Godfrey, Bruce wrote: Hello,&nbsp;I&#8217;m attempting to get pycsw running on a Windows 2008 box with IIS7.&nbsp; I have all the supporting libraries installed and I have SQLite3.&nbsp; I&#8217;ll preface this by saying I have pretty limited experience with python.&nbsp; &nbsp;I&#8217;ve changed the first line of csw.py to: #!/Python27/python -u&nbsp;At this point I need edit default.cfg, correct?&nbsp;What is the correct syntax for:&nbsp; home=/var/www/pycsw on Windows?&nbsp; Is it like: c:\path\to\defaul.cfg?&nbsp;Thank you for any assistance in getting this running on my Windows box.&nbsp; I really appreciate it.&nbsp; &nbsp;-Bruce&nbsp;&nbsp;<br> <br>&nbsp;<br>&nbsp;<br>------------------------------------------------------------------------------Keep Your Developer Skills Current with LearnDevNow!The most comprehensive online learning library for Microsoft developersis just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,Metro Style Apps, more. Free future releases when you subscribe now!<a href="http://p.sf.net/sfu/learndevnow-d2d" target="_blank">http://p.sf.net/sfu/learndevnow-d2d</a><br> <br>&nbsp;<br>&nbsp;<br>_______________________________________________pycsw-devel mailing listpycsw-devel@lists.sourceforge.net<a href="https://lists.sourceforge.net/lists/listinfo/pycsw-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/pycsw-devel</a><br> <br>&nbsp;<br>&nbsp;<br>-- Angelos TzotsosRemote Sensing LaboratoryNational Technical University of Athens<a href="http://users.ntua.gr/tzotsos" target="_blank">http://users.ntua.gr/tzotsos</a><br> <br>&nbsp;<br>-- Angelos TzotsosRemote Sensing LaboratoryNational Technical University of Athens<a href="http://users.ntua.gr/tzotsos" target="_blank">http://users.ntua.gr/tzotsos</a><br>------------------------------------------------------------------------------<br>Virtualization &amp; Cloud Management Using Capacity Planning<br>Cloud computing makes use of virtualization - but cloud computing <br>also focuses on allowing computing to be delivered as a service.<br><a href="http://www.accelacomm.com/jaw/sfnl/114/51521223/" target="_blank">http://www.accelacomm.com/jaw/sfnl/114/51521223/</a><br>_______________________________________________<br>pycsw-devel mailing list<br>pycsw-devel@lists.sourceforge.net<br><a href="https://lists.sourceforge.net/lists/listinfo/pycsw-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/pycsw-devel</a><o:p></o:p></pre></div></div></body></html>