-
Notifications
You must be signed in to change notification settings - Fork 20
/
python-2-or-3.html
193 lines (193 loc) · 27.6 KB
/
python-2-or-3.html
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta name="author" content="Matt Makai">
<meta name="description" content="学习关于你到底应该用 Python 2 还是 Python 3 来编写应用的知识。">
<title>Python 2 还是 3? - Full Stack Python</title>
<link href="/f.css" rel="stylesheet">
<link rel="shortcut icon" href="/img/fsp-fav.png">
</head>
<body>
<div style="margin: 0 0 12px;background-color: #22B24C;">
<div class="container">
<p class="banner sans-font">
<a href="https://training.talkpython.fm/courses/explore_entrepreneurs/python-for-entrepreneurs-build-and-launch-your-online-business" style="color: #fff">创业家的 Python: 边创造你自己的生意边学 Python</a>!
</p>
</div>
</div>
<div class="container">
<div class="row">
<div class="col-md-12">
<div class="logo-header-section">
<a href="/" style="text-decoration: none; border: none;"><img src="/img/logo-sm.png" class="logo-image" alt="Full Stack Python logo"></a>
<span class="logo-title"><a href="https://www.fullstackpython.com/">Full Stack Python</a></span>
</div>
<div class="sans-font">
<!--<a href="/blog.html" class="submenu-item-first">Blog</a> |
<a href="/books.html" class="submenu-item">Books</a> | -->
<a href="/table-of-contents.html">全部主题</a>
<span style="margin:0 12px 0 12px">|</span>
<a href="/blog.html">Blog</a>
<span style="margin:0 12px 0 12px">|</span>
<a href="/email.html">时讯</a>
<span style="margin:0 12px 0 12px">|</span>
<a href="https://twitter.com/fullstackpython">@fullstackpython</a>
<span style="margin:0 12px 0 12px">|</span>
<a href="https://www.facebook.com/fullstackpython">Facebook</a>
<span style="margin:0 12px 0 12px">|</span>
<a href="https://github.com/mattmakai/fullstackpython.com">源码</a>
</div> </div>
</div><div class="row">
<div class="col-md-8">
<h1>Python 2 还是 3?</h1>
<p>Python 编程语言目前正处在从版本 2 升级到版本 3 的漫长过渡期中。初学者通常会有到底该学哪个版本的问题。Python 3 最初是在 2008 年发布的,但目前仍不是作为默认版本安装在很多操作系统上,听到这些很令人困惑。</p>
<p>告诉你个好消息: 无论你从哪个版本开始学起都不会有问题的。尽管这两个版本在 unicode 处理和语法上有些许不同,但对于其它大部分来说,你先学的 Python 2 然后再学 Python 3 不会又要从头学起。</p>
<p>我个人推荐初学者现在应该从 Python 3 开始学起。因为现在已经能找到足够多的 <a href="/best-python-resources.html">资料</a> 来指导我们从零基础开始学习 Python 3。</p>
<p>但是,如果你对 <a href="http://baike.baidu.com/view/5705743.htm">DevOps</a> 型工作感兴趣,并且使用像 Ansible 或 Fabric 等 <a href="/configuration-management.html">配置管理工具</a>,那么你还是应该用 Python 2,因为这些工具还不支持 Python 3。如果你知道项目中必须要用到某些库,先在 <a href="https://python3wos.appspot.com/">Python 超能墙</a> 网站上查下兼容性。如果你用 Django 的话,也有个类似的网站叫 <a href="http://djangowos.com/">常用 Django 包的 Python 3 兼容性</a>。</p>
<h3>从 Python 2 转到 3 的相关资源</h3>
<ul>
<li>
<p>想知道 Python 3 与 Python 2 相比都有什么改动以及 Python 3 的所有优势吗?你需要看下 <a href="https://docs.python.org/3/whatsnew/index.html">Python 3 修改情况的官方文档</a>。</p>
</li>
<li>
<p>在官方的 <a href="https://wiki.python.org/moin/PortingToPy3k/">将代码移植到 Python 3</a>页面上列出了如何移植 Python 代码及底层的 C 代码等相关资源链接。 还有一个网站叫 <a href="https://wiki.python.org/moin/PortingToPy3k/BilingualQuickRef">编写与 Python 2 和 3 兼容的代码之快速参考</a>。</p>
</li>
<li>
<p><a href="https://hynek.me/articles/python3-2016/">2016 年的 Python 3</a> 上陈述了现在很多 Python 开发新手只使用 Python 3, 如果这个队伍继续壮大,将会对以后 Python 3 的采用产生特别大的影响。</p>
</li>
<li>
<p><a href="https://blogs.msdn.microsoft.com/pythonengineering/2016/03/08/python-3-is-winning/">Python 3 是赢家</a> 上的数据和图表来自 PyPI,可以看出如果以当前速度发展,到 2016 年中期,支持 Python 3的库总量将超过 支持 Python 2 的库。</p>
</li>
<li>
<p><a href="http://www.snarky.ca/the-stages-of-the-python-3-transition">Python 3 过渡期的各阶段</a> 从一个 Python 核心开发人员的角度,阐述了截止 2015 年底 Python 2 怎样过渡到 Python 3 的过程。</p>
</li>
<li>
<p><a href="http://nothingbutsnark.svbtle.com/porting-to-python-3-is-like-eating-your-vegetables">移植到 Python 3 就像要求你吃完蔬菜</a>, 阐述了 Python 3 有些特性值得我们将代码移植过去,同时还提供了一些怎样移植更省力的小建议。</p>
</li>
<li>
<p><a href="http://ptgmedia.pearsoncmg.com/imprint_downloads/informit/promotions/python/python2python3.pdf">从 Python 2 移植到 Python 3</a> 是一份如何移植 Python 代码的 PDF 小抄。</p>
</li>
<li>
<p><a href="https://godjango.com/96-django-and-python-3-how-to-setup-pyenv-for-multiple-pythons/">Django 和 Python 3 如何设置 pyenv 来支持多个 Python 版本</a>, 是一部讲述如何用 pyenv 来实现同时运行 Python 2 和 3,以支持不同的项目。</p>
</li>
<li>
<p><a href="http://blog.scrapinghub.com/2015/08/19/scrapy-on-the-road-to-python-3-support/">Scrapy 的 Python 3 支持之路</a>,以一个广为使用的 Python 项目的角度阐述了它的 Python 3 支持计划,以及为何实施起来花了这么长时间的原因。</p>
</li>
<li>
<p><a href="http://py3readiness.org/">Python 3 准备就绪</a> 是一个有关 360 个最受欢迎的 Python 库(基于下载量)是否已支持 Python 3 的可视化页面。</p>
</li>
<li>
<p>所有主要的科研型 Python 类库都承诺不晚于 2020 年,即当 Python 2 维护期结束时,<a href="https://python3statement.github.io/">放弃支持 Python 2</a>。该承诺通过公开声明它们的意图来大力鼓励对 Python 3 的采纳。</p>
</li>
</ul>
<h3>现已知道了 Python 的版本知识,那接下来想了解什么?</h3>
<div class="row">
<div class="col-md-4">
<div class="well select-next">
<a href="/development-environments.html" class="btn btn-success btn-full"><svg width="34" height="30" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1728 992v-832q0-13-9.5-22.5t-22.5-9.5h-1600q-13 0-22.5 9.5t-9.5 22.5v832q0 13 9.5 22.5t22.5 9.5h1600q13 0 22.5-9.5t9.5-22.5zm128-832v1088q0 66-47 113t-113 47h-544q0 37 16 77.5t32 71 16 43.5q0 26-19 45t-45 19h-512q-26 0-45-19t-19-45q0-14 16-44t32-70 16-78h-544q-66 0-113-47t-47-113v-1088q0-66 47-113t113-47h1600q66 0 113 47t47 113z" fill="#fff"/></svg></a>
<p class="under-btn">编写 Python 应用应该用什么编辑器?</p> </div>
</div>
<div class="col-md-4">
<div class="well select-next">
<a href="/web-frameworks.html" class="btn btn-success btn-full"><svg width="28" height="30" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M553 1399l-50 50q-10 10-23 10t-23-10l-466-466q-10-10-10-23t10-23l466-466q10-10 23-10t23 10l50 50q10 10 10 23t-10 23l-393 393 393 393q10 10 10 23t-10 23zm591-1067l-373 1291q-4 13-15.5 19.5t-23.5 2.5l-62-17q-13-4-19.5-15.5t-2.5-24.5l373-1291q4-13 15.5-19.5t23.5-2.5l62 17q13 4 19.5 15.5t2.5 24.5zm657 651l-466 466q-10 10-23 10t-23-10l-50-50q-10-10-10-23t10-23l393-393-393-393q-10-10-10-23t10-23l50-50q10-10 23-10t23 10l466 466q10 10 10 23t-10 23z" fill="#fff"/></svg></a>
<p class="under-btn">我想学习如何用框架创建 Python Web 应用。</p> </div>
</div>
<div class="col-md-4">
<div class="well select-next">
<a href="/best-python-resources.html" class="btn btn-success btn-full"><svg width="28" height="30" viewBox="0 0 1792 1792" xmlns="http://www.w3.org/2000/svg"><path d="M1703 478q40 57 18 129l-275 906q-19 64-76.5 107.5t-122.5 43.5h-923q-77 0-148.5-53.5t-99.5-131.5q-24-67-2-127 0-4 3-27t4-37q1-8-3-21.5t-3-19.5q2-11 8-21t16.5-23.5 16.5-23.5q23-38 45-91.5t30-91.5q3-10 .5-30t-.5-28q3-11 17-28t17-23q21-36 42-92t25-90q1-9-2.5-32t.5-28q4-13 22-30.5t22-22.5q19-26 42.5-84.5t27.5-96.5q1-8-3-25.5t-2-26.5q2-8 9-18t18-23 17-21q8-12 16.5-30.5t15-35 16-36 19.5-32 26.5-23.5 36-11.5 47.5 5.5l-1 3q38-9 51-9h761q74 0 114 56t18 130l-274 906q-36 119-71.5 153.5t-128.5 34.5h-869q-27 0-38 15-11 16-1 43 24 70 144 70h923q29 0 56-15.5t35-41.5l300-987q7-22 5-57 38 15 59 43zm-1064 2q-4 13 2 22.5t20 9.5h608q13 0 25.5-9.5t16.5-22.5l21-64q4-13-2-22.5t-20-9.5h-608q-13 0-25.5 9.5t-16.5 22.5zm-83 256q-4 13 2 22.5t20 9.5h608q13 0 25.5-9.5t16.5-22.5l21-64q4-13-2-22.5t-20-9.5h-608q-13 0-25.5 9.5t-16.5 22.5z" fill="#fff"/></svg></a>
<p class="under-btn">给我一份最佳 Python 学习资料吧。</p> </div>
</div>
</div><div id="mc_embed_signup">
<form action="//mattmakai.us2.list-manage.com/subscribe/post?u=b7e774f0c4f05dcebbfee183d&id=b22335388d" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
<h4>在这里注册以便每月能收到一份邮件资料,内容包含本站的主要更新、教程和 Python 书籍的打折码等。</h4>
<div class="row">
<div class="col-md-9">
<input type="email" value="" name="EMAIL" class="email form-control" id="mce-EMAIL" placeholder="邮箱地址" required>
<div style="position: absolute; left: -5000px;"><input type="text" name="b_b7e774f0c4f05dcebbfee183d_b22335388d" tabindex="-1" value=""></div>
</div>
<div class="col-md-3">
<div class="clear"><input type="submit" value="订阅" name="subscribe" id="mc-embedded-subscribe" class="btn btn-success" style="font-family: 'Helvetica Neue';"></div>
</div>
</div>
</div>
</form>
</div>
</div>
<div class="col-md-offset-1 col-md-3" id="sidebar">
<div class="panel panel-success">
<div class="panel-body">
<a href="http://www.deploypython.com/"><img src="/img/sponsored/fsp-deployment-guide.png" alt="The Full Stack Python Guide to Deployments" width="100%"></a>
<p style="font-size: .8em; margin-top: 10px;">想找到一个完整的,一步一步的部署方案吗?请看<a href="http://www.deploypython.com/">《The Full Stack Python Guide to Deployments》</a>.
</p>
</div>
</div><div class="panel panel-success">
<div class="panel-heading">
<h3 class="panel-head">邮件获取更新</h3>
</div>
<div class="panel-body">
<div id="mc_embed_signup">
<form action="//mattmakai.us2.list-manage.com/subscribe/post?u=b7e774f0c4f05dcebbfee183d&id=b22335388d" method="post" id="mc-embedded-subscribe-form" name="mc-embedded-subscribe-form" class="validate" target="_blank" novalidate>
<div id="mc_embed_signup_scroll">
<h5>注册以便每月能收到一份邮件资料,内容包含本站的主要更新和 Python 教程。</h5>
<input type="email" value="" name="EMAIL" class="email form-control" id="mce-EMAIL" placeholder="邮箱地址" required>
<div style="position: absolute; left: -5000px;"><input type="text" name="b_b7e774f0c4f05dcebbfee183d_b22335388d" tabindex="-1" value=""></div>
<input type="submit" value="订阅" name="subscribe" id="mc-embedded-subscribe" class="btn btn-success" style="font-family: 'Helvetica Neue'; margin-top: 5px;">
</div>
</form>
</div>
</div>
</div><div class="panel" id="full-toc">
<div class="panel-heading">
<h3 class="panel-head"><a href="/table-of-contents.html" style="color: #fff;">目录</a></h3>
</div>
<div class="list-group">
<a href="/introduction.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>1. 简介</a><a href="/learning-programming.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>学习编程</a><a href="/why-use-python.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>为什么用 Python?</a><a href="/python-2-or-3.html" class="list-group-item smaller-item active" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Python 2 还是 3?</a><a href="/enterprise-python.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>企业 Python</a><a href="/python-community.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Python Community</a><a href="/best-python-podcasts.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Best Python Podcasts</a><a href="/best-python-resources.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>最佳 Python 资源</a><a href="/best-python-videos.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>最佳 Python 视频</a><a href="/development-environments.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>2. 开发环境</a><a href="/vim.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Vim</a><a href="/emacs.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Emacs</a><a href="/python-programming-language.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>3. 核心语言</a><a href="/generators.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>生成器</a><a href="/comprehensions.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>推导式</a><a href="/web-development.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>4. Web 开发</a><a href="/web-frameworks.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Web 框架</a><a href="/django.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Django</a><a href="/flask.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Flask</a><a href="/bottle.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Bottle</a><a href="/pyramid.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Pyramid</a><a href="/morepath.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Morepath</a><a href="/other-web-frameworks.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>其它 Web 框架</a><a href="/web-design.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Web 设计</a><a href="/cascading-style-sheets.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>级联样式表 (CSS)</a><a href="/javascript.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>JavaScript</a><a href="/websockets.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>WebSockets</a><a href="/template-engines.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>模板引擎</a><a href="/web-application-security.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Web 应用安全</a><a href="/static-site-generator.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>静态网站生成器</a><a href="/jinja2.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Jinja2</a><a href="/data.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>5. 数据</a><a href="/databases.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>关系型数据库</a><a href="/no-sql-datastore.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>NoSQL 数据存储</a><a href="/object-relational-mappers-orms.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>对象关系映射器</a><a href="/postgresql.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>PostgreSQL</a><a href="/mysql.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>MySQL</a><a href="/sqlite.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>SQLite</a><a href="/application-programming-interfaces.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>6. Web APIs</a><a href="/api-integration.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>API 集成</a><a href="/api-creation.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>API 的创建</a><a href="/twilio.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Twilio</a><a href="/deployment.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>7. 部署</a><a href="/servers.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>服务器</a><a href="/platform-as-a-service.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>平台即服务(PaaS)</a><a href="/operating-systems.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>操作系统</a><a href="/web-servers.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Web 服务器</a><a href="/wsgi-servers.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>WSGI 服务器</a><a href="/source-control.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>源码控制</a><a href="/application-dependencies.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>应用程序依赖</a><a href="/static-content.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>静态内容</a><a href="/task-queues.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>任务队列</a><a href="/configuration-management.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>配置管理</a><a href="/continuous-integration.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>持续集成</a><a href="/logging.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>日志</a><a href="/monitoring.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>监控</a><a href="/web-analytics.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Web 分析</a><a href="/docker.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Docker</a><a href="/caching.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>缓存</a><a href="/microservices.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>微服务</a><a href="/devops.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>DevOps</a><a href="/nginx.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Nginx</a><a href="/apache-http-server.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Apache HTTP 服务器</a><a href="/caddy.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Caddy</a><a href="/green-unicorn-gunicorn.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Green Unicorn (Gunicorn)</a><a href="/ubuntu.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Ubuntu</a><a href="/pelican.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Pelican</a><a href="/lektor.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Lektor</a><a href="/mkdocs.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>MkDocs</a><a href="/testing.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>8. 测试</a><a href="/unit-testing.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>单元测试</a><a href="/integration-testing.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>集成测试</a><a href="/code-metrics.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>代码度量</a><a href="/debugging.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>调试</a><a href="/what-full-stack-means.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif;'>9. Meta</a><a href="/bots.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Bots</a><a href="/change-log.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Change Log</a><a href="/future-directions.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Future Directions</a><a href="/about-author.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>About the Author</a><a href="/sqlalchemy.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>SQLAlchemy</a><a href="/peewee.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",sans-serif; padding-left:27px'>Peewee</a> <a href="/table-of-contents.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",san-serif;background-color:#22B24C; color: #fff;'>...或者<span style="border-bottom: 1px dotted;">显示全部目录内容</span>.</a>
</div>
</div> <div class="panel">
<div class="panel-heading"><h3 class="panel-head">Python 2 还是 3?</h3></div>
<div class="panel-body">
重要的更新内容会通过 Twitter 账号<a href="https://twitter.com/fullstackpython">@fullstackpython</a>发布。
<hr/>
需要更加详细的教程吗?请看
<a href="http://www.deploypython.com/">《The Full Stack Python Guide to Deployments》。</a>
</div>
</div>
<div class="panel" id="mobile-toc">
<div class="panel-heading">
<h3 class="panel-head"><a href="/table-of-contents.html" style="color: #fff;">Chapters</a></h3>
</div>
<div class="list-group">
<a href="/introduction.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>1. 简介</a> <a href="/python-2-or-3.html" class="list-group-item smaller-item active" style='font-family: "Helvetica Neue",sans-serif;'>» Python 2 还是 3?</a>
<a href="/development-environments.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>2. 开发环境</a><a href="/python-programming-language.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>3. 核心语言</a><a href="/web-development.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>4. Web 开发</a><a href="/data.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>5. 数据</a><a href="/application-programming-interfaces.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>6. Web APIs</a><a href="/deployment.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>7. 部署</a><a href="/testing.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>8. 测试</a><a href="/what-full-stack-means.html" class="list-group-item smaller-item " style='font-family: "Helvetica Neue",sans-serif;'>9. Meta</a> <a href="/table-of-contents.html" class="list-group-item smaller-item" style='font-family: "Helvetica Neue",san-serif;background-color:#22B24C; color: #fff;'>...or <span style="border-bottom: 1px dotted;">view the full table of contents</span>.</a>
</div>
</div></div></div>
<hr/>
</div>
<div class="container">
<div class="footer pull-right">
This site is based on <a href="https://github.com/mattmakai">Matt Makai</a>'s project <a href="https://github.com/mattmakai/fullstackpython.com">Full Stack Python</a>, thanks for his excellent work!
</div>
</div>
<div class="container">
<div class="footer pull-right" style="text-align:right; font-size:85%;">
<p>此网站由 <a href="https://github.com/haiiiiiyun">@haiiiiiyun</a> 和 <a href="https://github.com/haiiiiiyun/fullstackpython.cn/graphs/contributors">开源爱好者们</a> 共同维护。
若发现错误或想贡献,请访问: <a href="https://github.com/haiiiiiyun/fullstackpython.cn/">Github fullstackpython.cn 项目</a>
</p>
</div>
</div><script>
(function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
(i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
})(window,document,'script','//www.google-analytics.com/analytics.js','ga');
ga('create', 'UA-77551377-2', 'auto');
ga('send', 'pageview');
</script><script type='text/javascript'>
var trackOutboundLink = function(url) { ga('send', 'event', 'outbound', 'click', url, {'hitCallback': function () { document.location = url; } }); }
</script>
</body>
</html>