<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>9946</bug_id>
          
          <creation_ts>2016-07-14 21:22:27 +0000</creation_ts>
          <short_desc>patchtest: must be able to test the series on every branch  specified on mbox summary</short_desc>
          <delta_ts>2017-12-06 17:03:28 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>6</classification_id>
          <classification>Yocto Project Subprojects</classification>
          <product>Patchwork/Patchtest</product>
          <component>Patchtest</component>
          <version>2.3</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>2.5</target_milestone>
          
          <blocked>10716</blocked>
          <everconfirmed>1</everconfirmed>
          <reporter name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</reporter>
          <assigned_to name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</assigned_to>
          <cc>bluelightning</cc>
    
    <cc>sgw</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>64014</commentid>
    <comment_count>0</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2016-07-14 21:22:27 +0000</bug_when>
    <thetext>Right now, patchtest just run the set of checks for a single branch but commonly people send patches to multiple branches (krogoth/jethro/master), e.g. CVE patches and the system must be able to check on each one.

Current implementation parses the &apos;[PATCH ]&apos; summary prefix and works on the first valid branch.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>70139</commentid>
    <comment_count>1</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2017-01-25 17:43:50 +0000</bug_when>
    <thetext>This is nice feature but current release is already too loaded with patchtest work and currently work is focused on stabilization and the test suite. Moving it to next release.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>74251</commentid>
    <comment_count>2</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2017-06-15 19:28:30 +0000</bug_when>
    <thetext>At 2.4, the focus is on the python 2 to python 3 migration, tinfoil usage and stabilization of these two. So moving it to 2.5</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>74515</commentid>
    <comment_count>3</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2017-06-23 16:00:51 +0000</bug_when>
    <thetext>Right now, we have the following commit to stop sending false positives, but need to better handle by indicating patchtest which branch to use, so test test_series_merge_on_head is generic



commit d2aba545588264e1135fa9b651145467178e4c8a
Author: Leonardo Sandoval &lt;leonardo.sandoval.gonzalez@linux.intel.com&gt;
Date:   Fri Jun 23 08:57:55 2017 -0700

    test_mbox_merge: skip test on stable branches
    
    Signed-off-by: Leonardo Sandoval &lt;leonardo.sandoval.gonzalez@linux.intel.com&gt;

diff --git a/tests/test_mbox_merge.py b/tests/test_mbox_merge.py
index 6d70d6c..04039b1 100644
--- a/tests/test_mbox_merge.py
+++ b/tests/test_mbox_merge.py
@@ -32,7 +32,18 @@ class Merge(base.Base):
 
     def test_series_merge_on_head(self):
         if not pti.repo.ismerged:
-            commithash, author, date, shortlog = headlog()
-            self.fail(&apos;Series does not apply on top of target branch&apos;,
-                      &apos;Rebase your series on top of targeted branch&apos;,
-                      data=[(&apos;Targeted branch&apos;, &apos;%s (currently at %s)&apos; % (pti.repo.branch, commithash))])
+
+            # TODO: in order to stop sending false-positives, do this check on
+            # patchtest-oe instead of selecting the correct branch from patchtest.
+            # Currently patchtest is not able to test on non-master branches,
+            # so we need to avoid testing on patches targeted for the following
+            # stable releases
+            stable_releases = [&apos;krogoth&apos;, &apos;morty&apos;, &apos;pyro&apos;]
+            subjects = [commit.subject for commit in self.commits]
+            for release in stable_releases:
+                if release in subjects[0]:
+                    self.skip(&apos;Non-master branch %s, skip test&apos; % release, data=[(&apos;patch&apos;, pti.repo.patch)])
+            else:
+                commithash, author, date, shortlog = headlog()
+                self.fail(&apos;Series does not apply on top of target branch&apos;, &apos;Rebase your series on top of targeted branch&apos;,
+                          data=[(&apos;Targeted branch&apos;, &apos;%s (currently at %s)&apos; % (pti.repo.branch, commithash))])</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>78375</commentid>
    <comment_count>4</comment_count>
    <who name="Leonardo Sandoval Gonzalez">leonardo.sandoval.gonzalez</who>
    <bug_when>2017-11-28 17:09:14 +0000</bug_when>
    <thetext>This enhancement is partially completed in the framework. By partially I meant that if a single series is intended for multiple branches, then just one branch will be tested (the first that match with a oe-core branch, i.e. master, pyro, rocko, etc.). IMO, this this good enough because series usually  are targeted to a single branch, not multiple, so patchtest will do its job as expected.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>