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

Typing transport and relateds. #271

Merged
merged 1 commit into from
Sep 8, 2023
Merged

Typing transport and relateds. #271

merged 1 commit into from
Sep 8, 2023

Conversation

zxzxwu
Copy link
Collaborator

@zxzxwu zxzxwu commented Sep 7, 2023

No description provided.

@zxzxwu
Copy link
Collaborator Author

zxzxwu commented Sep 7, 2023

Is it a good idea to make all sink/source inherited from a base class? Or a typing protocol is enough?

@barbibulle
Copy link
Collaborator

Is it a good idea to make all sink/source inherited from a base class? Or a typing protocol is enough?

I would prefer a Protocol based approach. The sinks and source concepts are very much intended for a Duck Typing approach. Definining a Sink and Source Protocol type rather than base classes would be great.

bumble/transport/__init__.py Outdated Show resolved Hide resolved
bumble/transport/__init__.py Outdated Show resolved Hide resolved
bumble/transport/file.py Outdated Show resolved Hide resolved
bumble/transport/tcp_server.py Outdated Show resolved Hide resolved
bumble/transport/ws_client.py Outdated Show resolved Hide resolved
@zxzxwu zxzxwu force-pushed the device_typing branch 4 times, most recently from 9c09128 to 30acab2 Compare September 7, 2023 17:11
bumble/host.py Outdated Show resolved Hide resolved
bumble/host.py Outdated Show resolved Hide resolved
bumble/transport/android_emulator.py Outdated Show resolved Hide resolved
bumble/transport/common.py Outdated Show resolved Hide resolved
bumble/transport/common.py Outdated Show resolved Hide resolved
bumble/transport/common.py Outdated Show resolved Hide resolved
@zxzxwu zxzxwu merged commit 01603ca into google:main Sep 8, 2023
16 checks passed
@zxzxwu zxzxwu deleted the device_typing branch September 8, 2023 16:56
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.

None yet

2 participants