A library for inspecting push and task results in Mozilla's CI
Перейти к файлу
dependabot[bot] d1d86f21ce
Bump jinja2 from 3.1.3 to 3.1.4 (#1112)
Bumps [jinja2](https://github.com/pallets/jinja) from 3.1.3 to 3.1.4.
- [Release notes](https://github.com/pallets/jinja/releases)
- [Changelog](https://github.com/pallets/jinja/blob/main/CHANGES.rst)
- [Commits](https://github.com/pallets/jinja/compare/3.1.3...3.1.4)

---
updated-dependencies:
- dependency-name: jinja2
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-05-31 10:15:09 +02:00
.github Update pre-commit repositories and add a few new checkers 2021-01-05 01:58:41 +01:00
docs Add filters to control autoclassification in JSON output from config (#679) 2022-03-08 10:58:50 +01:00
mozci On Android, assume suite is 'junit' when it is empty (#1111) 2024-05-31 10:14:50 +02:00
tests Update URL to variants.yml file (#1108) 2024-05-31 00:36:43 +02:00
.flake8 Use black and pre-commit (#70) 2020-02-26 17:05:30 +01:00
.gitignore Write a script to run the classify algorithm with various parameters combinations (#694) 2022-06-16 12:56:34 +02:00
.isort.cfg Add a bare-bones CLI for mozci (#531) 2021-11-03 19:49:46 +01:00
.pre-commit-config.yaml Update pre-commit repositories 2023-10-11 01:06:48 +02:00
.taskcluster.yml Fix dind problems (#962) 2023-05-05 18:02:35 +02:00
Dockerfile Bump to Python 3.10 (#784) 2022-06-11 19:15:43 +02:00
LICENSE Initial commit 2019-11-28 15:53:22 -05:00
README.md Remove troubleshooting section from README 2021-03-03 13:59:35 -05:00
poetry.lock Bump jinja2 from 3.1.3 to 3.1.4 (#1112) 2024-05-31 10:15:09 +02:00
pyproject.toml Bump to 2.4.0 2024-01-22 20:23:00 +01:00
requirements.readthedocs.txt Add some basic Sphinx documentation 2020-03-16 12:47:51 -04:00
tox.ini Use --no-ansi option for poetry 2023-04-12 16:42:42 +02:00

README.md

Task Status PyPI version Docs

mozci

A library for inspecting push and task results in Mozilla's CI.

Installation

To install, run:

$ pip install mozci

Usage

Basic usage is to instantiate a Push object then start accessing properties and call methods. For example:

from mozci.push import Push

push = Push("79041cab0cc2", branch="autoland")
print("\n".join([t.label for t in push.tasks if t.failed]))

This will print all the failing tasks from a given push. See the documentation for more usage details and API docs.

Contributing

Mozci uses poetry to manage the project. So first make sure that is installed. Then clone the repo and run:

$ poetry install

This will create a virtualenv and install both project and dev dependencies in it. See the poetry documentation to learn how to work within the project.

To execute tests and linters, run:

$ tox

This should run successfully prior to submitting PRs (unless you need help figuring out the problem).

There are also some integration tests that will hit live data sources. These are run in a cron task and are excluded from the default test run. But if needed, you can run them locally via:

$ tox -e integration

Since tox installs packages on every invocation, it's much faster to run tests directly with pytest:

$ poetry run pytest tests

or

$ poetry shell
$ pytest tests

Additionally, you can install the pre-commit hooks by running:

$ pre-commit install

Linters and formatters will now run every time you commit.