如何在Python項目中使用包?針對這個問題,這篇文章詳細(xì)介紹了相對應(yīng)的分析和解答,希望可以幫助更多想解決這個問題的小伙伴找到更簡單易行的方法。

Python中一些包的基本用處和安裝方法
pika可以用來連接RabbitMQ
pip install pika -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
requests是HTTP庫
Request支持HTTP連接保持和連接池,支持使用cookie保持會話,支持文件上傳,支持自動響應(yīng)內(nèi)容的編碼,支持國際化的URL和POST數(shù)據(jù)自動編碼。
pip install requests -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
SQLAlchemy是ORM框架
pip install SQLAlchemy -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
pymongo是連接mongodb的庫
pip install pymongo -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
MySQL-python是連接mysql的庫
apt-get install python-mysqldb
gearman分布式任務(wù)系統(tǒng)
pip install gearman -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
lxml是python的一個解析庫,支持HTML和XML的解析
pip install lxml -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
elasticsearch庫,es的客戶端庫
pip install elasticsearch -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
pycurl是curl庫
pip install pycurl -i http://pypi.douban.com/simple/ --trusted-host pypi.douban.com
報錯
__main__.ConfigurationError: Could not run curl-config: [Errno 2] No such file or directory
apt-get install libcurl4-openssl-dev
關(guān)于如何在Python項目中使用包問題的解答就分享到這里了,希望以上內(nèi)容可以對大家有一定的幫助,如果你還有很多疑惑沒有解開,可以關(guān)注創(chuàng)新互聯(lián)行業(yè)資訊頻道了解更多相關(guān)知識。
網(wǎng)站欄目:如何在Python項目中使用包-創(chuàng)新互聯(lián)
文章鏈接:http://chinadenli.net/article10/cohhgo.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供云服務(wù)器、網(wǎng)頁設(shè)計公司、標(biāo)簽優(yōu)化、外貿(mào)網(wǎng)站建設(shè)、軟件開發(fā)、App設(shè)計
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)
猜你還喜歡下面的內(nèi)容