<?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: loop of geoprocessing tasks, skip the error? in Web AppBuilder Custom Widgets Questions</title>
    <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758133#M754</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;THank you. Actually, I had to re-think the process and remove the promises. Since I was using a sync geoprocessing opeation which is already a deferred action, I didn't the need the promise. It is a lot simpler to catch errors.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 28 Jan 2020 21:09:06 GMT</pubDate>
    <dc:creator>LefterisKoumis</dc:creator>
    <dc:date>2020-01-28T21:09:06Z</dc:date>
    <item>
      <title>loop of geoprocessing tasks, skip the error?</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758131#M752</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm running a loop of geoprocessing tasks and save them in an array&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;promisesSeg&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;push&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;this&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;gpSegment_from_PM&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;execute&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;params_segment&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;;&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When all geoprocessing tasks are completed then it continue on...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt; Promise&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;all&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;promisesSeg&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="token function"&gt;then&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="keyword token"&gt;function&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;results&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt; &lt;SPAN class="punctuation token"&gt;{&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;-&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;--&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;-&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;However, if one set of params lead to a geoprocessing error, it creates an error and terminates further processing.&lt;/P&gt;&lt;P&gt;Is there a way to by-pass the error and continue on with the rest of the sets of params?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it makes sense.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 08:08:25 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758131#M752</guid>
      <dc:creator>LefterisKoumis</dc:creator>
      <dc:date>2021-12-12T08:08:25Z</dc:date>
    </item>
    <item>
      <title>Re: loop of geoprocessing tasks, skip the error?</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758132#M753</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I dont know if I'm misinterpreting the question so apologies if this obvious.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Try:&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; Run your iteration&lt;/P&gt;&lt;P&gt;Except:&lt;/P&gt;&lt;P&gt;&amp;nbsp; &amp;nbsp; continue&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 24 Jan 2020 19:57:00 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758132#M753</guid>
      <dc:creator>DavidPike</dc:creator>
      <dc:date>2020-01-24T19:57:00Z</dc:date>
    </item>
    <item>
      <title>Re: loop of geoprocessing tasks, skip the error?</title>
      <link>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758133#M754</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;THank you. Actually, I had to re-think the process and remove the promises. Since I was using a sync geoprocessing opeation which is already a deferred action, I didn't the need the promise. It is a lot simpler to catch errors.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 28 Jan 2020 21:09:06 GMT</pubDate>
      <guid>https://community.esri.com/t5/web-appbuilder-custom-widgets-questions/loop-of-geoprocessing-tasks-skip-the-error/m-p/758133#M754</guid>
      <dc:creator>LefterisKoumis</dc:creator>
      <dc:date>2020-01-28T21:09:06Z</dc:date>
    </item>
  </channel>
</rss>

