Bug 15366 - RRS: rrs_upstream_history.py does not know how to parse 'inherit_defer'
Summary: RRS: rrs_upstream_history.py does not know how to parse 'inherit_defer'
Status: RESOLVED FIXED
Alias: None
Product: Recipe Reporting System (RRS)
Classification: Yocto Project Subprojects
Component: Recipe Reporting System (RRS) (show other bugs)
Version: 5.0
Hardware: x86 Multiple
: Medium normal
Target Milestone: 5.0
Assignee: Tim Orling
QA Contact: apoorv sangal
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2024-01-23 23:04 UTC by Tim Orling
Modified: 2024-02-13 19:20 UTC (History)
1 user (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Don't know


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tim Orling 2024-01-23 23:04:43 UTC
2024-01-23 00:07:17,904: DEBUG: Parsing /opt/workdir/git___git_openembedded_org_openembedded-core/meta/recipes-connectivity/openssh/openssh_9.5p1.bb
2024-01-23 00:07:17,910: ERROR: openembedded-core: master: branch /opt/workdir/git___git_openembedded_org_openembedded-core/meta/recipes-connectivity/openssh/openssh_9.5p1.bb couldn't be parsed, Traceback (most recent call last):
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 83, in get_statements
    return cached_statements[absolute_filename]
KeyError: '/opt/workdir/git___git_openembedded_org_openembedded-core/meta/classes/useradd.bbclass'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/opt/workdir/bitbake/lib/bb/command.py", line 90, in runCommand
    result = command_method(self, commandline)
  File "/opt/workdir/bitbake/lib/bb/command.py", line 577, in parseRecipeFile
    envdata = command.cooker.databuilder._parse_recipe(config_data, fn, appendfiles, mc, layername)[cls]
  File "/opt/workdir/bitbake/lib/bb/cookerdata.py", line 507, in _parse_recipe
    return bb.parse.handle(bbfile, bb_data)
  File "/opt/workdir/bitbake/lib/bb/parse/__init__.py", line 115, in handle
    return h['handle'](fn, data, include, baseconfig)
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 137, in handle
    statements.eval(d)
  File "/opt/workdir/bitbake/lib/bb/parse/ast.py", line 20, in eval
    statement.eval(data)
  File "/opt/workdir/bitbake/lib/bb/parse/ast.py", line 314, in eval
    bb.parse.BBHandler.inherit(self.classes, self.filename, self.lineno, data)
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 74, in inherit
    bb.parse.handle(file, d, True)
  File "/opt/workdir/bitbake/lib/bb/parse/__init__.py", line 115, in handle
    return h['handle'](fn, data, include, baseconfig)
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 130, in handle
    statements = get_statements(fn, abs_fn, base_name)
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 94, in get_statements
    feeder(lineno, s, filename, base_name, statements)
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/BBHandler.py", line 268, in feeder
    return ConfHandler.feeder(lineno, s, fn, statements, conffile=False)
  File "/opt/workdir/bitbake/lib/bb/parse/parse_py/ConfHandler.py", line 200, in feeder
    raise ParseError("unparsed line: '%s'" % s, fn, lineno);
bb.parse.ParseError: ParseError at /opt/workdir/git___git_openembedded_org_openembedded-core/meta/classes/useradd.bbclass:271: unparsed line: 'inherit_defer ${USERADDEXTENSION}'
Comment 1 Tim Orling 2024-01-23 23:09:35 UTC
Might instead be a problem of /opt/workdir/bitbake not being updated:

layers@updatelayers:/opt/workdir/bitbake$ git checkout master
Switched to branch 'master'
Your branch is behind 'origin/master' by 14 commits, and can be fast-forwarded.
  (use "git pull" to update your local branch)
layers@updatelayers:/opt/workdir/bitbake$ git pull
Updating 664de3f6d..5c2e840e
Fast-forward
 lib/bb/event.py                                              |  5 +--
 lib/bb/fetch2/__init__.py                                    |  2 +-
 lib/bb/fetch2/wget.py                                        |  2 +-
 lib/bb/parse/ast.py                                          | 31 ++++++++++++++---
 lib/bb/parse/parse_py/BBHandler.py                           | 10 +++++-
 lib/bb/runqueue.py                                           | 83 +++++++++++++++++++++++++++------------------
 lib/bb/server/process.py                                     | 10 ++++--
 lib/bb/tests/event.py                                        | 24 +++++++++++++
 lib/bb/tests/parse.py                                        | 98 +++++++++++++++++++++++++++++++++++++++++++++++++++++
 lib/bb/ui/knotty.py                                          | 62 +++++++++++++++++++++++++++------
 lib/toaster/tests/browser/selenium_helpers_base.py           |  7 ++++
 lib/toaster/tests/browser/test_all_builds_page.py            |  9 +++--
 lib/toaster/tests/browser/test_all_projects_page.py          |  3 +-
 lib/toaster/tests/browser/test_builddashboard_page.py        |  1 +
 lib/toaster/tests/browser/test_layerdetails_page.py          |  9 ++++-
 lib/toaster/tests/browser/test_new_custom_image_page.py      |  1 +
 lib/toaster/tests/browser/test_new_project_page.py           |  4 ++-
 lib/toaster/tests/functional/test_project_page.py            |  5 +--
 lib/toaster/tests/functional/test_project_page_tab_config.py |  2 +-
 19 files changed, 305 insertions(+), 63 deletions(-)
Comment 2 Tim Orling 2024-02-13 19:20:40 UTC
Fixed by doing a checkout of bitbake before running the rrs/tools/*.py scripts.

layers@updatelayers:/opt/layerindex$ cat rrs/tools/daily_run.sh
#!/bin/bash

cd /opt/workdir/bitbake && git checkout master && git pull origin master
/opt/layerindex/layerindex/update.py
/opt/layerindex/rrs/tools/rrs_maintainer_history.py -d
/opt/layerindex/rrs/tools/rrs_upgrade_history.py -d
/opt/layerindex/rrs/tools/rrs_upstream_history.py -d
#/opt/layerindex/rrs/tools/rrs_distros.py -d

if [ "$1" = "email" ]; then
        /opt/layerindex/rrs/tools/rrs_upstream_email.py
fi