Title: Python 零基础入门(6/6):TCP/UDP 网络编程与打包 | wistbean | wistbean
Open Graph Title: Python 零基础入门(6/6):TCP/UDP 网络编程与打包
X Title: Python 零基础入门(6/6):TCP/UDP 网络编程与打包
Description: 通过可运行示例掌握 Python Socket TCP/UDP 编程,理解客户端与服务端通信,并学会用 PyInstaller 打包 exe。
Open Graph Description: 通过可运行示例掌握 Python Socket TCP/UDP 编程,理解客户端与服务端通信,并学会用 PyInstaller 打包 exe。
X Description: 通过可运行示例掌握 Python Socket TCP/UDP 编程,理解客户端与服务端通信,并学会用 PyInstaller 打包 exe。
Keywords:
Mail addresses
wistbean.bb@gmail.com
Opengraph URL: https://wistbean.github.io/python-network-programming.html
Generator: Hexo 3.9.0
Domain: wistbean.github.io
{
"@context": "https://schema.org",
"@type": "BlogPosting",
"headline": "Python 零基础入门(6/6):TCP/UDP 网络编程与打包",
"description": "通过可运行示例掌握 Python Socket TCP/UDP 编程,理解客户端与服务端通信,并学会用 PyInstaller 打包 exe。",
"author": {
"@type": "Person",
"name": "wistbean"
},
"publisher": {
"@type": "Organization",
"name": "wistbean"
},
"datePublished": "2026-03-26T11:25:00+08:00",
"dateModified": "2026-03-26T12:00:00+08:00",
"mainEntityOfPage": "https://wistbean.org/python-network-programming.html",
"inLanguage": "zh-CN"
}
{
"@context": "https://schema.org",
"@type": "FAQPage",
"mainEntity": [
{
"@type": "Question",
"name": "TCP 和 UDP 在入门阶段怎么选?",
"acceptedAnswer": {
"@type": "Answer",
"text": "要求可靠传输(顺序、重传)选 TCP;追求低延迟且可容忍丢包时选 UDP。"
}
},
{
"@type": "Question",
"name": "本地 socket 示例连不上通常是什么原因?",
"acceptedAnswer": {
"@type": "Answer",
"text": "常见是端口被占用、服务端未先启动、地址写错(127.0.0.1 与局域网 IP 混用)。"
}
},
{
"@type": "Question",
"name": "PyInstaller 打包后运行闪退怎么排查?",
"acceptedAnswer": {
"@type": "Answer",
"text": "先在命令行启动 exe 看报错,再检查资源路径与第三方依赖是否被正确打包。"
}
}
]
}
| google-site-verification | bcJVGqEGcBIay29szBsswzqYxY3qUzWuvu1hfad3-08 |
| theme-color | #B5963F |
| og:type | article |
| og:site_name | wistbean |
| og:locale | zh-CN |
| og:updated_time | 2026-03-26T02:30:00.000Z |
| twitter:card | summary |
Links:
Viewport: width=device-width, initial-scale=1, maximum-scale=1