kivy / kivy/python-for-android
Enhancement request: recipe regression and cache
- Ngôn ngữ chính
- Python
- Star
- 8.9k
- Fork
- 2k
- Merge trung bình
- 12 giờ 20 phút
- Pull request đã merge (30 ngày)
- 9
Mô tả
### Description
Add regression testing for recipes (I'm guessing this does not currently happen!).
And there is an *almost* (!) free lunch, faster builds for most users using the cached build result:
1) Save the regression results of each recipe in a recipe cache on a server. The cache is indexed by 'p4a release version', 'android.api' , 'recipe name and version', and 'architecture'. Android.api might be the two versions supported by the Store, recipe versions would be default. The cumulative effect of pre-built recipes means the build is computationally inexpensive (one pass is a few hours on my 3 year old NUC).
2) If 'cache is enabled' (see next item) and cache file exists, p4a downloads the built version from the cache instead of building from the recipe.
3) 'cache is enabled' is defined by Buildozer, default true for each requirement with a recipe. This option is false if any of the `p4a.xxx` are not default, or any of `android.min_api` `android.ndk` `android.ndk_api` or `android.ndk` are not default. 'Cache is enabled' is implemented on a per recipe basis, and it does not enable local recipes.
There is no gain for p4a developers who are almost certainly using the p4a develop version.
The general user will see a gain in build times (except if they version pin to not default), and perhaps only hostpython need be built locally?.
A future enhancement might be local (no internet) builds. These would be enabled by copying a subset of the cache to ~/.buildozer , from which p4a could alternatively copy. Locally built hostpython would also be in this cache, as well as any pure Python wheels.
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu bằng việc xem xét quy trình build recipe hiện có của p4a và cách Buildozer truyền các yêu cầu của recipe cùng các thiết lập cache. Xác định phạm vi kiểm thử hồi quy, các khóa cache của máy chủ, các điều kiện mặc định và các loại trừ recipe cục bộ trước khi triển khai. Công việc được xem là hoàn tất khi hành vi đã được đặc tả và được bao phủ bởi các kiểm thử cho cache hit, caching bị vô hiệu hóa và các lần build recipe.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- android, python
- Lĩnh vực
- build-system, mobile
- Loại issue
- Tính năng
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức độ hoạt động
- Đình trệ
- Độ rõ ràng
- Cần làm rõ
- Mức phù hợp với người mới
- 20/100