ValueError: incompatible .mpy file

General discussions and questions abound development of code with MicroPython that is not hardware specific.
Target audience: MicroPython Users.
Post Reply
User avatar
devnull
Posts: 473
Joined: Sat Jan 07, 2017 1:52 am
Location: Singapore / Cornwall
Contact:

ValueError: incompatible .mpy file

Post by devnull » Sat Mar 23, 2019 9:16 am

Have just updated from 1.9.4 to 1.10.

Build of 1.10 was successful and loaded and running.

Also went into mpy-cross folder and did

Code: Select all

make clean
make
And the new file was generated, but when I build a file using this new mpy-cross I get the error:

Code: Select all

ValueError: incompatible .mpy file
Now I know that the eroor message is self-explanatory, but I am stumped

Any suggestions ?

User avatar
Roberthh
Posts: 3667
Joined: Sat May 09, 2015 4:13 pm
Location: Rhineland, Europe

Re: ValueError: incompatible .mpy file

Post by Roberthh » Sat Mar 23, 2019 9:26 am

mpy-cross is normally built and called for frozen bytecode by Makefile. That call uses the option -march=armv7m
Besides that: are you sure that the fresh built mpy-cross is called and not another copy that is in the path? Things like that use to happen to me.

User avatar
devnull
Posts: 473
Joined: Sat Jan 07, 2017 1:52 am
Location: Singapore / Cornwall
Contact:

Re: ValueError: incompatible .mpy file

Post by devnull » Sat Mar 23, 2019 9:40 am

Hi Robert;

Was just about to update when I saw your post, thanks for helping.

The problem was with a sub-module that was loaded inside the module I was calling, and not the file itself

Post Reply