Fix a bug in rpakernel.py introduced in merge