Unpacking LittleFS fails (argument missing)
Henning-Lenz opened this issue · 1 comments
First I'd like to thank for this script, it should be included as standard action in PlatformIO.
I just started using little FS and because uploading is one thing, also (temperature logger) files should be downloaded. Everything seems to work fine till the final unpack step which somehow errors out as following:
Executing extraction command: ['/home/user/.platformio/packages/tool-mklittlefs/mklittlefs', '-b', '8192', '-p', '256', '--unpack', 'unpacked_fs', '/home/user/GIT/Temperature_measurement/.pio/build/nodemcuv2/downloaded_fs_0x300000_0xfa000.bin']
PARSE ERROR:
Required arguments missing: list, unpack, create, image_file
Brief USAGE:
/home/user/.platformio/packages/tool-mklittlefs/mklittlefs {-c
<pack_dir>|-u <dest_dir>|-l} [-d
<0-5>] [-a] [-b <number>] [-p
Unpacked filesystem.
<number>] [-s <number>] [--]
[--version] [-h] <image_file>
Extracted 0 file(s) from filesystem.
For complete USAGE and HELP type:
/home/user/.platformio/packages/tool-mklittlefs/mklittlefs --help
After trying to run the command directly from bash (works) and from Python (did not work instantly), I found out that changing shell=False here makes the script fully working. This line was recently changed with 1b44b66, before it was (defaulting to) False from the very beginning.
As the real problem seems to be that the command parts are not joined also " ".join(cmd) with shell=True does the job, but in my case it does not make sense to go for that.
Environment is Chromium 1.83.0.23277-r1 and PlatformIO 3.3.1 running under Linux with Python 3.11.5
Thanks for the report, I'll double check the commands. It also probably has something to do with the version of mklittlefs, with there being some possible differences in the arguments they accept.