Skip to content

Commit 83ac7e9

Browse files
Merge pull request #3134 from mitre/issue-3121
fix handler signature to address websocket errors
2 parents 140f1bc + dabc647 commit 83ac7e9

2 files changed

Lines changed: 4 additions & 3 deletions

File tree

app/contacts/contact_websocket.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,10 @@ def __init__(self, services):
3434
self.handles = []
3535
self.log = BaseWorld.create_logger('websocket_handler')
3636

37-
async def handle(self, socket, path):
37+
async def handle(self, connection):
3838
try:
39+
path = connection.request.path
3940
for handle in [h for h in self.handles if path.split('/', 1)[1].startswith(h.tag)]:
40-
await handle.run(socket, path, self.services)
41+
await handle.run(connection, path, self.services)
4142
except Exception as e:
4243
self.log.debug(e)

requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ aiohttp-apispec==3.0.0b2
66
jinja2==3.1.3
77
pyyaml==6.0.1
88
cryptography==42.0.2
9-
websockets==11.0.3
9+
websockets==15.0
1010
Sphinx==7.1.2
1111
sphinx_rtd_theme==1.3.0
1212
myst-parser==2.0.0

0 commit comments

Comments
 (0)