返回介绍

Development

发布于 2021-04-05 05:11:52 字数 6762 浏览 863 评论 0 收藏 0

Pull Requests

Submit Pull Requests against the develop branch.

Provide a good description of what you’re doing and why.

Provide tests that cover your changes and try to run the tests locally first.

Automated Testing

All pull requests and merges to ‘develop’ branch are tested in Travis based on our .travis.yml file.

Usually, a link to your specific travis build appears in pull requests, but if not, you can find it on our travis pull requests page

The only way to trigger Travis to run again for a pull request, is to submit another change to the pull branch.

We also have Jenkins CI that runs regularly for certain python versions on windows and centos.

Running tests

OS Requirements: subversion, bazaar, git, and mercurial.

Python Requirements: tox or pytest, virtualenv, scripttest, and mock

Ways to run the tests locally:

$ tox -e py33           # The preferred way to run the tests, can use pyNN to
                        # run for a particular version or leave off the -e to
                        # run for all versions.
$ python setup.py test  # Using the setuptools test plugin
$ py.test               # Using py.test directly
$ tox                   # Using tox against pip's tox.ini

Getting Involved

The pip project welcomes help in the following ways:

  • Making Pull Requests for code, tests, or docs.
  • Commenting on open issues and pull requests.
  • Helping to answer questions on the mailing list.

If you want to become an official maintainer, start by helping out.

Later, when you think you’re ready, get in touch with one of the maintainers, and they will initiate a vote.

Release Process

This process includes virtualenv, since pip releases necessitate a virtualenv release.

As an example, the instructions assume we’re releasing pip-1.4, and virtualenv-1.10.

  1. Upgrade setuptools, if needed:
  1. Upgrade setuptools in virtualenv/develop using the Refresh virtualenv process.
  2. Create a pull request against pip/develop with a modified .travis.yml file that installs virtualenv from virtualenv/develop, to confirm the travis builds are still passing.
  1. Create Release branches:
  1. Create pip/release-1.4 branch.
  2. In pip/develop, change pip.version to ‘1.5.dev1’.
  3. Create virtualenv/release-1.10 branch.
  4. In virtualenv/develop, change virtualenv.version to ‘1.11.dev1’.
  1. Prepare “rcX”:
  1. In pip/release-1.4, change pip.version to ‘1.4rcX’, and tag with ‘1.4rcX’.
  2. Build a pip sdist from pip/release-1.4, and build it into virtualenv/release-1.10 using the Refresh virtualenv process.
  3. In virtualenv/release-1.10, change virtualenv.version to ‘1.10rcX’, and tag with ‘1.10rcX’.
  1. Announce pip-1.4rcX and virtualenv-1.10rcX with the RC Install Instructions and elicit feedback.
  2. Apply fixes to ‘rcX’:
  1. Apply fixes to pip/release-1.4 and virtualenv/release-1.10
  2. Periodically merge fixes to pip/develop and virtualenv/develop
  1. Repeat #4 thru #6 if needed.
  2. Final Release:
  1. In pip/release-1.4, change pip.version to ‘1.4’, and tag with ‘1.4’.
  2. Merge pip/release-1.4 to pip/master.
  3. Build a pip sdist from pip/release-1.4, and load it into virtualenv/release-1.10 using the Refresh virtualenv process.
  4. Merge vitualenv/release-1.10 to virtualenv/develop.
  5. In virtualenv/release-1.10, change virtualenv.version to ‘1.10’, and tag with ‘1.10’.
  6. Merge virtualenv/release-1.10 to virtualenv/master
  7. Build and upload pip and virtualenv sdists to PyPI.

Refresh virtualenv

  1. Update the embedded versions of pip and setuptools in virtualenv_support.
  2. Run bin/rebuild-script.py to rebuild virtualenv based on the latest versions.

RC Install Instructions

$ curl -L -O https://github.com/pypa/virtualenv/archive/1.10rc1.tar.gz
$ echo "<md5sum value>  1.10rc1.tar.gz" | md5sum -c
1.10rc1.tar.gz: OK
$ tar zxf 1.10rc1.tar.gz
$ python virtualenv-1.10rc1/virtualenv.py myVE
$ myVE/bin/pip install SomePackage

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
    我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
    原文