blob: 00924174c1e0baf22ecec501c450b8acd906049e [file] [log] [blame]
Patrick Williams92b42cb2022-09-03 06:53:57 -05001#
2# Copyright OpenEmbedded Contributors
3#
4# SPDX-License-Identifier: MIT
5#
6
Patrick Williamsc124f4f2015-09-15 14:41:29 -05007python primport_handler () {
8 import bb.event
9 if not e.data:
10 return
11
12 if isinstance(e, bb.event.ParseCompleted):
13 import oe.prservice
14 #import all exported AUTOPR values
15 imported = oe.prservice.prserv_import_db(e.data)
16 if imported is None:
17 bb.fatal("import failed!")
18
19 for (version, pkgarch, checksum, value) in imported:
20 bb.note("imported (%s,%s,%s,%d)" % (version, pkgarch, checksum, value))
21 elif isinstance(e, bb.event.ParseStarted):
22 import oe.prservice
23 oe.prservice.prserv_check_avail(e.data)
24}
25
26addhandler primport_handler
27primport_handler[eventmask] = "bb.event.ParseCompleted bb.event.ParseStarted"