You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
#43 first introduced websockets as a dependency, but the message classes in the s2-python package should also be usable outside of a WebSocket implementation, right?
Might I suggest making it into an optional subpackage?1 So users could then choose between:2
pip install s2-python # install S2 messages as Python classes
pip install s2-python[ws] # include support for WebSockets
Notes:
Footnotes
This concerns s2_connection.py and associated examples. ↩
I imagine future extensions like pip install s2-python[mqtt]↩
The text was updated successfully, but these errors were encountered:
I like this suggestion! It would be nice to have a clean split between types that are useful for any S2 implementation, and tooling that makes it easy to work with a specific format/protocol (ws/JSON in our case).
Is this common enough in the Python world that users will know to enable the subpackage? Or is there a way to make it enabled by default, but possible to disable for those who don't want websockets/JSON?
Is this common enough in the Python world that users will know to enable the subpackage?
I believe it is. For instance, Pandas uses it (pip install pandas[excel]). We've used it, too.
Or is there a way to make it enabled by default, but possible to disable for those who don't want websockets/JSON?
This is not an approach I've seen before with pip (nor after a few minutes of research). Of course, any installation instructions would deserve a prominent place in the documentation for this package.
#43 first introduced
websockets
as a dependency, but the message classes in thes2-python
package should also be usable outside of a WebSocket implementation, right?Might I suggest making it into an optional subpackage?1 So users could then choose between:2
Notes:
Footnotes
This concerns
s2_connection.py
and associated examples. ↩I imagine future extensions like
pip install s2-python[mqtt]
↩The text was updated successfully, but these errors were encountered: