Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mac: hid_open_path in non exclusive mode #148

Closed
wants to merge 1 commit into from
Closed

Mac: hid_open_path in non exclusive mode #148

wants to merge 1 commit into from

Conversation

mattsains
Copy link

@Youw
Copy link
Member

Youw commented Feb 22, 2020

The point is to be able to do it conditionally
The old behavior is might be required too

@mattsains
Copy link
Author

mattsains commented Feb 22, 2020

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

@Youw
Copy link
Member

Youw commented Feb 22, 2020

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.

@mattsains
Copy link
Author

Do you have examples of users who are expecting hidapi to work this way on Mac?

@Youw
Copy link
Member

Youw commented Feb 22, 2020

I don't

Do you have proof there is none?

@mattsains
Copy link
Author

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

@Youw
Copy link
Member

Youw commented Feb 22, 2020

"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.

@mattsains
Copy link
Author

Although I disagree, I understand your position. Good luck with the project. It would be nice to see this fixed.

@mattsains mattsains closed this Feb 22, 2020
@Youw
Copy link
Member

Youw commented Feb 22, 2020

Thanks, we'll do our best

@mcuee mcuee added the macOS Related to macOS backend label Jul 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
macOS Related to macOS backend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants