RFC edk2-tools-library creation
Create a new tianocore owned repository to host a python library package in support of UEFI development. This package will allow easy sharing of python library code to facilitate reuse. Inclusion of this package and dependency management should be managed using Pip/Pypi. This is a supplemental package and is not required to be used for edk2 builds. To avoid conflicting dependencies on your host platform it is strongly suggested to leverage python virtual environments.
Examples of content here
- Edk2 file type parsing
- UEFI structure encode/decode in python
- Packaging tools (Capsules generation, signing, INF gen, Cat gen)
- TPM support code
- No command line tools/interface
Maintainers
- Sean Brogan
- Bret Barkelew
- Placeholder for existing maintainer from the basetools
License
- BSD + Patent (edk2 aligned)
Contribution process and issue tracking
- Follow Github PR process for contributions and issue tracking
- Contributor forks repo in github
- Contributor creates branch for work
- Contributor updates release notes to indicate change (if necessary)
- Contributor submits PR to master branch of tianocore/edk2-tools-library repo
- Review feedback is given in PR
- Python Tests are run on the repo (new contributions need unit tests)
- Python Style (flake8) must pass
- All review feedback must be completed, maintainers approved, and tests run successfully before PR is squash merged into master. Since squash merge is used there is no support for patchsets. The PR should be sized appropriately.
Documentation
- Use Github IO documentation/wiki hosting
- Example content
- https://microsoft.github.io/mu/dyn/mu_pip_python_library/developing/
- https://microsoft.github.io/mu/dyn/mu_pip_python_library/publishing/
- Readme at root of repo
- Example: https://github.com/Microsoft/mu_pip_python_library
- API documentation
- Figure out autogenerated pydocs
CI Builds
- CI build process using dev ops (new TianoCore organization created in Azure devops)
- Validation is done thru build process
- Release publication done thru manual CI Build
- Examples from Mu-Python-Library
- Windows CI - https://dev.azure.com/projectmu/mu%20pip/_build?definitionId=13
- Linux CI - https://dev.azure.com/projectmu/mu%20pip/_build?definitionId=12
- Publishing - https://dev.azure.com/projectmu/mu%20pip/_build?definitionId=16
Release
- Release to Pypi as edk2-tools-library for easy usage in product environment
- Versioned follows: Aa.bb.cc and is based on tags in git
- AA == Major version. Changes don’t need to be backward compatible
- BB == Minor version. Significant new features. Backward compatibility maintained
- CC == Bug fix/patch/small optional feature
- Package on Pypi will be owned by Tianocore group
- Example for mu-python-library: https://pypi.org/project/mu-python-library/
Other Notes
- Only support Python 3 (prefer 3.7+)
- This was discussed on the edk2 design meetings (4/18) https://edk2.groups.io/g/devel/files/Designs/2019/0418
- There will be one more RFC for another python package/repo for edk2-tools-extensions
- Will start version 00.09.00 while getting the repository setup and functioning with 1.0.0 being the first real release