{"id":1119075,"date":"2025-01-08T18:41:21","date_gmt":"2025-01-08T10:41:21","guid":{"rendered":"https:\/\/docs.pingcode.com\/ask\/ask-ask\/1119075.html"},"modified":"2025-01-08T18:41:24","modified_gmt":"2025-01-08T10:41:24","slug":"%e5%a6%82%e4%bd%95%e4%bd%bf%e7%94%a8python%e7%bc%96%e5%86%99%e5%8f%af%e6%89%a7%e8%a1%8c%e6%96%87%e4%bb%b6","status":"publish","type":"post","link":"https:\/\/docs.pingcode.com\/ask\/1119075.html","title":{"rendered":"\u5982\u4f55\u4f7f\u7528python\u7f16\u5199\u53ef\u6267\u884c\u6587\u4ef6"},"content":{"rendered":"<p style=\"text-align:center;\" ><img decoding=\"async\" src=\"https:\/\/cdn-kb.worktile.com\/kb\/wp-content\/uploads\/2024\/04\/25082316\/bd23dc4a-90d9-454b-a9fb-a50a2271298f.webp\" alt=\"\u5982\u4f55\u4f7f\u7528python\u7f16\u5199\u53ef\u6267\u884c\u6587\u4ef6\" \/><\/p>\n<p><p> <strong>\u8981\u4f7f\u7528Python\u7f16\u5199\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u4f60\u53ef\u4ee5\u4f7f\u7528\u4e00\u4e9b\u5de5\u5177\u548c\u5e93\uff0c\u5982PyInstaller\u3001cx_Freeze\u3001py2exe\u7b49\u3002<\/strong> \u8fd9\u4e9b\u5de5\u5177\u53ef\u4ee5\u5c06Python\u811a\u672c\u6253\u5305\u6210\u72ec\u7acb\u7684\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u4f7f\u5176\u5728\u6ca1\u6709\u5b89\u88c5Python\u89e3\u91ca\u5668\u7684\u73af\u5883\u4e2d\u8fd0\u884c\u3002\u672c\u6587\u5c06\u8be6\u7ec6\u4ecb\u7ecd\u5982\u4f55\u4f7f\u7528PyInstaller\u5c06Python\u811a\u672c\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\u3002<\/p>\n<\/p>\n<p><p>\u4e00\u3001\u5b89\u88c5PyInstaller<\/p>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u4f60\u9700\u8981\u5b89\u88c5PyInstaller\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528pip\u6765\u5b89\u88c5\u5b83\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pip install pyinstaller<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>PyInstaller\u652f\u6301\u591a\u5e73\u53f0\uff0c\u56e0\u6b64\u65e0\u8bba\u4f60\u4f7f\u7528\u7684\u662fWindows\u3001macOS\u8fd8\u662fLinux\uff0c\u90fd\u53ef\u4ee5\u5b89\u88c5\u5e76\u4f7f\u7528\u5b83\u3002<\/p>\n<\/p>\n<p><p>\u4e8c\u3001\u7f16\u5199Python\u811a\u672c<\/p>\n<\/p>\n<p><p>\u63a5\u4e0b\u6765\uff0c\u6211\u4eec\u9700\u8981\u7f16\u5199\u4e00\u4e2a\u7b80\u5355\u7684Python\u811a\u672c\u3002\u4f8b\u5982\uff0c\u7f16\u5199\u4e00\u4e2a\u540d\u4e3a<code>hello.py<\/code>\u7684\u811a\u672c\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\"># hello.py<\/p>\n<p>def m<a href=\"https:\/\/docs.pingcode.com\/blog\/59162.html\" target=\"_blank\">AI<\/a>n():<\/p>\n<p>    print(&quot;Hello, world!&quot;)<\/p>\n<p>if __name__ == &quot;__main__&quot;:<\/p>\n<p>    main()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u4e2a\u811a\u672c\u975e\u5e38\u7b80\u5355\uff0c\u5f53\u8fd0\u884c\u65f6\uff0c\u5b83\u4f1a\u6253\u5370\u201cHello, world!\u201d\u3002<\/p>\n<\/p>\n<p><p>\u4e09\u3001\u4f7f\u7528PyInstaller\u6253\u5305Python\u811a\u672c<\/p>\n<\/p>\n<p><p>\u73b0\u5728\uff0c\u6211\u4eec\u4f7f\u7528PyInstaller\u5c06\u8fd9\u4e2a\u811a\u672c\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\u3002\u6253\u5f00\u547d\u4ee4\u884c\u6216\u7ec8\u7aef\uff0c\u5e76\u5bfc\u822a\u5230\u5305\u542b<code>hello.py<\/code>\u7684\u76ee\u5f55\u3002\u7136\u540e\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pyinstaller --onefile hello.py<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u5728\u8fd9\u4e2a\u547d\u4ee4\u4e2d\uff0c<code>--onefile<\/code>\u9009\u9879\u544a\u8bc9PyInstaller\u5c06\u6240\u6709\u6587\u4ef6\u6253\u5305\u6210\u4e00\u4e2a\u5355\u72ec\u7684\u53ef\u6267\u884c\u6587\u4ef6\u3002PyInstaller\u4f1a\u521b\u5efa\u4e00\u4e2a\u540d\u4e3a<code>dist<\/code>\u7684\u76ee\u5f55\uff0c\u5176\u4e2d\u5305\u542b\u751f\u6210\u7684\u53ef\u6267\u884c\u6587\u4ef6\u3002<\/p>\n<\/p>\n<p><p>\u56db\u3001\u8fd0\u884c\u751f\u6210\u7684\u53ef\u6267\u884c\u6587\u4ef6<\/p>\n<\/p>\n<p><p>\u6253\u5305\u8fc7\u7a0b\u5b8c\u6210\u540e\uff0c\u4f60\u53ef\u4ee5\u5728<code>dist<\/code>\u76ee\u5f55\u4e2d\u627e\u5230\u751f\u6210\u7684\u53ef\u6267\u884c\u6587\u4ef6\u3002\u5bf9\u4e8e\u6211\u4eec\u7684\u793a\u4f8b\uff0c\u6587\u4ef6\u540d\u5c06\u662f<code>hello.exe<\/code>\uff08\u5728Windows\u4e0a\uff09\u6216<code>hello<\/code>\uff08\u5728macOS\u548cLinux\u4e0a\uff09\u3002\u4f60\u53ef\u4ee5\u76f4\u63a5\u8fd0\u884c\u8fd9\u4e2a\u6587\u4ef6\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">.\/dist\/hello<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u4f60\u5c06\u770b\u5230\u201cHello, world!\u201d\u7684\u8f93\u51fa\uff0c\u8fd9\u610f\u5473\u7740\u4f60\u7684\u53ef\u6267\u884c\u6587\u4ef6\u5df2\u7ecf\u6210\u529f\u8fd0\u884c\u3002<\/p>\n<\/p>\n<p><p>\u4e94\u3001\u4f7f\u7528PyInstaller\u7684\u5176\u4ed6\u9009\u9879<\/p>\n<\/p>\n<p><p>PyInstaller\u63d0\u4f9b\u4e86\u8bb8\u591a\u5176\u4ed6\u9009\u9879\uff0c\u4f7f\u4f60\u53ef\u4ee5\u5b9a\u5236\u6253\u5305\u8fc7\u7a0b\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u7528\u9009\u9879\uff1a<\/p>\n<\/p>\n<ol>\n<li><strong>\u6307\u5b9a\u56fe\u6807<\/strong>\uff1a\u4f60\u53ef\u4ee5\u4f7f\u7528<code>--icon<\/code>\u9009\u9879\u6765\u6307\u5b9a\u53ef\u6267\u884c\u6587\u4ef6\u7684\u56fe\u6807\u3002\u4f8b\u5982\uff1a<\/li>\n<\/ol>\n<p><pre><code class=\"language-bash\">pyinstaller --onefile --icon=myicon.ico hello.py<\/p>\n<p><\/code><\/pre>\n<\/p>\n<ol start=\"2\">\n<li><strong>\u9690\u85cf\u63a7\u5236\u53f0\u7a97\u53e3<\/strong>\uff1a\u5728Windows\u4e0a\uff0c\u4f60\u53ef\u4ee5\u4f7f\u7528<code>--noconsole<\/code>\u9009\u9879\u6765\u9690\u85cf\u63a7\u5236\u53f0\u7a97\u53e3\u3002\u4f8b\u5982\uff1a<\/li>\n<\/ol>\n<p><pre><code class=\"language-bash\">pyinstaller --onefile --noconsole hello.py<\/p>\n<p><\/code><\/pre>\n<\/p>\n<ol start=\"3\">\n<li><strong>\u6dfb\u52a0\u6570\u636e\u6587\u4ef6<\/strong>\uff1a\u4f60\u53ef\u4ee5\u4f7f\u7528<code>--add-data<\/code>\u9009\u9879\u6765\u5305\u542b\u989d\u5916\u7684\u6570\u636e\u6587\u4ef6\u3002\u4f8b\u5982\uff1a<\/li>\n<\/ol>\n<p><pre><code class=\"language-bash\">pyinstaller --onefile --add-data &quot;data.txt;.&quot; hello.py<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u516d\u3001\u89e3\u51b3\u5e38\u89c1\u95ee\u9898<\/p>\n<\/p>\n<p><p>\u5728\u4f7f\u7528PyInstaller\u65f6\uff0c\u4f60\u53ef\u80fd\u4f1a\u9047\u5230\u4e00\u4e9b\u95ee\u9898\u3002\u4ee5\u4e0b\u662f\u4e00\u4e9b\u5e38\u89c1\u95ee\u9898\u53ca\u5176\u89e3\u51b3\u65b9\u6cd5\uff1a<\/p>\n<\/p>\n<ol>\n<li>\n<p><strong>\u7f3a\u5c11\u6a21\u5757<\/strong>\uff1a\u5982\u679c\u5728\u8fd0\u884c\u53ef\u6267\u884c\u6587\u4ef6\u65f6\u9047\u5230\u201cModuleNotFoundError\u201d\uff0c\u8bf7\u786e\u4fdd\u6240\u6709\u4f9d\u8d56\u9879\u90fd\u5df2\u6b63\u786e\u5bfc\u5165\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528<code>--hidden-import<\/code>\u9009\u9879\u624b\u52a8\u6307\u5b9a\u9700\u8981\u5305\u542b\u7684\u6a21\u5757\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u6587\u4ef6\u8def\u5f84\u95ee\u9898<\/strong>\uff1a\u5728\u6253\u5305\u8fc7\u7a0b\u4e2d\uff0c\u6587\u4ef6\u8def\u5f84\u53ef\u80fd\u4f1a\u6539\u53d8\u3002\u4f60\u53ef\u4ee5\u4f7f\u7528<code>sys._MEIPASS<\/code>\u6765\u83b7\u53d6\u4e34\u65f6\u76ee\u5f55\u8def\u5f84\uff0c\u5e76\u786e\u4fdd\u4f60\u7684\u811a\u672c\u80fd\u591f\u6b63\u786e\u52a0\u8f7d\u8d44\u6e90\u6587\u4ef6\u3002<\/p>\n<\/p>\n<\/li>\n<li>\n<p><strong>\u517c\u5bb9\u6027\u95ee\u9898<\/strong>\uff1a\u4e0d\u540c\u5e73\u53f0\u4e4b\u95f4\u7684\u517c\u5bb9\u6027\u95ee\u9898\u53ef\u80fd\u4f1a\u5bfc\u81f4\u6253\u5305\u5931\u8d25\u3002\u786e\u4fdd\u4f7f\u7528\u4e0e\u76ee\u6807\u5e73\u53f0\u517c\u5bb9\u7684Python\u7248\u672c\u548c\u5e93\u3002<\/p>\n<\/p>\n<\/li>\n<\/ol>\n<p><p>\u4e03\u3001\u793a\u4f8b\uff1a\u6253\u5305\u5e26\u6709GUI\u7684Python\u5e94\u7528\u7a0b\u5e8f<\/p>\n<\/p>\n<p><p>\u4e3a\u4e86\u66f4\u597d\u5730\u7406\u89e3PyInstaller\u7684\u4f7f\u7528\uff0c\u6211\u4eec\u5c06\u5c55\u793a\u5982\u4f55\u6253\u5305\u4e00\u4e2a\u5e26\u6709GUI\u7684Python\u5e94\u7528\u7a0b\u5e8f\u3002\u4f8b\u5982\uff0c\u4f7f\u7528Tkinter\u521b\u5efa\u4e00\u4e2a\u7b80\u5355\u7684GUI\u5e94\u7528\u7a0b\u5e8f\uff0c\u5e76\u5c06\u5176\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\u3002<\/p>\n<\/p>\n<p><p>\u9996\u5148\uff0c\u7f16\u5199\u4e00\u4e2a\u540d\u4e3a<code>gui_app.py<\/code>\u7684\u811a\u672c\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-python\"># gui_app.py<\/p>\n<p>import tkinter as tk<\/p>\n<p>def on_button_click():<\/p>\n<p>    label.config(text=&quot;Hello, Tkinter!&quot;)<\/p>\n<p>app = tk.Tk()<\/p>\n<p>app.title(&quot;Simple GUI App&quot;)<\/p>\n<p>label = tk.Label(app, text=&quot;Click the button&quot;)<\/p>\n<p>label.pack()<\/p>\n<p>button = tk.Button(app, text=&quot;Click Me&quot;, command=on_button_click)<\/p>\n<p>button.pack()<\/p>\n<p>app.mainloop()<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd9\u4e2a\u811a\u672c\u521b\u5efa\u4e86\u4e00\u4e2a\u7b80\u5355\u7684Tkinter\u5e94\u7528\u7a0b\u5e8f\uff0c\u5176\u4e2d\u5305\u542b\u4e00\u4e2a\u6807\u7b7e\u548c\u4e00\u4e2a\u6309\u94ae\u3002\u5f53\u6309\u94ae\u88ab\u70b9\u51fb\u65f6\uff0c\u6807\u7b7e\u7684\u6587\u672c\u5c06\u88ab\u66f4\u6539\u3002<\/p>\n<\/p>\n<p><p>\u63a5\u4e0b\u6765\uff0c\u4f7f\u7528PyInstaller\u5c06\u8fd9\u4e2a\u811a\u672c\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\uff1a<\/p>\n<\/p>\n<p><pre><code class=\"language-bash\">pyinstaller --onefile --noconsole gui_app.py<\/p>\n<p><\/code><\/pre>\n<\/p>\n<p><p>\u8fd0\u884c\u751f\u6210\u7684\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u4f60\u5c06\u770b\u5230\u4e00\u4e2a\u5e26\u6709GUI\u7684\u5e94\u7528\u7a0b\u5e8f\u3002<\/p>\n<\/p>\n<p><p>\u516b\u3001\u4f7f\u7528cx_Freeze<\/p>\n<\/p>\n<p><p>\u9664\u4e86PyInstaller\uff0c\u4f60\u8fd8\u53ef\u4ee5\u4f7f\u7528cx_Freeze\u5c06Python\u811a\u672c\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\u3002\u4ee5\u4e0b\u662f\u4f7f\u7528cx_Freeze\u7684\u6b65\u9aa4\uff1a<\/p>\n<\/p>\n<ol>\n<li>\u5b89\u88c5cx_Freeze\uff1a<\/li>\n<\/ol>\n<p><pre><code class=\"language-bash\">pip install cx_Freeze<\/p>\n<p><\/code><\/pre>\n<\/p>\n<ol start=\"2\">\n<li>\u7f16\u5199\u4e00\u4e2a\u540d\u4e3a<code>setup.py<\/code>\u7684\u811a\u672c\uff1a<\/li>\n<\/ol>\n<p><pre><code class=\"language-python\"># setup.py<\/p>\n<p>from cx_Freeze import setup, Executable<\/p>\n<p>setup(<\/p>\n<p>    name=&quot;Simple GUI App&quot;,<\/p>\n<p>    version=&quot;1.0&quot;,<\/p>\n<p>    description=&quot;A simple GUI application&quot;,<\/p>\n<p>    executables=[Executable(&quot;gui_app.py&quot;, base=&quot;Win32GUI&quot;)]<\/p>\n<p>)<\/p>\n<p><\/code><\/pre>\n<\/p>\n<ol start=\"3\">\n<li>\u8fd0\u884c<code>setup.py<\/code>\u811a\u672c\uff1a<\/li>\n<\/ol>\n<p><pre><code class=\"language-bash\">python setup.py build<\/p>\n<p><\/code><\/pre>\n<\/p>\n<ol start=\"4\">\n<li>\u5728\u751f\u6210\u7684<code>build<\/code>\u76ee\u5f55\u4e2d\u627e\u5230\u53ef\u6267\u884c\u6587\u4ef6\u5e76\u8fd0\u884c\u3002<\/li>\n<\/ol>\n<p><p>\u4e5d\u3001\u603b\u7ed3<\/p>\n<\/p>\n<p><p>\u4f7f\u7528Python\u7f16\u5199\u53ef\u6267\u884c\u6587\u4ef6\u53ef\u4ee5\u4f7f\u4f60\u7684\u5e94\u7528\u7a0b\u5e8f\u66f4\u6613\u4e8e\u5206\u53d1\u548c\u8fd0\u884c\u3002\u901a\u8fc7\u4f7f\u7528\u5de5\u5177\u5982PyInstaller\u548ccx_Freeze\uff0c\u4f60\u53ef\u4ee5\u8f7b\u677e\u5730\u5c06Python\u811a\u672c\u8f6c\u6362\u4e3a\u72ec\u7acb\u7684\u53ef\u6267\u884c\u6587\u4ef6\u3002\u65e0\u8bba\u4f60\u662f\u521b\u5efa\u4e00\u4e2a\u7b80\u5355\u7684\u547d\u4ee4\u884c\u5de5\u5177\u8fd8\u662f\u4e00\u4e2a\u590d\u6742\u7684GUI\u5e94\u7528\u7a0b\u5e8f\uff0c\u8fd9\u4e9b\u5de5\u5177\u90fd\u80fd\u591f\u6ee1\u8db3\u4f60\u7684\u9700\u6c42\u3002<\/p>\n<\/p>\n<p><p>\u5e0c\u671b\u672c\u6587\u80fd\u5e2e\u52a9\u4f60\u66f4\u597d\u5730\u7406\u89e3\u5982\u4f55\u4f7f\u7528Python\u7f16\u5199\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u5e76\u5728\u4f60\u7684\u5f00\u53d1\u8fc7\u7a0b\u4e2d\u63d0\u4f9b\u4e00\u4e9b\u5b9e\u7528\u7684\u6307\u5bfc\u3002<\/p>\n<\/p>\n<h2><strong>\u76f8\u5173\u95ee\u7b54FAQs\uff1a<\/strong><\/h2>\n<p> <strong>\u5982\u4f55\u5c06Python\u811a\u672c\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\uff1f<\/strong><br \/>\u8981\u5c06Python\u811a\u672c\u8f6c\u6362\u4e3a\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u53ef\u4ee5\u4f7f\u7528\u5de5\u5177\u5982PyInstaller\u3001cx_Freeze\u6216py2exe\u3002\u8fd9\u4e9b\u5de5\u5177\u80fd\u591f\u5c06Python\u4ee3\u7801\u6253\u5305\u6210\u72ec\u7acb\u7684\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u4f7f\u5176\u53ef\u4ee5\u5728\u6ca1\u6709Python\u73af\u5883\u7684\u8ba1\u7b97\u673a\u4e0a\u8fd0\u884c\u3002\u4f7f\u7528PyInstaller\u7684\u57fa\u672c\u6b65\u9aa4\u5305\u62ec\u5b89\u88c5PyInstaller\uff0c\u901a\u8fc7\u547d\u4ee4\u884c\u8fd0\u884c<code>pyinstaller your_script.py<\/code>\uff0c\u5e76\u5728\u751f\u6210\u7684<code>dist<\/code>\u6587\u4ef6\u5939\u4e2d\u627e\u5230\u53ef\u6267\u884c\u6587\u4ef6\u3002<\/p>\n<p><strong>\u5728\u521b\u5efa\u53ef\u6267\u884c\u6587\u4ef6\u65f6\u9700\u8981\u6ce8\u610f\u54ea\u4e9b\u4f9d\u8d56\u5173\u7cfb\uff1f<\/strong><br \/>\u5728\u6253\u5305Python\u811a\u672c\u65f6\uff0c\u786e\u4fdd\u6240\u6709\u4f9d\u8d56\u5e93\u90fd\u88ab\u6b63\u786e\u5305\u542b\u5728\u5185\u975e\u5e38\u91cd\u8981\u3002PyInstaller\u4f1a\u81ea\u52a8\u68c0\u6d4b\u5927\u90e8\u5206\u4f9d\u8d56\uff0c\u4f46\u5728\u67d0\u4e9b\u60c5\u51b5\u4e0b\uff0c\u53ef\u80fd\u9700\u8981\u624b\u52a8\u6307\u5b9a\u67d0\u4e9b\u6a21\u5757\u6216\u6570\u636e\u6587\u4ef6\u3002\u67e5\u770b\u751f\u6210\u7684spec\u6587\u4ef6\uff0c\u786e\u8ba4\u6240\u6709\u5fc5\u8981\u7684\u5e93\u548c\u8d44\u6e90\u662f\u5426\u5df2\u88ab\u5217\u51fa\uff0c\u4ee5\u786e\u4fdd\u53ef\u6267\u884c\u6587\u4ef6\u7684\u6b63\u5e38\u8fd0\u884c\u3002<\/p>\n<p><strong>\u53ef\u6267\u884c\u6587\u4ef6\u5728\u4e0d\u540c\u64cd\u4f5c\u7cfb\u7edf\u4e0a\u662f\u5426\u517c\u5bb9\uff1f<\/strong><br \/>\u53ef\u6267\u884c\u6587\u4ef6\u901a\u5e38\u662f\u7279\u5b9a\u4e8e\u64cd\u4f5c\u7cfb\u7edf\u7684\u3002\u4f7f\u7528PyInstaller\u5728Windows\u4e0a\u6253\u5305\u7684\u53ef\u6267\u884c\u6587\u4ef6\u4e0d\u80fd\u76f4\u63a5\u5728Linux\u6216macOS\u4e0a\u8fd0\u884c\uff0c\u53cd\u4e4b\u4ea6\u7136\u3002\u5982\u679c\u9700\u8981\u5728\u591a\u4e2a\u64cd\u4f5c\u7cfb\u7edf\u4e0a\u4f7f\u7528\u76f8\u540c\u7684Python\u811a\u672c\uff0c\u5efa\u8bae\u5728\u6bcf\u4e2a\u76ee\u6807\u64cd\u4f5c\u7cfb\u7edf\u4e0a\u5206\u522b\u521b\u5efa\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u786e\u4fdd\u5b83\u4eec\u80fd\u591f\u9002\u5e94\u4e0d\u540c\u73af\u5883\u7684\u7279\u6027\u548c\u8981\u6c42\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"\u8981\u4f7f\u7528Python\u7f16\u5199\u53ef\u6267\u884c\u6587\u4ef6\uff0c\u4f60\u53ef\u4ee5\u4f7f\u7528\u4e00\u4e9b\u5de5\u5177\u548c\u5e93\uff0c\u5982PyInstaller\u3001cx_Freeze\u3001py2 [&hellip;]","protected":false},"author":3,"featured_media":1119086,"comment_status":"closed","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[37],"tags":[],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1119075"}],"collection":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/users\/3"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/comments?post=1119075"}],"version-history":[{"count":"1","href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1119075\/revisions"}],"predecessor-version":[{"id":1119091,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/posts\/1119075\/revisions\/1119091"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media\/1119086"}],"wp:attachment":[{"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/media?parent=1119075"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/categories?post=1119075"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/docs.pingcode.com\/wp-json\/wp\/v2\/tags?post=1119075"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}