Direction
Treat this as an upstream-first Kanata compatibility project, independent of KeyPath integration.
The immediate goal is to make the latest upstream Kanata compatible with the current Karabiner-DriverKit-VirtualHIDDevice protocol, validate the result as a standalone Kanata change, submit it upstream, and get it merged. KeyPath should consume the upstream result afterward in a separate integration step.
Do not update the KeyPath submodule, bundled driver package, release scripts, installer, or macOS 27 lane as part of the upstream PR.
Context
Karabiner-DriverKit-VirtualHIDDevice v8.0.0 uses client protocol 7. The Kanata driverkit client currently targets the older protocol-5 API and local-datagram transport.
Breaking changes since the currently supported driver include:
- v7 changed IPC from
pqrs::local_datagram to pqrs::unix_domain_stream and moved the client protocol from 5 to 6.
- v8 removed
virtual_hid_device_service::request::get_status, changed subsequent request enum values, removed virtual_hid_device_service/utility.hpp, and moved the protocol from 6 to 7.
- Clients using the embedded C++ headers must be rebuilt and adapted to the new API.
KeyPath also carries Kanata-side work that must not be lost when designing the upstream change:
Verify authorship and current upstream provenance before deciding whether each behavior should be ported, redesigned, or omitted.
Phase 1: upstream Kanata implementation
Work from the latest jtroo/kanata main branch in a dedicated Kanata checkout and branch.
- Reproduce the current incompatibility against VirtualHIDDevice v8.
- Update the Kanata
karabiner-driverkit client and vendored headers/source to the selected current protocol.
- Replace removed status APIs with the supported client signals:
driver_activated
virtual_hid_keyboard_ready
virtual_hid_pointing_ready
- Port the reconnect, report-reset, convergence, and stuck-key protections where they remain semantically necessary.
- Add focused automated coverage around protocol framing/state, readiness transitions, reconnect behavior, report convergence, and shutdown cleanup.
- Test standalone Kanata with the matching current VirtualHID daemon on supported macOS versions available outside KeyPath.
- Keep the upstream diff focused and free of KeyPath-specific paths, packaging, naming, or assumptions.
- Open a PR against
jtroo/kanata, address upstream review and CI, and continue until it is merged.
Upstream acceptance criteria
- Latest upstream Kanata builds against and communicates with the selected current VirtualHIDDevice release.
- Client and daemon use the same protocol version.
- No references remain to removed v8 APIs.
- Keyboard output, readiness, reconnect, shutdown, and stuck-key recovery are validated.
- The implementation is acceptable upstream and the Kanata PR is merged.
Phase 2: KeyPath integration
Begin only after the upstream Kanata work is merged.
Create a separate KeyPath issue or focused follow-up PR to:
- update the KeyPath Kanata fork from the merged upstream commit
- reconcile any remaining KeyPath-only patches without duplicating upstream behavior
- update the bundled VirtualHID package and release tooling
- rebuild the Kanata engine and host bridge
- run signed/notarized install and upgrade verification
- hand the resulting build to the separate macOS 27 validation lane
Non-goals for the upstream PR
- KeyPath installer or UI changes
- KeyPath release packaging
- KeyPath submodule updates
- broad Kanata macOS architecture cleanup
- claiming macOS 27 support without that lane completing its own validation
Completion rule
This ticket is complete when the standalone Kanata protocol migration has been merged upstream and a clearly scoped KeyPath integration follow-up exists. KeyPath adoption is downstream work, not part of the upstream PR.
Direction
Treat this as an upstream-first Kanata compatibility project, independent of KeyPath integration.
The immediate goal is to make the latest upstream Kanata compatible with the current Karabiner-DriverKit-VirtualHIDDevice protocol, validate the result as a standalone Kanata change, submit it upstream, and get it merged. KeyPath should consume the upstream result afterward in a separate integration step.
Do not update the KeyPath submodule, bundled driver package, release scripts, installer, or macOS 27 lane as part of the upstream PR.
Context
Karabiner-DriverKit-VirtualHIDDevice v8.0.0 uses client protocol 7. The Kanata driverkit client currently targets the older protocol-5 API and local-datagram transport.
Breaking changes since the currently supported driver include:
pqrs::local_datagramtopqrs::unix_domain_streamand moved the client protocol from 5 to 6.virtual_hid_device_service::request::get_status, changed subsequent request enum values, removedvirtual_hid_device_service/utility.hpp, and moved the protocol from 6 to 7.KeyPath also carries Kanata-side work that must not be lost when designing the upstream change:
malpern/kanataPR refactor(wizard): consolidate service pages (Communication + Kanata Service) #26, commit7890acfea7ec53Verify authorship and current upstream provenance before deciding whether each behavior should be ported, redesigned, or omitted.
Phase 1: upstream Kanata implementation
Work from the latest
jtroo/kanatamain branch in a dedicated Kanata checkout and branch.karabiner-driverkitclient and vendored headers/source to the selected current protocol.driver_activatedvirtual_hid_keyboard_readyvirtual_hid_pointing_readyjtroo/kanata, address upstream review and CI, and continue until it is merged.Upstream acceptance criteria
Phase 2: KeyPath integration
Begin only after the upstream Kanata work is merged.
Create a separate KeyPath issue or focused follow-up PR to:
Non-goals for the upstream PR
Completion rule
This ticket is complete when the standalone Kanata protocol migration has been merged upstream and a clearly scoped KeyPath integration follow-up exists. KeyPath adoption is downstream work, not part of the upstream PR.