Dimming my Lights via MQTT multiple times in quick succession makes them behave weirdly. Workarounds? Alternatives?

What I’ve tried so far:

-an automation including HAs’ MQTT integration that’s triggered by a macro on my Pc sending MQTT messages

alias: (MQTT) Dimming A Light Via PC Hotkeys
  description: ''
  trigger:
  - platform: mqtt
    topic: ahk
    payload: brighter
    id: brighter
  - platform: mqtt
    topic: ahk
    payload: darker
    id: darker
  condition: []
  action:
  - choose:
    - conditions:
      - condition: trigger
        id:
        - brighter
      sequence:
      - service: light.turn_on
        data:
          brightness_step_pct: 10
        target:
          entity_id: light.computer_room
    - conditions:
      - condition: trigger
        id:
        - darker
      sequence:
      - service: light.turn_on
        data:
          brightness_step_pct: -10
        target:
          entity_id: light.computer_room
  mode: parallel
  max: 6

What didn’t work about it:

If i toggle the macro a handful of times in quick succession all messages will be ignored for a few s. Running the automation in parallel- or queued mode with 6 queued items doesn’t relieve the problem either.

I’m confident the problem isn’t caused by my hotkey because each hotkey I send shows up in the log of HAs MQTT integration.

MQQT has very little overhead and should be very fast. Any chance you can share your automation for others to look at and maybe make suggestions on?

I updated my original post

another bump

Try Hass Agent.

Is it possible your device is not responding to the commands in quick succession? My thoughts are this is not an issue with mqtt or your buttons but the lights. Have you tried this with a different device or another way if you are trying to increase or decrease the brightness?