If you're interested in contributing, take a look at the general contributor's guide first.
This project is community supported and welcomes contributions. We are working on plans to make it GA and officially support it. As part of GA we consider migrating features of this SDK to Open Census. Specifically things like automatic data collection and more.
Run python setup.py sdist
- Unit tests:
python setup.py test
- Django tests:
django_tests/all_tests.sh
Use pip install -e <path>
to install it into test application for the testing purposes.
- Install sphinx. On Mac:
brew install sphinx-doc
. You can also use virtualenv:% python3 -m venv env # Create 'env' directory % . env/bin/activate # Activate virtual environment % pip install sphinx django # Install sphinx and django (so sphinx can find it) % python setup.py install # Install applicationinsights package % cd doc % make html . . % deactivate # Exit virtualenv
- Open docs folder
cd docs
- Generate html documents:
make html
- Update gh-pages branch
git clone https://github.com/Microsoft/ApplicationInsights-Python.git python-gh-pages cd python-gh-pages/ git checkout gh-pages cp -r ../python/doc/build/html/ . git add -A git commit -m "upgrade to the latest version"
This is for repository maintainers only:
This package is published to https://pypi.python.org/pypi/applicationinsights. These are the steps to publish the package.
- Merge
develop
tomaster
via pull request. - Tag
master
. Use CHANGELOG.md to get release description. - Travis should release a new version. For manual steps:
- Clean up repo:
git clean -xfd
. - Make sure
wheel
is installed:sudo pip install wheel
. - Make sure
twine
is installed:sudo pip install twine
. - Create distributions
python setup.py bdist_wheel
. - Create
~/.pypirc
file with the following content[distutils] index-servers= pypi [pypi] username:AppInsightsSDK password=<pwd here>
- Test distributive. You can upload it to https://test.pypi.org/ using
twine upload --repository-url https://test.pypi.org/legacy/ dist/*
- Upload the package
twine upload dist/*
.
- Clean up repo:
- Regenerate documentation on gh-pages branch.
- Update versions in
TelemetryChannel.py
,CHANGELOG.md
,conf.py
andsetup.py
.
This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.microsoft.com.
When you submit a pull request, a CLA-bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., label, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repositories using our CLA.
This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact opencode@microsoft.com with any additional questions or comments.