[英]Cloning github repositories and importing them to a file throws an decoding error
[英]Importing github repositories on travis
我正在嘗試在travis構建中導入github存儲庫。 我是通過打電話來做的
install:
- pip install -r requirements.txt
在.travis.yml
。 我的需求文件如下所示:
git+ssh://git@github.com/my_account/repository_test.git@development
git+ssh://git@github.com/my_account/repository_test_ii.git@development
這似乎行得通,因為當我將pip freeze
調用時,兩個存儲庫都被列出。 但是,當我這樣做時:
import repository_test
import repository_test_ii
第二次導入失敗。 兩個github倉庫都有一個正確的setup.py文件,我可以在本地安裝所有文件而不會出現任何問題。 我用盡了一些東西來檢查。
我認為問題可能在於我的github存儲庫,我懷疑該模塊可能是以略微不同的名稱導入的。 我怎么檢查這個? 我還能檢查什么?
問題是我在我的github存儲庫中缺少__init__.py文件,因此無法導入它。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.