human
Here's a good function header given the following:
I wrote the below code

    import RFXtrx as rfxtrxmod
    lights = rfxtrx.get_devices_from_config(config, RfxtrxLight, hass)
    add_devices(lights)
    def light_update(event):
        'Handle    light    updates    from    the    RFXtrx    gateway.'
        if ((not isinstance(event.device, rfxtrxmod.LightingDevice)) or (not event.device.known_to_be_dimmable)):
            return
        new_device = rfxtrx.get_new_device(event, config, RfxtrxLight, hass)
        if new_device:
            add_devices([new_device])
        rfxtrx.apply_received_command(event)
    if (light_update not in rfxtrx.RECEIVED_EVT_SUBSCRIBERS):
        rfxtrx.RECEIVED_EVT_SUBSCRIBERS.append(light_update)

What's a good function header?
assistant
#Here's a good function header.

def setup_platform(hass, config, add_devices, discovery_info=None):