Luna
d21b3c8f2a
lvsp: add "common logic scenarios"
2019-03-05 00:59:37 -03:00
Luna
579a71dd9b
lvsp_conn: add basic INFO handling for channel assign
...
- lvsp: finish defining data for channel info messages
- lvsp_conn: add send_info()
- lvsp_opcodes: add InfoTable, InfoReverse
- voice.manager: handle channels without bitrate
2019-03-04 22:46:09 -03:00
Luna
00100f9abb
voice.manager: add VST_REQ call
2019-03-04 21:32:04 -03:00
Luna
e2af6b6370
voice: more voice goodies
...
- lvsp manager: change internal structure of lvsp conns
- voice.manager: add incomplete impl for creating a channel
2019-03-04 20:46:14 -03:00
Luna
9dab5b20ae
typing, episode 2
2019-03-04 15:48:51 -03:00
Luna
ed3c436b6d
channels, guild.roles, user.billing: typing fixes
2019-03-04 15:19:05 -03:00
Luna
68c6442375
storage: fix more type hints, handle None on more places
2019-03-04 15:12:38 -03:00
Luna
bbf80f72b1
fix tests and an ugly circular import
2019-03-04 05:24:40 -03:00
Luna
d91030a2c1
typings, episode 1
...
(i installed mypy and its beautiful)
2019-03-04 05:09:04 -03:00
Luna
506bd8afbe
pipenv: add mypy
2019-03-04 04:30:27 -03:00
Luna
627d87b4a7
lvsp_conn: remove unused var
2019-03-04 03:20:34 -03:00
Luna
0759a52046
pubsub.lazy_guild: s/pop/remove on remove_channel
2019-03-04 03:16:28 -03:00
Luna
ad7f93b40a
add guild.region = null consistency checker
...
as soon as a voice region is added, we should move all guilds to it. or
if there are any guilds with a NULL region, we select one at random.
region being NULL causes the client to be unable to change it, so..
- channels: fix update handlers for guild channels
2019-03-04 03:00:46 -03:00
Luna
336f3a6eaf
lvsp_conn: handle errors when connecting to voice server
2019-03-04 01:29:14 -03:00
Luna
9d80cb5564
admin_api.voice: handle UniqueViolationError
2019-03-04 01:26:53 -03:00
Luna
2d7dc05453
lvsp_manager: fix bug when fetching regions
2019-03-04 01:22:18 -03:00
Luna
4a792966f1
voice: fix bugs
2019-03-04 01:21:06 -03:00
Luna
547353e8a5
admin_api.voice: remove unused vars
2019-03-04 00:48:32 -03:00
Luna
cb029b36e3
add admin api (w/ voice endpoints)
...
- add docs/admin_api.md
- add litecord.voice_schemas
- auth: add admin_check
- voice.manager: add VoiceManager.voice_server_list
2019-03-04 00:37:56 -03:00
Luna
b71aec5aa1
add basic LVSP client implementation
2019-03-03 20:16:17 -03:00
Luna
7fdb74370e
add better implementation for GET /voice/region
...
this takes account of:
- the majority region selected in all the guilds the user owns. if that
fails:
- the majority region on all the guilds the user is in. if that fails:
- random region
- storage: add Storage.all_voice_regions
2019-03-03 18:57:54 -03:00
Luna
42cd0ae12c
lvsp_manager: handle no region case
2019-03-03 18:41:27 -03:00
Luna
9d853f0bda
lvsp_manager: add basic region spawn code
2019-03-03 18:40:35 -03:00
Luna
287678331d
add voice_regions, voice_servers, and guild.region foreign key
2019-03-03 18:11:11 -03:00
Luna
287368ad1c
litecord.voice: add LVSPManager, LVSPConnection
2019-03-03 04:30:41 -03:00
Luna
62d1252975
lvsp: remove VST REQUEST in favour of a generic INFO message
...
- lvsp: add sequence numbers
- lvsp: add health scoring on heartbeats and ready
- lvsp: change info table to allow for generic actions
2019-03-03 02:40:39 -03:00
Luna
307feacc78
gateway.websocket, voice.manager: quickfixes
2019-03-03 00:13:32 -03:00
Luna
3a6073468e
rm litecord/voice/utils.py
2019-03-03 00:05:33 -03:00
Luna
c6aea0b7b1
gateway.websocket: rewrite op 4 handler
...
mostly we moved the permission checks from the websocket to the voice
manager.
- voice.manager: add leave_all(), leave()
- voice.state add VoiceState.guild_id, VoiceState.key
2019-03-03 00:04:08 -03:00
Luna
d47d79977b
gateway.websocket: handle chan_id=None
...
- gateway.websocket: change fetch_state to get_state
- voice.manager: add get_state()
2019-03-01 18:35:46 -03:00
Luna
22402fd4cb
voice.manager: add fetch_states() impl
...
- storage: follow the impl
2019-03-01 18:29:41 -03:00
Luna
75a52a5ac8
storage: add voice state fetch
2019-03-01 18:25:22 -03:00
Luna
ec738cd41e
voice.manager: add some functions
...
- add voice.state with VoiceState dataclass
2019-03-01 18:17:07 -03:00
Luna
8cf6a28b58
storage: formatting
2019-03-01 17:32:21 -03:00
Luna
6d0f4e775c
Merge branch 'voice' of gitlab.com:litecord/litecord into voice
2019-03-01 17:31:33 -03:00
Luna
f8b808c7b4
remove unused import
2019-03-01 17:30:44 -03:00
Luna
e22deb316f
gateway.websocket: add voice state property fetch
...
- gateway.websocket: handle when vsu.channel_id and vsu.guild_id are
none
2019-03-01 17:29:40 -03:00
gabixdev
919d8be2cb
Update lvsp.md
2019-03-01 15:48:29 +00:00
gabixdev
e2258ed728
Make the secret actually secret, use HMAC for authentication
2019-03-01 15:45:49 +00:00
Luna
5d2869b53c
remove voice websocket implementation
...
voice websockets are left to the voice server itself.
2019-03-01 04:48:05 -03:00
Luna
f22a9b92a9
remove voice websocket fields from configs
...
- run: remove vws spawn
- tests.conftest: rollback to unused_tcp_port fixture
2019-03-01 04:39:12 -03:00
Luna
2711924e03
move from lvsp/00-connecting.md to lvsp.md
...
add some more stuff like INFO and VST\_REQUEST messages
2019-03-01 04:33:09 -03:00
Luna
7270462325
add litecord voice server protocol (lvsp) draft
2019-03-01 03:12:50 -03:00
Luna
1bc04449bd
add some dummy impl for vws v4
...
will be removed as this should be on the voice server instead. litecord
manages simple voice state and dispatches voice state updates (such as
speaking=1)
2019-03-01 02:25:52 -03:00
Luna
cbf6a3d441
run: remove unused loop variable
2019-02-28 23:14:56 -03:00
Luna
ca5386d3ce
add VOICE_WEBSOCKET_URL to configs
...
- gateway: remove implicit /ws path, leave it up to configs
- run: fix start_websocket
2019-02-28 23:12:19 -03:00
Luna
f3bc65302d
add voice websocket instantiation
2019-02-28 21:16:32 -03:00
Luna
0d38c7cc0c
gateway.websocket: add basic vsu handling
...
this adds *theoretical* interfaces to a VoiceManager. The actual
VoiceManager does not work and probably any VSU being sent over will
crash the websocket with an AttributionError.
- enums: add VOICE_CHANNELS
- run: add App.voice attribute
2019-02-28 20:51:09 -03:00
Luna
9a42d20259
guild.roles: s/logging/logbook
2019-02-27 00:16:12 -03:00
Luna
f2bfb901c7
storage: fix get_invite for non-guild invites
2019-02-27 00:11:11 -03:00