使用pyinstaller進行python程序打包的時候,在https://github.com/pyinstaller/pyinstaller/wiki/Supported-Packages上看到對於pyecharts的支持不好,因此不能將pyecharts打包到程序當中,會出現如下的錯誤,參考https://www.yinyubo.cn/?p=177,在pyinstaller打包后的程序根目錄建立文件夾pyecharts,將pyecharts在python環境中的template整個拷出來放到打包后的主程序的pyecharts目錄下。

再運行還是會出現以下錯誤

此時在pyinstaller打包后的程序的根目錄下建立文件夾jupyter_echarts_pypkg,將jupyter_echarts_pypkg這個模塊的resources這個目錄頁復制到pyinstalller打包后的主程序的jupyter_echarts_pypkg目錄中。
