From 9da05e5cb742aec20372679c41d83c89fcab56df Mon Sep 17 00:00:00 2001 From: taras Date: Thu, 15 Aug 2024 13:54:37 +0200 Subject: [PATCH] Fix doc build --- .readthedocs.yaml | 2 +- README.rst | 4 ++-- picows/picows.pyx | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/.readthedocs.yaml b/.readthedocs.yaml index f71a2fe..7f9dc7b 100644 --- a/.readthedocs.yaml +++ b/.readthedocs.yaml @@ -13,7 +13,7 @@ build: # Build documentation in the "docs/" directory with Sphinx sphinx: - configuration: docs/conf.py + configuration: docs/source/conf.py # Optional but recommended, declare the Python requirements required # to build your documentation diff --git a/README.rst b/README.rst index 17cd38b..9b35241 100644 --- a/README.rst +++ b/README.rst @@ -97,8 +97,8 @@ Echo server print("New client connected") def on_ws_frame(self, transport: WSTransport, frame: WSFrame): - transport.send(frame.opcode, frame.get_payload_as_bytes()) - if frame.opcode == WSMsgType.CLOSE: + transport.send(frame.msg_type, frame.get_payload_as_bytes()) + if frame.msg_type == WSMsgType.CLOSE: transport.disconnect() async def main(): diff --git a/picows/picows.pyx b/picows/picows.pyx index 6b5cf7f..f872f5f 100644 --- a/picows/picows.pyx +++ b/picows/picows.pyx @@ -113,7 +113,7 @@ cdef class WSFrame: Internally WSFrame just points to a chunk of memory in the receiving buffer without copying or owning memory.\n .. DANGER:: Only use WSFrame object during :any:`WSListener.on_ws_frame` callback. WSFrame objects are essentially just - pointers to the underlying receiving buffer. After :any:`WSListener.on_ws_frame` is completed the buffer + pointers to the underlying receiving buffer. After :any:`WSListener.on_ws_frame` has completed the buffer will be reused for the new incoming data. In order to actually copy payload use one of the `get_*` methods. @@ -153,7 +153,7 @@ cdef class WSFrame: .. DANGER:: Returned memoryview does NOT own the underlying memory. - The content will be invalidated after :any:`WSListener.on_ws_frame` is complete. + The content will be invalidated after :any:`WSListener.on_ws_frame` has completed. Please process payload or copy it as soon as possible. """ return PyMemoryView_FromMemory(self.payload_ptr, self.payload_size, PyBUF_READ)