In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Internet Technology >
Share
Shulou(Shulou.com)05/31 Report--
This article mainly introduces "how to package py files in Python3.6 to generate exe" related knowledge, editor through the actual case to show you the process of operation, the method of operation is simple and fast, practical, I hope that this "how to package py files in Python3.6 to generate exe" article can help you solve the problem.
Main points:
1. Python version 32-bit (file name is python-3.6.1.exe)
two。 Install all the modules used (the original blog uses openpyxl, but I use request\ config\ data in urllib)
3. Download replacement pyinstaller (download pyinstaller-develop.zip and copy the Pyinstaller folder)
4. Generate exe in the console
The operation process is recorded as follows:
C:\ Python\ Scripts > pip install requestC:\ Python\ Scripts > pip install configC:\ Python\ Scripts > pip install dataC:\ Python\ Scripts > pyinstaller.exe-F structs2.py
Generate successful interface content:
24957 INFO: checking EXE
24957 INFO: Building EXE because out00-EXE.toc is non existent
24957 INFO: Building EXE from out00-EXE.toc
24958 INFO: Appending archive to EXE C:\ Python\ Scripts\ dist\ structs2.exe
24975 INFO: Building EXE from out00-EXE.toc completed successfully.
After many previous failures, the reasons for the failure of Python 3 to exe are summarized:
1. Python development environment version and environment variables are inconsistent. Wrong installation before (python-3.6.2rc1.exe)
two。 Pay attention to the version. Several versions have been tried before, and finally all of them are removed and reinstalled successfully.
3. The Python package needs to be fully installed. I didn't install the request\ config package before, which may be one of the reasons for the failure.
There have been failures, the contents are as follows:
Usage: setup.exe [global_opts] cmd1 [cmd1_opts] [cmd2 [cmd2_opts]...] or: setup.exe-help [cmd1 cmd2...] or: setup.exe-help-commandsor: setup.exe cmd-help
The solution is to re-clean the installation development environment. Finally succeeded.
This is the end of the introduction on "how to package py files in Python3.6 to generate exe". Thank you for your reading. If you want to know more about the industry, you can follow the industry information channel. The editor will update different knowledge points for you every day.
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.