<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: How to timeout a long running arcpy operation like (Spatial Join or Identity) in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659628#M51271</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Once a tool has started, your script cannot interact with it. The only approach I can suggest is to launch a script asynchronously using the subprocess module and check on it. Python 2.6 has a new method that allows you to kill processes in Windows in a pretty straightforward way.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think you may have better luck determining why the process is "randomly" taking a couple of hours and try to trap for that before you start the tool.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 07 May 2012 22:32:07 GMT</pubDate>
    <dc:creator>curtvprice</dc:creator>
    <dc:date>2012-05-07T22:32:07Z</dc:date>
    <item>
      <title>How to timeout a long running arcpy operation like (Spatial Join or Identity)</title>
      <link>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659626#M51269</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I have a Spatial join operation which works on huge volume of data. Sometimes it???s done in few minutes but randomly takes couple of hours.&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Is there any way to track the timelines of any ongoing&amp;nbsp;&amp;nbsp; arcpy method, so that the process can be interrupted if the method takes a long time?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;regards,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Nidhi&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 May 2012 16:30:44 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659626#M51269</guid>
      <dc:creator>nidhiarora</dc:creator>
      <dc:date>2012-05-07T16:30:44Z</dc:date>
    </item>
    <item>
      <title>Re: How to timeout a long running arcpy operation like (Spatial Join or Identity)</title>
      <link>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659627#M51270</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;there is probably a better way but you could always build a timer into the program&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;import time&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;write some little catch which triggers and aborts after ten minutes or whatever time frame you had in mind&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 May 2012 17:38:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659627#M51270</guid>
      <dc:creator>AnthonyTimpson2</dc:creator>
      <dc:date>2012-05-07T17:38:25Z</dc:date>
    </item>
    <item>
      <title>Re: How to timeout a long running arcpy operation like (Spatial Join or Identity)</title>
      <link>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659628#M51271</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Once a tool has started, your script cannot interact with it. The only approach I can suggest is to launch a script asynchronously using the subprocess module and check on it. Python 2.6 has a new method that allows you to kill processes in Windows in a pretty straightforward way.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I think you may have better luck determining why the process is "randomly" taking a couple of hours and try to trap for that before you start the tool.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 07 May 2012 22:32:07 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/how-to-timeout-a-long-running-arcpy-operation-like/m-p/659628#M51271</guid>
      <dc:creator>curtvprice</dc:creator>
      <dc:date>2012-05-07T22:32:07Z</dc:date>
    </item>
  </channel>
</rss>

