Page 1 of 1

unix port does not support PYTHONPATH?

Posted: Thu Jan 06, 2022 5:39 am
by yjchun
It seems PYTHONPATH is not recognized by unix port of micropython. How do you set import path for unix micropython, without modifying source code?
And if I have to modify sys.path for unix micropython, where is good place put the code? Is there a bootstrap script for unix port?

I want to use unix micropython to run test scripts quickly without installing firmware.

Re: unix port does not support PYTHONPATH?

Posted: Thu Jan 06, 2022 7:22 am
by stijn
MICROPYPATH is the equivalent. Would make no sense to use PYTHONPATH because that would make it very awkward to use both Python and MicroPython.

I don't think any 'bootstrap script' or similar is implemented for PC ports.

Re: unix port does not support PYTHONPATH?

Posted: Thu Jan 06, 2022 9:34 am
by yjchun
Thank you. Problem solved.