Open
Description
In 10.0.0 alpha 6, when reading a fixed number of bytes from usb_cdc above a certain size (7936) and above, a memory allocation error is thrown (from a new REPL). It doesn't happen with lower values.
This seems to start happening with #10264
Tested on a Clue too.
Adafruit CircuitPython 10.0.0-alpha.6 on 2025-05-17; SparkFun Pro Micro RP2040 with rp2040
>>> import usb_cdc
>>> data = usb_cdc.data.read(7936)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
MemoryError: memory allocation failed, allocating 7937 bytes