Description of problem: bkr machine-test --machine FQDN will schedule a job potentially against families which have been excluded for that host. The excluded families should not be included since they will just abort. Version-Release number of selected component (if applicable): 0.9.4
On Gerrit for review.. http://gerrit.beaker-project.org/#/c/1501/
Thanks for the patch, Bill.
Couple of issues, first this traceback: 2013-01-03 19:23:29,157 bkr.server.xmlrpccontroller ERROR Error handling XML-RPC method Traceback (most recent call last): File "/usr/lib/python2.6/site-packages/bkr/server/xmlrpccontroller.py", line 54, in RPC2 response = self.process_rpc(method,params) File "/usr/lib/python2.6/site-packages/bkr/server/xmlrpccontroller.py", line 43, in process_rpc response = obj(*params) File "<string>", line 3, in get_osmajor_arches File "/usr/lib/python2.6/site-packages/turbogears/identity/conditions.py", line 249, in require return fn(self, *args, **kwargs) File "/usr/lib/python2.6/site-packages/bkr/server/systems.py", line 274, in get_osmajor_arches query = query.filter(Distro._tags.any(DistroTag.tag.in_(tags))) NameError: global name 'Distro' is not defined Secondly, we can still get ine set the tag to STABLE if no tag is set explicitly. This seems reasonable, but the recipe will fail if the STABLE tag does not exist. If by default we specified no tag then the recipe would run, but then we could be testing the distro as much as we are the machine :-S I think the get_os_major_arches should query on tag STABLE, and if no distros are returned then we cannot run the test.
(In reply to comment #5) > Couple of issues, first this traceback: > > 2013-01-03 19:23:29,157 bkr.server.xmlrpccontroller ERROR Error handling > XML-RPC method > Traceback (most recent call last): > File "/usr/lib/python2.6/site-packages/bkr/server/xmlrpccontroller.py", > line 54, in RPC2 > response = self.process_rpc(method,params) > File "/usr/lib/python2.6/site-packages/bkr/server/xmlrpccontroller.py", > line 43, in process_rpc > response = obj(*params) > File "<string>", line 3, in get_osmajor_arches > File "/usr/lib/python2.6/site-packages/turbogears/identity/conditions.py", > line 249, in require > return fn(self, *args, **kwargs) > File "/usr/lib/python2.6/site-packages/bkr/server/systems.py", line 274, > in get_osmajor_arches > query = query.filter(Distro._tags.any(DistroTag.tag.in_(tags))) > NameError: global name 'Distro' is not defined http://gerrit.beaker-project.org/1599 > Secondly, we can still get ine set the tag to STABLE if no tag is set > explicitly. This seems reasonable, but the recipe will fail if the STABLE > tag does not exist. If by default we specified no tag then the recipe would > run, but then we could be testing the distro as much as we are the machine > :-S > > I think the get_os_major_arches should query on tag STABLE, and if no > distros are returned then we cannot run the test. Hmm the hardcoded 'STABLE' tag comes from the BeakerWorkflow base class. I see what you mean, it's problematic if we don't filter for 'STABLE' when picking families/arches but then we do include the filter in the job XML. Previously the machine-test command had hardcoded 'Active', but Bill took it out. I think we really need to get rid of all of these hardcoded tags, since they have no meaning outside of Red Hat, but that is a bigger issue. For now I am thinking I should restore the hardcoded 'Active' that we had before, since at least it's not a regression then.
(In reply to comment #6) > I think we really need to get rid of all of these hardcoded tags, since > they have no meaning outside of Red Hat, but that is a bigger issue. Turns out that's not true, STABLE does have meaning for all Beaker sites, not just Red Hat -- it's just not documented properly (filed bug 891827). So we can hardcode STABLE, we just need to do it properly: http://gerrit.beaker-project.org/1600
Verified that it does not run a job on excluded distros. It does however give the following: <job retention_tag="Scratch"><whiteboard>Test hx-pp.example.com</whiteboard></job> <Fault 1: "<class 'bkr.common.bexceptions.BX'>:'No RecipeSets! You can not have a Job with no recipeSets!'"> Submitted: [] That's a different problem though, and have opened a BZ for it 893878
Beaker 0.11.0 has been released.