Mac: hid_open_path in non exclusive mode #148
No reviewers
Labels
No labels
3rdparty
Android
API
Author does not respond
bsd
bug
build system/CI
ci-virtual-device
CMake
Contributions Welcome
Core
dependencies
device-specific
documentation
don't_merge
duplicate
enhancement
Example
Haiku
hidraw
hotplug
info required
invalid
libusb
macOS
Misc
Not an issue
question
Release
Test
Test GUI
Windows
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
gh-libusb/hidapi!148
Loading…
Reference in a new issue
No description provided.
Delete branch "master"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Based on https://github.com/signal11/hidapi/pull/453
The point is to be able to do it conditionally
The old behavior is might be required too
Can you do that with hidapi on Linux? My understand is that in Linux, hidapi does not use the device in exclusive mode. My intention with this PR is to make sure the behaviour on Mac is the same.
My motivation: I developed an application using this library on Linux, and it works great, but when I use the same application on Mac, it steals hid events from the rest of the environment. Essentially hidapi does not have consistency cross platform, and this impacts the functionality of cross platform applications using it
And you're not the first one :)
There're users, who are already using the library. They are relying on backward compatibility, when updating it.
Do you have examples of users who are expecting hidapi to work this way on Mac?
I don't
Do you have proof there is none?
No, but I do have a bunch who didn’t expect it to work the way it does, especially since the behaviour is different for different operating systems, and I don’t think this difference is documented.
I don’t really have the space to implement a new feature to specify which mode to use, so if you’re uncomfortable making the change proposed here then feel free to close this pr and I’ll just use my fork in my project and this bug will have to remain until someone else has time to fix it
"I don't have space/time" - is not a good excuse to fix something for some users, and potentially break something for others (we've been there)
I do believe we need to fix this, and yes, someone has to spend additional time to have this fix, AND allow the old behavior, AND don't break API/ABI compatibility for those who don't care
That "someone" is likely going to be myself
Since you came here and raised the issue one more time, I'll move it higher in my TODO list, but I strongly disagree to accept half measures
There'is other active maintainers/contributors, @libusb/hidapi @z3ntu, you'r opinion is welcome here too.
Although I disagree, I understand your position. Good luck with the project. It would be nice to see this fixed.
Thanks, we'll do our best
Pull request closed