FindUSB fails if new USB memory stick has no label.
Short-bus opened this issue · comments
Short-bus commented
Problem spotted by -PHU-
When I bought a new 32 GB stick recently, I ran into a certain weakness in pilomardisk.py.
A USB stick normally has four identifiers: amount of storage, file system, (own) serial ID and a label. This information is identified in pilomardisk.py by the process: def FindUSB.
When a fresh USB device is introduced, this device carries no label. The program pilomardisk.py then crashes on line 164, as the fourth item is empty.
In Linux and Windows normally the label is shown, but in case the label is absent, the serial number is shown. I think pilomardisk.py needs such a provision too.
Review the way USB memory is recognised and used. For example, is it is simpler to rely upon the RPi always booting to the desktop in order to find and mount the memory?
Short-bus commented
Latest copy in development will default back to SD card storage and issues a warning with common causes if USB storage search fails unexpectedly.
Short-bus commented
2024-04 Development branch now merged.
Closes this issue.