Bug 13542

Summary: File not found error when running hashserve tests
Product: [Build System, Metadata & Runtime] BitBake Reporter: Joshua Watt <JPEWhacker>
Component: bitbakeAssignee: Richard Purdie <richard.purdie>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: High CC: akuster, poky.bs.watcher, poky.watcher, richard.purdie
Version: 3.0   
Target Milestone: 2.8 M4   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)

Description Joshua Watt 2019-09-20 20:21:50 UTC
Occasionally when the hash equivalence server tests are run in bitbake the following error appears:

ERROR: test_hashserv_multiple_setscene (bb.tests.runqueue.RunQueueTests)
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/pokybuild/yocto-worker/oe-selftest-centos/build/bitbake/lib/bb/tests/runqueue.py", line 313, in test_hashserv_multiple_setscene
    self.assertEqual(tasks.count(i), 1, "%s not in task list once" % i)
  File "/usr/lib64/python3.6/tempfile.py", line 809, in __exit__
    self.cleanup()
  File "/usr/lib64/python3.6/tempfile.py", line 813, in cleanup
    _shutil.rmtree(self.name)
  File "/usr/lib64/python3.6/shutil.py", line 486, in rmtree
    _rmtree_safe_fd(fd, path, onerror)
  File "/usr/lib64/python3.6/shutil.py", line 444, in _rmtree_safe_fd
    onerror(os.unlink, fullname, sys.exc_info())
  File "/usr/lib64/python3.6/shutil.py", line 442, in _rmtree_safe_fd
    os.unlink(name, dir_fd=topfd)
FileNotFoundError: [Errno 2] No such file or directory: 'hashserve.sock'
Comment 1 Joshua Watt 2019-09-26 14:39:28 UTC
This appears to be caused by the hashserver being tardy in it's shutdown and racing with the test cleanup
Comment 3 Armin Kuster 2019-10-02 16:17:11 UTC
*** Bug 13564 has been marked as a duplicate of this bug. ***
Comment 4 Richard Purdie 2019-10-02 19:24:23 UTC
The original fix didn't work but this one should http://git.yoctoproject.org/cgit.cgi/poky/commit/?id=562de41ce7c576c96d55586637c156313c428ff4