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

Wait permissions to be set #15

Closed
wants to merge 1 commit into from

Conversation

philfifi
Copy link

@philfifi philfifi commented Oct 4, 2017

before accessing sysfs files. This is useful in the case a
udev rules in run to fix the permissions of the GPIO.

This fixes #14

before accessing sysfs files. This is useful in the case a
udev rules in run to fix the permissions of the GPIO.
Repository owner deleted a comment from coveralls Oct 5, 2017
Repository owner deleted a comment from coveralls Oct 5, 2017
Repository owner deleted a comment from coveralls Oct 5, 2017
Repository owner deleted a comment from coveralls Oct 5, 2017
Copy link
Owner

@rm-hull rm-hull left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • There are 5 bits of identical functionality -> these should be abstracted into a single method
  • Please add some tests to cover the branches in the new method
  • Please add some context (in the docstrings) about what problem this solves and what other things need to happen (e.g. how to add specific udev rules)

@philfifi
Copy link
Author

philfifi commented Oct 5, 2017

Thanks for the comments, I'll fix that and propose a new patch.

@rm-hull
Copy link
Owner

rm-hull commented Oct 5, 2017

We already use https://pypi.python.org/pypi/pyfakefs so it should be relatively easy to fake out scenarios where the file permissions are not set as expected.

@rm-hull
Copy link
Owner

rm-hull commented Sep 15, 2018

Merged #28 in preference to this PR (identical functionality)

@rm-hull rm-hull closed this Sep 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

race condition when using the library as non root user
2 participants