Skip to content

Latest commit

 

History

History
121 lines (80 loc) · 2.48 KB

File metadata and controls

121 lines (80 loc) · 2.48 KB

Contributing

Running the tests

The quickest way to get feedback is to run the unit tests.

  1. Install the development dependencies:

    pip install -r dev_requirements.txt
    
  2. Run the unit tests

    py.test tests --ignore=tests/integrations
    
  3. Lint changes

    flake8 bugsnag tests
    

The integration environments are managed via tox. Some of the integration tests require conflicting dependencies, so the environment matrix ensures each set is tested. Running tox will run every configuration, or individual environments can be specified to run python version

  • configuration pairs. The complete list of configurations is available in tox.ini.

Examples:

# Run the unit tests and linter on python 3.8
tox -e py38-tests,py38-lint

# Run the Flask integration tests on python 3.5
tox -e py35-flask

# Run async support tests
tox -e py38-asynctests

Running the example django app

  • Install bugsnag somewhere the example app can read from it.

    python setup.py install

  • Install the rest of the app requirements

    cd example/django pip install -r requirements.txt

  • Boot django

    python manage.py runserver

Releasing a new version

If you're on the core team, you can release Bugsnag as follows:

Prerequisites

  • Create a PyPI account

  • Get someone to add you as contributer on bugsnag-python in PyPI

  • Create or edit the file ~/.pypirc

    [server-login]
    username: your-pypi-username
    password: your-pypi-password
    
  • Install the distribution dependencies

    pip install -r dev_requirements.txt
    

Making a release

  • Update the version number in setup.py

  • Update the CHANGELOG.md, and README.md if necessary

  • Commit

    git commit -am v4.x.x
    
  • Tag the release in git

    git tag v4.x.x
    
  • Push to git

    git push origin master && git push --tags
    
  • Push the release to PyPI

    python setup.py sdist bdist_wheel
    twine upload dist/*
    

Update docs.bugsnag.com

Update the setup guides for Python (and its frameworks) with any new content.