Skip to content

adafruit_sdcard.SDcard f.read() fails on some files >= 1024 size #3259

@gmeader

Description

@gmeader

I have a problem reading certain JSON files stored on an SD card on a PyPortal Titano. Basically, if the size of the JSON string in the file is 1024 characters or larger, read() fails. If smaller, it works fine.
Here’s a short demo Python program. https://github.com/gmeader/pyportal/blob/master/bug_demo.py

anecdata: @gmeader Confirmed. I can read a >=1024 character file from CIRCUITPY, but not from SD Card. https://gist.github.com/anecdata/f59901af2922ad2279971a57894c2a24 (PyPortal 6.0.0-alpha.1 + latest lib)

Metadata

Metadata

Assignees

Type

No type
No fields configured for issues without a type.

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions