如何在站点包中强制重新编译py源? [英] How to force recompile of py source in site-packages?
本文介绍了如何在站点包中强制重新编译py源?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如果我编辑已安装程序包的源代码,并在重新启动使用该程序的应用程序时删除.pyc,则不会生成新的pyc,表明其他地方有缓存.
If I edit source of an installed package and delete the .pyc when I restart an app that uses it there is no new pyc generated in place indicating there is a cache elsewhere.
如何强制考虑对源的更新?
How do I force the update to source to be taken into account?
推荐答案
转到.py
文件的目录并运行python -m compileall .
.
Go to the directory of the .py
file and run python -m compileall .
.
这篇关于如何在站点包中强制重新编译py源?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文