Checks need to handle array branches differently
Currently if one tries to run a range check on a branch of arrays you can get the error
Traceback (most recent call last):
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/bin/lb-ap", line 8, in <module>
sys.exit(main())
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/click/core.py", line 1128, in __call__
return self.main(*args, **kwargs)
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/click/core.py", line 1053, in main
rv = self.invoke(ctx)
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/click/core.py", line 1659, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/click/core.py", line 1395, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/click/core.py", line 754, in invoke
return __callback(*args, **kwargs)
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/LbAPLocal/cli.py", line 357, in ci_checks
check_results = run_job_checks(
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/LbAPCommon/checks.py", line 46, in run_job_checks
check_results[check] = range_check(
File "/cvmfs/lhcb.cern.ch/lib/var/lib/LbEnv/2361/stable/linux-64/lib/python3.9/site-packages/LbAPCommon/checks.py", line 232, in range_check
(test_array < limits["max"]) & (test_array > limits["min"])
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
so we need a way to check which events satisfy the given range and record the values when the branch to be checked is an array.