<?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>11115</bug_id>
          
          <creation_ts>2017-03-01 17:32:22 +0000</creation_ts>
          <short_desc>Downloading cvs tarball for buildcvs.py selftest shouldn&apos;t use /tmp</short_desc>
          <delta_ts>2017-05-25 15:14:56 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>10</classification_id>
          <classification>QA/Testing</classification>
          <product>Runtime Testing</product>
          <component>general</component>
          <version>unspecified</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>normal</bug_severity>
          <target_milestone>2.3</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Richard Purdie">richard.purdie</reporter>
          <assigned_to name="yeoh ee peng">ee.peng.yeoh</assigned_to>
          <cc>benjamin.esquivel</cc>
    
    <cc>joshuagloe</cc>
    
    <cc>rebecca.swee.fun.chang</cc>
    
    <cc>ross.burton</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>71024</commentid>
    <comment_count>0</comment_count>
    <who name="Richard Purdie">richard.purdie</who>
    <bug_when>2017-03-01 17:32:22 +0000</bug_when>
    <thetext>The autobuilder normally uses a cached copy of tarballs from DL_DIR if present for the runtime build tests (cvs, iptables and galculator).

If these aren&apos;t present, it will download to /tmp/. This is racy as several buiulds may download to the same location and tests can fail. There are two problems:

a) DL_DIR is never populated
b) /tmp/ is used for the temporary file which can race with other builds.

I&apos;ve added a copy of the tarballs to the new AB so this error won&apos;t occur but we need to fix the underlying races and initial populatation.

Its complicated by the same tests being used against the target images and against the sdk/extsdk. We need to fix all cases to be consistent and not use /tmp for tmp files.

NOTE: core-image-sato-sdk-1.0-r0 do_testimage: ======================================================================
NOTE: core-image-sato-sdk-1.0-r0 do_testimage: ERROR [0.000s]: setUpClass (buildcvs.BuildCvsTest)
NOTE: core-image-sato-sdk-1.0-r0 do_testimage: ----------------------------------------------------------------------
NOTE: core-image-sato-sdk-1.0-r0 do_testimage: Traceback (most recent call last):
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-ppc/build/meta/lib/oeqa/core/case.py&quot;, line 32, in _oeSetUpClass
    clss.setUpClassMethod()
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-ppc/build/meta/lib/oeqa/runtime/cases/buildcvs.py&quot;, line 17, in setUpClass
    cls.project.download_archive()
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-ppc/build/meta/lib/oeqa/runtime/utils/targetbuildproject.py&quot;, line 17, in download_archive
    status, output = self.target.copyTo(self.localarchive, self.targetdir)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-ppc/build/meta/lib/oeqa/core/target/ssh.py&quot;, line 103, in copyTo
    return self._run(scpCmd, ignore_status=False)
  File &quot;/home/pokybuild/yocto-autobuilder/yocto-worker/nightly-ppc/build/meta/lib/oeqa/core/target/ssh.py&quot;, line 61, in _run
    &quot;status %d:\n%s&quot; % (command, status, output))
AssertionError: Command &apos;[&apos;scp&apos;, &apos;-o&apos;, &apos;UserKnownHostsFile=/dev/null&apos;, &apos;-o&apos;, &apos;StrictHostKeyChecking=no&apos;, &apos;-o&apos;, &apos;LogLevel=ERROR&apos;, &apos;/tmp/cvs-1.12.13.tar.bz2&apos;, &apos;root@192.168.7.10:~/&apos;]&apos; returned non-zero exit status 1:
/tmp/cvs-1.12.13.tar.bz2: No such file or directory</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>73509</commentid>
    <comment_count>1</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2017-05-25 15:14:56 +0000</bug_when>
    <thetext>oe-core c43c966e0ed4ed836bdf90b1d4c3f2f45426f1ec fixed this.

    oeqa/utils/targetbuild: tmp dir improvements

    Don&apos;t hard-code /tmp as the tmpdir, instead use WORKDIR as the tmpdir if the
    instantiater doesn&apos;t specify a value.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>