Bug 14722

Summary: ERROR: SState: cannot test file
Product: [Build System, Metadata & Runtime] BitBake Reporter: Michael Opdenacker <michael.opdenacker>
Component: bitbakeAssignee: Richard Purdie <richard.purdie>
Status: RESOLVED INVALID QA Contact:
Severity: minor    
Priority: Undecided CC: poky.bs.watcher, poky.watcher, randy.macleod
Version: 4.0   
Target Milestone: ---   
Hardware: x86   
OS: Multiple   
Whiteboard:
OS type for building Yocto: --- Type of Regression: ---
Verified: Documentation change: No (bug/feature does not impact docs)
Attachments:
Description Flags
Bitbake log none

Description Michael Opdenacker 2022-02-14 17:57:36 UTC
Created attachment 4850 [details]
Bitbake log

Greetings

I got ugly but non blocking errors after running "bitbake core-image-minimal" and then interrupting the process during "Checking sstate mirror object availability".

I used [Ctrl][c] and used the "ps" command to kill any surviving bitbake related process ("ps -auxww | grep bitbake").

Then, running "bitbake core-image-minimal" again, I got the below kind of error in the output:

Initialising tasks: 100% |############################################################################################################################################################################################| Time: 0:00:02
ERROR: SState: cannot test file://41/ad/sstate:v86d:qemux86_64-poky-linux:0.1.10:r2:qemux86_64:8:41adea8823d916914437a48bcfe534574e04004415c74a3f3482c895e3107655_deploy_source_date_epoch.tar.zst: timeout('The read operation timed out')
Traceback (most recent call last):
  File "/media/mike/ssd/yocto/poky/meta/classes/sstate.bbclass", line 1000, in checkstatus
    fetcher.checkstatus()
  File "/media/mike/ssd/yocto/poky/bitbake/lib/bb/fetch2/__init__.py", line 1816, in checkstatus
    ret = m.try_mirrors(self, ud, self.d, mirrors, True)
  File "/media/mike/ssd/yocto/poky/bitbake/lib/bb/fetch2/__init__.py", line 1589, in try_mirrors
    return bool(try_mirrors(fetch, d, urldata, mirrors, check))
  File "/media/mike/ssd/yocto/poky/bitbake/lib/bb/fetch2/__init__.py", line 1115, in try_mirrors
    ret = try_mirror_url(fetch, origud, uds[index], ld, check)
  File "/media/mike/ssd/yocto/poky/bitbake/lib/bb/fetch2/__init__.py", line 1010, in try_mirror_url
    found = ud.method.checkstatus(fetch, ud, ld)
  File "/media/mike/ssd/yocto/poky/bitbake/lib/bb/fetch2/wget.py", line 369, in checkstatus
    with opener.open(r, timeout=30) as response:
  File "/usr/lib/python3.8/urllib/request.py", line 525, in open
    response = self._open(req, data)
  File "/usr/lib/python3.8/urllib/request.py", line 542, in _open
    result = self._call_chain(self.handle_open, protocol, protocol +
  File "/usr/lib/python3.8/urllib/request.py", line 502, in _call_chain
    result = func(*args)
  File "/usr/lib/python3.8/urllib/request.py", line 1397, in https_open
    return self.do_open(http.client.HTTPSConnection, req,
  File "/usr/lib/python3.8/urllib/request.py", line 1358, in do_open
    r = h.getresponse()
  File "/usr/lib/python3.8/http/client.py", line 1348, in getresponse
    response.begin()
  File "/usr/lib/python3.8/http/client.py", line 316, in begin
    version, status, reason = self._read_status()
  File "/usr/lib/python3.8/http/client.py", line 277, in _read_status
    line = str(self.fp.readline(_MAXLINE + 1), "iso-8859-1")
  File "/usr/lib/python3.8/socket.py", line 669, in readinto
    return self._sock.recv_into(b)
  File "/usr/lib/python3.8/ssl.py", line 1241, in recv_into
    return self.read(nbytes, buffer)
  File "/usr/lib/python3.8/ssl.py", line 1099, in read
    return self._sslobj.read(len, buffer)
socket.timeout: The read operation timed out

There were more errors of this kind, but it didn't prevent Bitbake from proceeding with the build job. 

Because of this, and because of the special case that triggered it, I consider this bug as a minor one.

See the full log for details...
Comment 1 Michael Opdenacker 2022-02-14 17:58:51 UTC
Note that I was using the latest "master" branch from Poky as of 2022-02-14.
Comment 2 Randy MacLeod 2022-02-17 15:38:30 UTC
Likely just that the server for sstate is overloaded and not responding.
We have other defects to deal with this.
Comment 3 Michael Opdenacker 2022-02-17 15:39:26 UTC
I confirm that I am using the sstate servers:
SSTATE_MIRRORS ?= "file://.* https://sstate.yoctoproject.org/dev/PATH;downloadfilename=PATH"