Skip to content

Commit 5ec195b

Browse files
committed
Remove PacketBuffer.packet_size
Fixes #2853
1 parent e3b3f97 commit 5ec195b

File tree

1 file changed

+1
-9
lines changed

1 file changed

+1
-9
lines changed

shared-bindings/_bleio/PacketBuffer.c

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ STATIC void check_for_deinit(bleio_packet_buffer_obj_t *self) {
9595

9696
//| def readinto(self, buf: WriteableBuffer) -> int:
9797
//| """Reads a single BLE packet into the ``buf``. Raises an exception if the next packet is longer
98-
//| than the given buffer. Use `packet_size` to read the maximum length of a single packet.
98+
//| than the given buffer. Use `incoming_packet_length` to read the maximum length of a single packet.
9999
//|
100100
//| :return: number of bytes read and stored into ``buf``
101101
//| :rtype: int"""
@@ -179,11 +179,6 @@ STATIC mp_obj_t bleio_packet_buffer_deinit(mp_obj_t self_in) {
179179
}
180180
STATIC MP_DEFINE_CONST_FUN_OBJ_1(bleio_packet_buffer_deinit_obj, bleio_packet_buffer_deinit);
181181

182-
//| packet_size: int
183-
//| """`packet_size` is the same as `incoming_packet_length`.
184-
//| The name `packet_size` is deprecated and
185-
//| will be removed in CircuitPython 6.0.0."""
186-
//|
187182
//| incoming_packet_length: int
188183
//| """Maximum length in bytes of a packet we are reading."""
189184
//|
@@ -233,9 +228,6 @@ STATIC const mp_rom_map_elem_t bleio_packet_buffer_locals_dict_table[] = {
233228
{ MP_OBJ_NEW_QSTR(MP_QSTR_readinto), MP_ROM_PTR(&bleio_packet_buffer_readinto_obj) },
234229
{ MP_OBJ_NEW_QSTR(MP_QSTR_write), MP_ROM_PTR(&bleio_packet_buffer_write_obj) },
235230

236-
// .packet_size is now an alias for .incoming_packet_length
237-
// TODO: Remove in 6.0.0.
238-
{ MP_OBJ_NEW_QSTR(MP_QSTR_packet_size), MP_ROM_PTR(&bleio_packet_buffer_incoming_packet_length_obj) },
239231
{ MP_OBJ_NEW_QSTR(MP_QSTR_incoming_packet_length), MP_ROM_PTR(&bleio_packet_buffer_incoming_packet_length_obj) },
240232
{ MP_OBJ_NEW_QSTR(MP_QSTR_outgoing_packet_length), MP_ROM_PTR(&bleio_packet_buffer_outgoing_packet_length_obj) },
241233
};

0 commit comments

Comments
 (0)