Python 打包exe

打包带走

安装pyinstaller

管理员启动cmd:pip install pyinstaller

卸载:pip uninstall pyinstaller

验证安装:pyinstaller --version

打包exe

进入py文件对应的目录:pyinstaller xxx.py

错误处理

UnicodeDecodeError: 'utf-8' codec can't decode byte

在最开头添加如下声明即可

csharp 复制代码
# -*- coding: latin1 -*-
相关推荐
Ivanqhz7 小时前
MoE + LLM 应用
数据库·人工智能·pytorch·python·深度学习·算法·1024程序员节
Mr. zhihao7 小时前
Deep Agent 架构深度解析:主Agent与子Agent完整交互机制与核心参数作用
python·ai·langgraph·deepagent
狗凯之家源码网7 小时前
iOS C2 V2 与 Python FastAPI 全链路远控系统深度评测
python·ios·fastapi
超级架构师7 小时前
让 Fortran 模型自己调用 Agent:原生 Fortran 2008 实现深度剖析
人工智能·python·架构·机器人·开源·fortran
小蒜学长7 小时前
基于Django+Vue喵汪联盟宠物领养系统的设计与实现(代码+数据库+LW)
后端·python·django·宠物领养系统·流程规范化
云边有个稻草人8 小时前
Prometheus Pushgateway教程:离线任务指标上报、Shell与Python示例、远程访问
开发语言·python·prometheus
fanruitian8 小时前
pycharm 使用anaconda
ide·python·pycharm
Dwzun8 小时前
基于SpringBoot3+Vue3的油莎豆种植管理系统
java·前端·vue.js·spring boot·后端·python·计算机网络
代码山河16 小时前
Python就业方向全解析:后端、爬虫、数据分析、AI你选哪个?
python·学习·架构·教程·面向对象·项目
在世修行16 小时前
智学文枢:题目流水线
python·多线程·状态机·pyside