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

keyboard.py: allow 'import usb_hid' to fail #128

Merged
merged 1 commit into from
Sep 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ repos:
- id: end-of-file-fixer
- id: trailing-whitespace
- repo: https://github.com/pycqa/pylint
rev: v2.17.4
rev: v3.2.7
hooks:
- id: pylint
name: pylint (library code)
Expand Down
4 changes: 2 additions & 2 deletions adafruit_hid/keyboard.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@
"""

from micropython import const
import usb_hid

from .keycode import Keycode

from . import find_device

try:
from typing import Sequence
except: # pylint: disable=bare-except
import usb_hid
except ImportError:
pass

_MAX_KEYPRESSES = const(6)
Expand Down