← index #6800Issue #4688
Related · high · value 2.924
QUERY · ISSUE

Build process: mpy file in frozen dir produces spam

openby peterhinchopened 2021-01-26updated 2024-09-13
enhancementtools

I inadvertently included a .mpy file in a directory containing .py files for freezing. On building, so much output spewed that the Bash history buffer filled; I couldn't scroll back far enough to see where the error first occurred.

It would be good if the build process either stopped with a clear message or ignored files without .py extensions with a warning.

CANDIDATE · ISSUE

error with frozen option

closedby supersjimmieopened 2019-04-10updated 2019-04-15

My issue looks like https://github.com/micropython/micropython/issues/4542 which was only assumed to be solved.

I use an esp32 with:
~/micropython/ports/esp32$ make FROZEN_MPY_DIR="frozen"
The error then is:

GEN build/frozen_mpy.c
usage: mpy-tool.py [-h] [-d] [-f] [-q QSTR_HEADER]
                   [-mlongint-impl {none,longlong,mpz}] [-mmpz-dig-size N]
                   files [files ...]
mpy-tool.py: error: the following arguments are required: files
../../py/mkrules.mk:122: recipe for target 'build/frozen_mpy.c' failed
make: *** [build/frozen_mpy.c] Error 2
make: *** Deleting file 'build/frozen_mpy.c'

(I don't use symlinks as discussed in the closed issue)
Dir ~/micropython/ports/esp32/frozen exists and is empty now.

Keyboard

j / / n
next pair
k / / p
previous pair
1 / / h
show query pane
2 / / l
show candidate pane
c
copy suggested comment
r
toggle reasoning
g i
go to index
?
show this help
esc
close overlays

press ? or esc to close

copied