<?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 can I set the status of a databricks job as skipped via python? in Data Engineering</title>
    <link>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6241#M2438</link>
    <description>&lt;P&gt;@Michael Papadopoulos​&amp;nbsp;usually that should not be the case i think, as for task level we have 3 level notifications ( success, failure,start), where as whole job level skip option is available to discard notification . will see if some one from community faced or respond &lt;/P&gt;</description>
    <pubDate>Fri, 07 Apr 2023 20:32:12 GMT</pubDate>
    <dc:creator>karthik_p</dc:creator>
    <dc:date>2023-04-07T20:32:12Z</dc:date>
    <item>
      <title>How can I set the status of a databricks job as skipped via python?</title>
      <link>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6238#M2435</link>
      <description>&lt;P&gt;I have a basic 2 task job. &lt;/P&gt;&lt;UL&gt;&lt;LI&gt;The 1st notebook (task) checks whether the source file has changes and if so then refreshes a corresponding materialized view. In case we have no changes then I use dbutils.jobs.taskValues.set(key = "skip_job", value = 1) &amp;amp; dbutils.notebook.exit("SKIP").&lt;/LI&gt;&lt;LI&gt;The 2nd notebook (task) checks the passed variable from the 1st notebook with skip_job = dbutils.jobs.taskValues.get(taskKey = "01_prepare_fms_rmf_data", key = "skip_job", default = 0, debugValue = 0) and skips execution accordingly if (skip_job == 1): dbutils.notebook.exit("SKIP")&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This seems to work fine for my case but I have I minor issue. I want to receive email notification upon Success or failure but not upon skip. The job Status is Success even when I use the above skip approach. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a solution to this? Maybe there is some other command I can use to set the job status as skipped?&lt;/P&gt;</description>
      <pubDate>Fri, 07 Apr 2023 13:35:05 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6238#M2435</guid>
      <dc:creator>Michael_Papadop</dc:creator>
      <dc:date>2023-04-07T13:35:05Z</dc:date>
    </item>
    <item>
      <title>Re: How can I set the status of a databricks job as skipped via python?</title>
      <link>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6239#M2436</link>
      <description>&lt;P&gt;@Michael Papadopoulos​&amp;nbsp;please select below option in job notification settings , that should handle u r case&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/396i254A0BB954C4CE4D/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Apr 2023 18:09:54 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6239#M2436</guid>
      <dc:creator>karthik_p</dc:creator>
      <dc:date>2023-04-07T18:09:54Z</dc:date>
    </item>
    <item>
      <title>Re: How can I set the status of a databricks job as skipped via python?</title>
      <link>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6240#M2437</link>
      <description>&lt;P&gt;Sorry, I forgot to mention that I had already tried that flag with no success. The job still sends notification even upon skip of both tasks.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also the Statuses of both tasks and whole job is Succeeded.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/408i7E2D9D69D1F8D1C4/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/393iB17FC06E906DA351/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/399iE79063E6B45D9515/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper" image-alt="image"&gt;&lt;img src="https://community.databricks.com/t5/image/serverpage/image-id/417iCAD78B983B5CCAC3/image-size/large?v=v2&amp;amp;px=999" role="button" title="image" alt="image" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 07 Apr 2023 20:09:26 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6240#M2437</guid>
      <dc:creator>Michael_Papadop</dc:creator>
      <dc:date>2023-04-07T20:09:26Z</dc:date>
    </item>
    <item>
      <title>Re: How can I set the status of a databricks job as skipped via python?</title>
      <link>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6241#M2438</link>
      <description>&lt;P&gt;@Michael Papadopoulos​&amp;nbsp;usually that should not be the case i think, as for task level we have 3 level notifications ( success, failure,start), where as whole job level skip option is available to discard notification . will see if some one from community faced or respond &lt;/P&gt;</description>
      <pubDate>Fri, 07 Apr 2023 20:32:12 GMT</pubDate>
      <guid>https://community.databricks.com/t5/data-engineering/how-can-i-set-the-status-of-a-databricks-job-as-skipped-via/m-p/6241#M2438</guid>
      <dc:creator>karthik_p</dc:creator>
      <dc:date>2023-04-07T20:32:12Z</dc:date>
    </item>
  </channel>
</rss>

