CHANGELOG#

v4.4.0 (2024-01-15)#

Chore#

  • chore(deps): update all non-major dependencies (550f935)

  • chore(deps): update pre-commit hook pycqa/flake8 to v7 (9a199b6)

  • chore(deps): update dependency jinja2 to v3.1.3 [security] (880913b)

  • chore(deps): update dependency flake8 to v7 (20243c5)

  • chore(deps): update all non-major dependencies (cbc13a6)

  • chore(ci): align upload and download action versions (dcca59d)

  • chore(deps): update actions/upload-artifact action to v4 (7114af3)

  • chore(ci): add Python 3.13 development CI job

Add a job to test the development versions of Python 3.13. (ff0c11b)

  • chore(deps): update all non-major dependencies (369a595)

Feature#

  • feat(api): add reviewer_details manager for mergrequest to get reviewers of merge request

Those changes implements ‘GET /projects/:id/merge_requests/:merge_request_iid/reviewers’ gitlab API call. Naming for call is not reviewers because reviewers atribute already presen in merge request response (adbd90c)

  • feat(api): support access token rotate API (b13971d)

  • feat(api): support single resource access token get API (dae9e52)

Fix#

  • fix(cli): support binary files with @ notation

Support binary files being used in the CLI with arguments using the @ notation. For example --avatar @/path/to/avatar.png

Also explicitly catch the common OSError exception, which is the parent exception for things like: FileNotFoundError, PermissionError and more exceptions.

Remove the bare exception handling. We would rather have the full traceback of any exceptions that we don’t know about and add them later if needed.

Closes: #2752 (57749d4)

v4.3.0 (2023-12-28)#

Chore#

  • chore(deps): update all non-major dependencies (d7bdb02)

  • chore(deps): update actions/stale action to v9 (c01988b)

  • chore(deps): update all non-major dependencies (9e067e5)

  • chore(deps): update actions/setup-python action to v5 (fad1441)

  • chore(deps): update all non-major dependencies (bb2af7b)

  • chore(deps): update all non-major dependencies (5ef1b4a)

  • chore(deps): update dependency types-setuptools to v69 (de11192)

Documentation#

  • docs: fix rst link typo in CONTRIBUTING.rst (2b6da6e)

Feature#

  • feat(api): add support for the Draft notes API (#2728)

  • feat(api): add support for the Draft notes API

  • fix(client): handle empty 204 reponses in PUT requests (ebf9d82)

Fix#

  • fix(cli): add ability to disable SSL verification

Add a --no-ssl-verify option to disable SSL verification

Closes: #2714 (3fe9fa6)

v4.2.0 (2023-11-28)#

Chore#

  • chore(deps): update all non-major dependencies (8aeb853)

  • chore(deps): update dessant/lock-threads action to v5 (f4ce867)

  • chore(deps): update all non-major dependencies (9fe2335)

  • chore(deps): update all non-major dependencies (91e66e9)

  • chore(deps): update all non-major dependencies (d0546e0)

Feature#

  • feat: add pipeline status as Enum

https://docs.gitlab.com/ee/api/pipelines.html (4954bbc)

  • feat(api): add support for wiki attachments (#2722)

Added UploadMixin in mixin module Added UploadMixin dependency for Project, ProjectWiki, GroupWiki Added api tests for wiki upload Added unit test for mixin Added docs sections to wikis.rst (7b864b8)

v4.1.1 (2023-11-03)#

Chore#

  • chore(ci): add release id to workflow step (9270e10)

  • chore(deps): update all non-major dependencies (32954fb)

Documentation#

  • docs(users): add missing comma in v4 API create runner examples

The examples which show usage of new runner registration api endpoint are missing commas. This change adds the missing commas. (b1b2edf)

Fix#

  • fix(build): include py.typed in dists (b928639)

v4.1.0 (2023-10-28)#

Chore#

  • chore(deps): update all non-major dependencies (bf68485)

  • chore(CHANGELOG): re-add v4.0.0 changes using old format (258a751)

  • chore(CHANGELOG): revert python-semantic-release format change (b5517e0)

  • chore: add source label to container image (7b19278)

  • chore(rtd): revert to python 3.11 (#2694) (1113742)

Ci#

  • ci: remove unneeded GitLab auth (fd7bbfc)

Feature#

  • feat: add Merge Request merge_status and detailed_merge_status values as constants (e18a424)

Fix#

  • fix: remove depricated MergeStatus (c6c012b)

v4.0.0 (2023-10-17)#

Breaking#

  • docs(advanced): document new netrc behavior

BREAKING CHANGE: python-gitlab now explicitly passes auth to requests, meaning it will only read netrc credentials if no token is provided, fixing a bug where netrc credentials took precedence over OAuth tokens. This also affects the CLI, where all environment variables now take precedence over netrc files. (45b8930)

  • refactor(build): build project using PEP 621

BREAKING CHANGE: python-gitlab now stores metadata in pyproject.toml as per PEP 621, with setup.py removed. pip version v21.1 or higher is required if you want to perform an editable install. (71fca8c)

  • refactor(const): remove deprecated global constant import

BREAKING CHANGE: Constants defined in gitlab.const can no longer be imported globally from gitlab. Import them from gitlab.const instead. (e4a1f6e)

  • refactor(list): as_list support is removed.

In list() calls support for the as_list argument has been removed. as_list was previously deprecated and now the use of iterator will be required if wanting to have same functionality as using as_list

BREAKING CHANGE: Support for the deprecated as_list argument in list() calls has been removed. Use iterator instead. (9b6d89e)

  • refactor(lint): remove deprecated lint()in favor of ci_lint.create()

BREAKING CHANGE: The deprecated lint() method is no longer available. Use ci_lint.create() instead. (0b17a2d)

  • refactor(artifacts): remove deprecated artifact()in favor of artifacts.raw()

BREAKING CHANGE: The deprecated project.artifact() method is no longer available. Use project.artifacts.raw() instead. (90134c9)

  • refactor(artifacts): remove deprecated artifacts()in favor of artifacts.download()

BREAKING CHANGE: The deprecated project.artifacts() method is no longer available. Use project.artifacts.download() instead. (42639f3)

  • refactor(groups): remove deprecated LDAP group link add/delete methods

BREAKING CHANGE: The deprecated group.add_ldap_group_link() and group.delete_ldap_group_link() methods are no longer available. Use group.ldap_group_links.create() and group.ldap_group_links.delete() instead. (5c8b7c1)

  • refactor(projects): remove deprecated project.transfer_project() in favor of project.transfer()

BREAKING CHANGE: The deprecated project.transfer_project() method is no longer available. Use project.transfer() instead. (27ed490)

  • fix(cli): remove deprecated --all option in favor of --get-all

BREAKING CHANGE: The --all option is no longer available in the CLI. Use --get-all instead. (e9d48cf)

  • feat: remove support for Python 3.7, require 3.8 or higher

Python 3.8 is End-of-Life (EOL) as of 2023-06-27 as stated in https://devguide.python.org/versions/ and https://peps.python.org/pep-0537/

By dropping support for Python 3.7 and requiring Python 3.8 or higher it allows python-gitlab to take advantage of new features in Python 3.8, which are documented at: https://docs.python.org/3/whatsnew/3.8.html

BREAKING CHANGE: As of python-gitlab 4.0.0, Python 3.7 is no longer supported. Python 3.8 or higher is required. (058d5a5)

Chore#

  • chore(ci): follow upstream config for release build_command (3e20a76)

  • chore(ci): update release build for python-semantic-release v8 (#2692) (bf050d1)

  • chore(deps): update pre-commit hook pycqa/pylint to v3 (0f4a346)

  • chore(deps): update all non-major dependencies (1348a04)

  • chore: add package pipelines API link (2a2404f)

  • chore(ci): fix pre-commit deps and python version (1e7f257)

  • chore(ci): remove Python 3.13 dev job (e8c50f2)

  • chore(helpers): fix previously undetected flake8 issue (bf8bd73)

  • chore: fix test names (f1654b8)

  • chore: make linters happy (3b83d5d)

  • chore: change _update_uses to _update_method and use an Enum

Change the name of the _update_uses attribute to _update_method and store an Enum in the attribute to indicate which type of HTTP method to use. At the moment it supports POST and PUT. But can in the future support PATCH. (7073a2d)

  • chore(deps): update all non-major dependencies (ff45124)

  • chore(deps): update dependency pylint to v3 (491350c)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v37 (b4951cd)

  • chore(deps): update all non-major dependencies (0d49164)

  • chore(deps): update dependency commitizen to v3.10.0 (becd8e2)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v3.10.0 (626c2f8)

  • chore(deps): update all non-major dependencies (6093dbc)

  • chore(deps): update all non-major dependencies (bb728b1)

  • chore(deps): update all non-major dependencies to v23.9.1 (a16b732)

  • chore(deps): update actions/checkout action to v4 (af13914)

  • chore(deps): update all non-major dependencies (9083787)

  • chore(deps): update dependency build to v1 (2e856f2)

  • chore(deps): update all non-major dependencies (b6a3db1)

  • chore(rtd): use readthedocs v2 syntax (6ce2149)

  • chore(rtd): fix docs build on readthedocs.io (#2654) (3d7139b)

  • chore(ci): adapt release workflow and config for v8 (827fefe)

  • chore(deps): update relekang/python-semantic-release action to v8 (c57c85d)

  • chore(deps): update all non-major dependencies (16f2d34)

  • chore(deps): update all non-major dependencies (5b33ade)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v36 (db58cca)

  • chore(deps): update dependency ubuntu to v22 (8865552)

  • chore(deps): update all non-major dependencies (3732841)

  • chore(deps): update dependency pytest-docker to v2 (b87bb0d)

  • chore: switch to docker-compose v2

Closes: #2625 (713b5ca)

  • chore: update PyYAML to 6.0.1

Fixes issue with CI having error: AttributeError: cython_sources

Closes: #2624 (3b8939d)

  • chore(deps): update all non-major dependencies (511f45c)

  • chore(deps): update all non-major dependencies (d4a7410)

  • chore(deps): update all non-major dependencies (12846cf)

  • chore(deps): update all non-major dependencies (33d2aa2)

  • chore(deps): update dependency types-setuptools to v68 (bdd4eb6)

  • chore(deps): update actions/upload-artifact action to v3 (b78d6bf)

  • chore(deps): update dependency setuptools to v68 (0f06082)

  • chore(deps): bring myst-parser up to date with sphinx 7 (da03e9c)

  • chore(deps): bring furo up to date with sphinx (a15c927)

  • chore(deps): update dependency sphinx to v7 (2918dfd)

  • chore(deps): update actions/checkout action to v3 (e2af1e8)

  • chore(deps): update actions/setup-python action to v4 (e0d6783)

  • chore(deps): update all non-major dependencies (5ff56d8)

  • chore(deps): pin pytest-console-scripts for 3.7 (6d06630)

  • chore(deps): update all non-major dependencies (7586a5c)

Documentation#

  • docs: correct error with back-ticks (#2653)

New linting package update detected the issue. (0b98dd3)

  • docs(access_token): adopt token docs to 16.1

expires_at is now required Upstream MR: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/124964 (fe7a971)

  • docs(files): fix minor typo in variable declaration (118ce42)

Feature#

  • feat(client): mask tokens by default when logging (1611d78)

  • feat(api): add ProjectPackagePipeline

Add ProjectPackagePipeline, which is scheduled to be included in GitLab 16.0 (5b4addd)

  • feat: officially support Python 3.12 (2a69c0e)

  • feat(packages): Allow uploading bytes and files

This commit adds a keyword argument to GenericPackageManager.upload() to allow uploading bytes and file-like objects to the generic package registry. That necessitates changing file path to be a keyword argument as well, which then cascades into a whole slew of checks to not allow passing both and to not allow uploading file-like objects as JSON data.

Closes https://github.com/python-gitlab/python-gitlab/issues/1815 (61e0fae)

  • feat: Use requests AuthBase classes (5f46cfd)

  • feat(api): add support for job token scope settings (59d6a88)

  • feat(api): support project remote mirror deletion (d900910)

  • feat(api): add optional GET attrs for /projects/:id/ci/lint (40a102d)

  • feat(api): add support for new runner creation API (#2635)

Co-authored-by: Nejc Habjan <hab.nejc@gmail.com> (4abcd17)

  • feat(releases): Add support for direct_asset_path

This commit adds support for the “new” alias for filepath: direct_asset_path (added in 15.10) in release links API. (d054917)

  • feat: Added iteration to issue and group filters (8d2d297)

Fix#

  • fix(cli): add _from_parent_attrs to user-project manager (#2558) (016d90c)

  • fix(cli): fix action display in –help when there are few actions

fixes #2656 (b22d662)

  • fix(client): support empty 204 responses in http_patch (e15349c)

  • fix(snippets): allow passing list of files (31c3c5e)

Test#

  • test: add tests for token masking (163bfcf)

  • test(cli): add test for user-project list (a788cff)

  • test: correct calls to script_runner.run()

Warnings were being raised. Resolve those warnings. (cd04315)

  • test: fix failing tests that use 204 (No Content) plus content

urllib3>=2 now checks for expected content length. Also codes 204 and 304 are set to expect a content length of 0 [1]

So in the unit tests stop setting content to return in these situations.

[1] https://github.com/urllib3/urllib3/blob/88a707290b655394aade060a8b7eaee83152dc8b/src/urllib3/response.py#L691-L693 (3074f52)

Unknown#

  • chore(deps): update dependency requests to v2.31.0 [security]

Also update dependency responses==0.23.3 as it provides support for urllib3&gt;=2

Closes: #2626 (988a6e7)

v3.15.0 (2023-06-09)#

Chore#

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v35 (8202e3f)

  • chore: update sphinx from 5.3.0 to 6.2.1 (c44a290)

  • chore: update copyright year to include 2023 (511c6e5)

  • chore(deps): update all non-major dependencies (e3de6ba)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v3 (1591e33)

  • chore(deps): update dependency types-setuptools to v67 (c562424)

  • chore(deps): update dependency requests-toolbelt to v1 (86eba06)

  • chore(deps): update dependency myst-parser to v1 (9c39848)

  • chore(deps): update dependency commitizen to v3 (784d59e)

  • chore(ci): use OIDC trusted publishing for pypi.org (#2559)

  • chore(ci): use OIDC trusted publishing for pypi.org

  • chore(ci): explicitly install setuptools in tests (7be09e5)

Documentation#

  • docs: remove exclusive EE about issue links (e0f6f18)

Feature#

  • feat: add support for select=&#34;package_file&#34; in package upload

Add ability to use select=&#34;package_file&#34; when uploading a generic package as described in: https://docs.gitlab.com/ee/user/packages/generic_packages/index.html

Closes: #2557 (3a49f09)

  • feat(api): add support for events scope parameter (348f56e)

  • feat: usernames support for MR approvals

This can be used instead of ‘user_ids’

See: https://docs.gitlab.com/ee/api/merge_request_approvals.html#create-project-level-rule (a2b8c8c)

v3.14.0 (2023-04-11)#

Chore#

  • chore(ci): wait for all coverage reports in CI status (511764d)

  • chore(setup): depend on typing-extensions for 3.7 until EOL (3abc557)

  • chore: add Contributor Covenant 2.1 as Code of Conduct

See https://www.contributor-covenant.org/version/2/1/code_of_conduct/ (fe334c9)

  • chore(deps): update all non-major dependencies (8b692e8)

  • chore(deps): update dependency furo to v2023 (7a1545d)

  • chore(deps): update actions/stale action to v8 (7ac4b86)

  • chore(pre-commit): Bumping versions (e973729)

  • chore(.github): actually make PR template the default (7a8a862)

  • chore: use a dataclass to return values from prepare_send_data

I found the tuple of three values confusing. So instead use a dataclass to return the three values. It is still confusing but a little bit less so.

Also add some unit tests (f2b5e4f)

  • chore(contributing): refresh development docs (d387d91)

  • chore(github): add default pull request template (bf46c67)

  • chore(deps): update all non-major dependencies (#2493)

  • chore(deps): update all non-major dependencies

  • chore(fixtures): downgrade GitLab for now

  • chore(deps): ungroup typing deps, group gitlab instead

  • chore(deps): downgrade argcomplete for now


Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: Nejc Habjan <nejc.habjan@siemens.com> (07d03dc)

  • chore(deps): update dependency pre-commit to v3 (#2508)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> (7d779c8)

  • chore(deps): update dependency coverage to v7 (#2501)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> (aee73d0)

  • chore(deps): update dependency flake8 to v6 (#2502)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> (3d4596e)

  • chore(renovate): swith to gitlab-ee (8da48ee)

  • chore(renovate): bring back custom requirements pattern (ae0b21c)

  • chore(deps): update mypy (1.0.0) and responses (0.22.0)

Update the requirements-* files.

In order to update mypy==1.0.0 we need to also update responses==0.22.0

Fix one issue found by mypy

Leaving updates for precommit to be done in a separate commit by someone. (9c24657)

  • chore(renovate): do not ignore tests dir (5b8744e)

  • chore(deps): update all non-major dependencies (2f06999)

  • chore(deps): update pre-commit hook psf/black to v23 (217a787)

  • chore(deps): update black (23.1.0) and commitizen (2.40.0) (#2479)

Update the dependency versions: black: 23.1.0 commitizen: 2.40.0

They needed to be updated together as just updating black caused a dependency conflict.

Updated files by running black and committing the changes. (44786ef)

  • chore: add SECURITY.md (572ca3b)

  • chore: remove pre-commit as a default tox environment (#2470)

For users who use tox having pre-commit as part of the default environment list is redundant as it will run the same tests again that are being run in other environments. For example: black, flake8, pylint, and more. (fde2495)

  • chore: add Python 3.12 testing

Add a unit test for Python 3.12. This will use the latest version of Python 3.12 that is available from https://github.com/actions/python-versions/

At this time it is 3.12.0-alpha.4 but will move forward over time until the final 3.12 release and updates. So 3.12.0, 3.12.1, … will be matched. (0867564)

Documentation#

  • docs(objects): fix typo in pipeline schedules (3057f45)

  • docs(advanced): clarify netrc, proxy behavior with requests (1da7c53)

  • docs: fix update badge behaviour

docs: fix update badge behaviour

Earlier: badge.image_link = new_link

Now: badge.image_url = new_image_url badge.link_url = new_link_url (3d7ca1c)

  • docs(advanced): fix typo in Gitlab examples (1992790)

Feature#

  • feat(projects): allow importing additional items from GitHub (ce84f2e)

  • feat(objects): support fetching PATs via id or self endpoint (19b38bd)

  • feat: add resource_weight_event for ProjectIssue (6e5ef55)

  • feat(backends): use PEP544 protocols for structural subtyping (#2442)

The purpose of this change is to track API changes described in https://github.com/python-gitlab/python-gitlab/blob/main/docs/api-levels.rst, for example, for package versioning and breaking change announcements in case of protocol changes.

This is MVP implementation to be used by #2435. (4afeaff)

  • feat(client): add http_patch method (#2471)

In order to support some new API calls we need to support the HTTP PATCH method.

Closes: #2469 (f711d9e)

  • feat(cli): add setting of allow_force_push for protected branch

For the CLI: add allow_force_push as an optional argument for creating a protected branch.

API reference: https://docs.gitlab.com/ee/api/protected_branches.html#protect-repository-branches

Closes: #2466 (929e07d)

Fix#

  • fix(cli): warn user when no fields are displayed (8bf53c8)

  • fix(client): properly parse content-type when charset is present (76063c3)

  • fix: support int for parent_id in import_group

This will also fix other use cases where an integer is passed in to MultipartEncoder.

Added unit tests to show it works.

Closes: #2506 (90f96ac)

  • fix(cli): add ability to escape at-prefixed parameter (#2513)

  • fix(cli): Add ability to escape at-prefixed parameter (#2511)


Co-authored-by: Nejc Habjan <hab.nejc@gmail.com> (4f7c784)

  • fix(cli): display items when iterator is returned (33a04e7)

  • fix: typo fixed in docs (ee5f444)

Refactor#

  • refactor(client): let mypy know http_password is set (2dd177b)

Test#

  • test(unit): increase V4 CLI coverage (5748d37)

  • test(unit): split the last remaining unittest-based classes into modules” (14e0f65)

  • test(unit): remove redundant package (4a9e3ee)

  • test(unit): consistently use inline fixtures (1bc56d1)

  • test(meta): move meta suite into unit tests

They’re always run with it anyway, so it makes no difference. (847004b)

  • test(functional): clarify MR fixture factory name (d8fd1a8)

Unknown#

  • Merge pull request #2465 from valentingregoire/typos

docs: fix typo in issue docs (43f5ac5)

  • Merge branch ‘main’ into typos (3cfd390)

v3.13.0 (2023-01-30)#

Chore#

  • chore: make backends private (1e629af)

  • chore(deps): update all non-major dependencies (ea7010b)

  • chore: add a UserWarning if both iterator=True and page=X are used (#2462)

If a caller calls a list() method with both iterator=True (or as_list=False) and page=X then emit a UserWarning as the options are mutually exclusive. (8e85791)

  • chore: remove tox envdir values

tox > 4 no longer will re-use the tox directory :( What this means is that with the previous config if you ran: $ tox -e mypy; tox -e isort; tox -e mypy It would recreate the tox environment each time :(

By removing the envdir values it will have the tox environments in separate directories and not recreate them.

The have an FAQ entry about this: https://tox.wiki/en/latest/upgrading.html#re-use-of-environments (3c7c7fc)

  • chore: update attributes for create and update projects (aa44f2a)

  • chore(deps): update all non-major dependencies (122988c)

  • chore(deps): update all non-major dependencies (49c0233)

  • chore(deps): update all non-major dependencies (10c4f31)

  • chore(deps): update all non-major dependencies (bbd01e8)

  • chore(deps): update actions/stale action to v7 (76eb024)

  • chore(ci): complete all unit tests even if one has failed (#2438) (069c6c3)

  • chore: add test, docs, and helper for 409 retries (3e1c625)

  • chore(deps): update all non-major dependencies (6682808)

  • chore(deps): update all non-major dependencies (1816107)

  • chore(deps): update pre-commit hook pycqa/flake8 to v6 (82c61e1)

  • chore: add docs for schedule pipelines (9a9a6a9)

  • chore(tox): ensure test envs have all dependencies (63cf4e4)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v34.48.4 (985b971)

  • chore(deps): update dessant/lock-threads action to v4 (337b25c)

  • chore: Use SPDX license expression in project metadata (acb3a4a)

  • chore(deps): update actions/download-artifact action to v3 (64ca597)

  • chore(deps): update all non-major dependencies (21e767d)

Documentation#

  • docs(faq): describe and group common errors (4c9a072)

Feature#

  • feat(group): add support for group restore API (9322db6)

  • feat(client): automatically retry on HTTP 409 Resource lock

Fixes: #2325 (dced76a)

  • feat(api): add support for bulk imports API (043de2d)

  • feat(api): add support for resource groups (5f8b8f5)

  • feat(api): support listing pipelines triggered by pipeline schedules (865fa41)

  • feat: allow filtering pipelines by source

See: https://docs.gitlab.com/ee/api/pipelines.html#list-project-pipelines Added in GitLab 14.3 (b6c0872)

  • feat(client): bootstrap the http backends concept (#2391) (91a665f)

  • feat: add resource iteration events (see https://docs.gitlab.com/ee/api/resource_iteration_events.html) (ef5feb4)

  • feat: allow passing kwargs to Gitlab class when instantiating with from_config (#2392) (e88d34e)

  • feat: add keep_base_url when getting configuration from file (50a0301)

Fix#

  • fix(client): regression - do not automatically get_next if page=# and iterator=True/as_list=False are used

This fix a regression introduced on commit https://github.com/python-gitlab/python-gitlab/commit/1339d645ce58a2e1198b898b9549ba5917b1ff12

If page is used, then get_next should be false.

This was found on the mesa ci project, after upgrading the python-gitlab version, the script that monitors the ci was getting killed by consuming too much memory. (585e3a8)

  • fix: change return value to “None” in case getattr returns None to prevent error (3f86d36)

  • fix(deps): bump requests-toolbelt to fix deprecation warning (faf842e)

  • fix: Use the ProjectIterationManager within the Project object

The Project object was previously using the GroupIterationManager resulting in the incorrect API endpoint being used. Utilize the correct ProjectIterationManager instead.

Resolves #2403 (44f05dc)

  • fix(api): Make description optional for releases (5579750)

Refactor#

  • refactor: add reason property to RequestsResponse (#2439) (b59b7bd)

  • refactor: remove unneeded requests.utils import (#2426) (6fca651)

  • refactor: Migrate MultipartEncoder to RequestsBackend (#2421) (43b369f)

  • refactor: move Response object to backends (#2420) (7d9ce0d)

  • refactor: move the request call to the backend (#2413) (283e7cc)

  • refactor: Moving RETRYABLE_TRANSIENT_ERROR_CODES to const (887852d)

Test#

  • test(functional): do not require config file (43c2dda)

  • test(unit): expand tests for pipeline schedules (c7cf0d1)

v3.12.0 (2022-11-28)#

Chore#

  • chore: validate httpx package is not installed by default (0ecf3bb)

  • chore(deps): update all non-major dependencies (d8a657b)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v34.24.0 (a0553c2)

  • chore: correct website for pylint

Use https://github.com/PyCQA/pylint as the website for pylint. (fcd72fe)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v34.20.0 (e6f1bd6)

  • chore(deps): update all non-major dependencies (b2c6d77)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v34 (623e768)

Documentation#

  • docs: Use the term “log file” for getting a job log file

The GitLab docs refer to it as a log file: https://docs.gitlab.com/ee/api/jobs.html#get-a-log-file

“trace” is the endpoint name but not a common term people will think of for a “log file” (9d2b1ad)

  • docs(groups): describe GitLab.com group creation limitation (9bd433a)

  • docs(api): pushrules remove saying None is returned when not found

In groups.pushrules.get(), GitLab does not return None when no rules are found. GitLab returns a 404.

Update docs to not say it will return None

Also update docs in project.pushrules.get() to be consistent. Not 100% sure if it returns None or returns a 404, but we don’t need to document that.

Closes: #2368 (c3600b4)

Feature#

  • feat: add support for SAML group links (#2367) (1020ce9)

  • feat(groups): add LDAP link manager and deprecate old API endpoints (3a61f60)

  • feat(groups): add support for listing ldap_group_links (#2371) (ad7c8fa)

  • feat: implement secure files API (d0a0348)

  • feat(ci): Re-Run Tests on PR Comment workflow (034cde3)

  • feat(api): add support for getting a project’s pull mirror details

Add the ability to get a project’s pull mirror details. This was added in GitLab 15.5 and is a PREMIUM feature.

https://docs.gitlab.com/ee/api/projects.html#get-a-projects-pull-mirror-details (060cfe1)

  • feat(api): add support for remote project import from AWS S3 (#2357) (892281e)

  • feat(api): add support for remote project import (#2348) (e5dc72d)

  • feat(api): add application statistics (6fcf3b6)

Fix#

  • fix(cli): Enable debug before doing auth

Authentication issues are currently hard to debug since --debug only has effect after gl.auth() has been called.

For example, a 401 error is printed without any details about the actual HTTP request being sent:

$ gitlab --debug --server-url https://gitlab.com current-user get
401: 401 Unauthorized

By moving the call to gl.enable_debug() the usual debug logs get printed before the final error message.

Signed-off-by: Emanuele Aina <emanuele.aina@collabora.com> (65abb85)

  • fix(cli): expose missing mr_default_target_self project attribute

Example::

gitlab project update –id 616 –mr-default-target-self 1

References:

  • https://gitlab.com/gitlab-org/gitlab/-/merge_requests/58093

  • https://gitlab.com/gitlab-org/gitlab/-/blob/v13.11.0-ee/doc/user/project/merge_requests/creating_merge_requests.md#new-merge-request-from-a-fork

  • https://gitlab.com/gitlab-org/gitlab/-/blob/v14.7.0-ee/doc/api/projects.md#get-single-project (12aea32)

  • fix: use POST method and return dict in cancel_merge_when_pipeline_succeeds() (#2350)

  • Call was incorrectly using a PUT method when should have used a POST method.

    • Changed return type to a dict as GitLab only returns {‘status’: ‘success’} on success. Since the function didn’t work previously, this should not impact anyone.

    • Updated the test fixture merge_request to add ability to create a pipeline.

    • Added functional test for mr.cancel_merge_when_pipeline_succeeds()

Fixes: #2349 (bd82d74)

Refactor#

  • refactor: explicitly use ProjectSecureFile (0c98b2d)

Test#

  • test(api): fix flaky test test_cancel_merge_when_pipeline_succeeds

This is an attempt to fix the flaky test test_cancel_merge_when_pipeline_succeeds. Were seeing a: 405 Method Not Allowed error when setting the MR to merge_when_pipeline_succeeds.

Closes: #2383 (6525c17)

Unknown#

  • Merge pull request #2347 from Shreya-7/issue-2264-add-application-statistics

feat(api): add application statistics (31ec146)

  • Merge pull request #2351 from python-gitlab/renovate/all-minor-patch

chore(deps): update all non-major dependencies (2974966)

  • Merge pull request #2352 from python-gitlab/renovate/maxbrunet-pre-commit-renovate-34.x

chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v34 (c3d9820)

v3.11.0 (2022-10-28)#

Chore#

  • chore: add responses to pre-commit deps (4b8ddc7)

  • chore: add basic type checks to functional/api tests (5b642a5)

  • chore: add basic typing to functional tests (ee143c9)

  • chore: narrow type hints for license API (50731c1)

  • chore: add basic type checks to meta tests (545d6d6)

  • chore: add basic typing to smoke tests (64e8c31)

  • chore: add basic typing to test root (0b2f6bc)

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v33 (932bbde)

  • chore(deps): update all non-major dependencies (dde3642)

  • chore: add not-callable to pylint ignore list

The not-callable error started showing up. Ignore this error as it is invalid. Also mypy tests for these issues.

Closes: #2334 (f0c02a5)

  • chore: revert compose upgrade

This reverts commit f825d70e25feae8cd9da84e768ec6075edbc2200. (dd04e8e)

  • chore(deps): update all non-major dependencies (2966234)

  • chore: use kwargs for http_request docs (124abab)

  • chore(deps): pin GitHub Actions (8dbaa5c)

  • chore(deps): group non-major upgrades to reduce noise (37d14bd)

  • chore(deps): pin and clean up test dependencies (60b9197)

  • chore(deps): pin dependencies (953f38d)

  • chore: topic functional tests (d542eba)

  • chore: renovate and precommit cleanup (153d373)

  • chore(deps): update black to v22.10.0 (531ee05)

  • chore(deps): update dependency types-requests to v2.28.11.2 (d47c0f0)

  • chore: fix flaky test (fdd4114)

  • chore: update the issue templates

  • Have an option to go to the discussions

  • Have an option to go to the Gitter chat

  • Move the bug/issue template into the .github/ISSUE_TEMPLATE/ directory (c15bd33)

  • chore: simplify wait_for_sidekiq usage

Simplify usage of wait_for_sidekiq by putting the assert if it timed out inside the function rather than after calling it. (196538b)

  • chore(deps): update dependency pylint to v2.15.3 (6627a60)

  • chore(deps): update dependency mypy to v0.981 (da48849)

  • chore(deps): update dependency commitizen to v2.35.0 (4ce9559)

  • chore(deps): update typing dependencies (81285fa)

Documentation#

  • docs(advanced): add hint on type narrowing (a404152)

  • docs: add minimal docs about the enable_debug() method

Add some minimal documentation about the enable_debug() method. (b4e9ab7)

  • docs(commits): fix commit create example for binary content (bcc1eb4)

  • docs(readme): add a basic feature list (b4d53f1)

  • docs(api): describe use of lower-level methods (b7a6874)

  • docs(api): describe the list() and all() runners’ functions (b6cc3f2)

  • docs(api): Update merge_requests.rst: mr_id to mr_iid

Typo: Author probably meant mr_iid (i.e. project-specific MR ID) and not mr_id (i.e. server-wide MR ID)

Closes: https://github.com/python-gitlab/python-gitlab/issues/2295

Signed-off-by: Stavros Ntentos <133706+stdedos@users.noreply.github.com> (b32234d)

Feature#

  • feat(build): officially support Python 3.11 (74f66c7)

  • feat(api): add support for topics merge API (9a6d197)

Fix#

  • fix: remove project.approvals.set_approvals() method

The project.approvals.set_approvals() method used the /projects/:id/approvers end point. That end point was removed from GitLab in the 13.11 release, on 2-Apr-2021 in commit 27dc2f2fe81249bbdc25f7bd8fe799752aac05e6 via merge commit e482597a8cf1bae8e27abd6774b684fb90491835. It was deprecated on 19-Aug-2019.

See merge request: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/57473 (91f08f0)

  • fix: use epic id instead of iid for epic notes (97cae38)

  • fix(cli): handle list response for json/yaml output

Handle the case with the CLI where a list response is returned from GitLab and json/yaml output is requested.

Add a functional CLI test to validate it works.

Closes: #2287 (9b88132)

  • fix: intermittent failure in test_merge_request_reset_approvals

Have been seeing intermittent failures in the test: tests/functional/api/test_merge_requests.py::test_merge_request_reset_approvals

Also saw a failure in: tests/functional/cli/test_cli_v4.py::test_accept_request_merge[subprocess]

Add a call to wait_for_sidekiq() to hopefully resolve the issues. (3dde36e)

Refactor#

  • refactor: pre-commit trigger from tox (6e59c12)

  • refactor: migrate legacy EE tests to pytest (88c2505)

  • refactor: pytest-docker fixtures (3e4781a)

  • refactor(deps): drop compose v1 dependency in favor of v2 (f825d70)

Test#

  • test: fix test_project_push_rules test

Make the test_project_push_rules test work. (8779cf6)

  • test: enable skipping tests per GitLab plan (01d5f68)

  • test: use false instead of /usr/bin/false

On Debian systems false is located at /bin/false (coreutils package). This fixes unit test failure on Debian system:

FileNotFoundError: [Errno 2] No such file or directory: ‘/usr/bin/false’ /usr/lib/python3.10/subprocess.py:1845: FileNotFoundError (51964b3)

Unknown#

  • Merge pull request #2345 from python-gitlab/jlvillal/enable_debug

docs: add minimal docs about the enable_debug() method (8f74a33)

  • Merge pull request #2343 from python-gitlab/feat/python-3-11

feat(build): officially support Python 3.11 (a3b4824)

  • Merge pull request #2341 from python-gitlab/renovate/maxbrunet-pre-commit-renovate-33.x

chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v33 (31a39e1)

  • Merge pull request #2320 from lmilbaum/refactoring

refactor: pre-commit triggered from tox (eec6c02)

  • Merge pull request #2333 from python-gitlab/jlvillal/remove_approvers_endpoint

fix: remove project.approvals.set_approvals() method (eb54adf)

  • Merge pull request #2332 from python-gitlab/jlvillal/fix_test

test: fix test_project_push_rules test (c676b43)

  • Merge pull request #2322 from AndreySV/fix-test-with-false

test: use false instead of /usr/bin/false (4eca9b9)

  • Merge pull request #2318 from python-gitlab/renovate/all-minor-patch

chore(deps): update all non-major dependencies (9410acb)

v3.10.0 (2022-09-28)#

Chore#

  • chore: bump GitLab docker image to 15.4.0-ee.0

  • Use settings.delayed_group_deletion=False as that is the recommended method to turn off the delayed group deletion now.

  • Change test to look for default as pages is not mentioned in the docs[1]

[1] https://docs.gitlab.com/ee/api/sidekiq_metrics.html#get-the-current-queue-metrics (b87a2bc)

  • chore(deps): update black to v22.8.0 (86b0e40)

  • chore(deps): update dependency types-requests to v2.28.10 (5dde7d4)

  • chore(deps): update dependency pytest to v7.1.3 (ec7f26c)

  • chore(deps): update dependency commitizen to v2.32.5 (e180f14)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.32.2 (31ba64f)

  • chore(deps): update dependency commitizen to v2.32.2 (31aea28)

Feature#

  • feat: Add reset_approvals api

Added the newly added reset_approvals merge request api.

Signed-off-by: Lucas Zampieri <lzampier@redhat.com> (88693ff)

Fix#

  • fix(cli): add missing attributes for creating MRs (1714d0a)

  • fix(cli): add missing attribute for MR changes (20c46a0)

Unknown#

  • Merge pull request #2280 from python-gitlab/jlvillal/docker_image

chore: bump GitLab docker image to 15.4.0-ee.0 (fceeebc)

  • Merge pull request #2261 from python-gitlab/renovate/commitizen-2.x

chore(deps): update dependency commitizen to v2.32.2 (336ee21)

  • Merge pull request #2262 from python-gitlab/renovate/commitizen-tools-commitizen-2.x

chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.32.2 (89bf581)

  • Merge pull request #2254 from python-gitlab/jlvillal/deploy_approve

feat: add support for deployment approval endpoint (56fbe02)

v3.9.0 (2022-08-28)#

Chore#

  • chore: Only check for our UserWarning

The GitHub CI is showing a ResourceWarning, causing our test to fail.

Update test to only look for our UserWarning which should not appear.

What was seen when debugging the GitHub CI: {message: ResourceWarning( “unclosed <socket.socket fd=12, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=(‘127.0.0.1’, 50862), raddr=(‘127.0.0.1’, 8080)>” ), category: ‘ResourceWarning’, filename: ‘/home/runner/work/python-gitlab/python-gitlab/.tox/api_func_v4/lib/python3.10/site-packages/urllib3/poolmanager.py’, lineno: 271, line: None } (bd4dfb4)

  • chore: fix issue if only run test_gitlab.py func test

Make it so can run just the test_gitlab.py functional test.

For example: $ tox -e api_func_v4 – -k test_gitlab.py (98f1956)

  • chore(ci): make pytest annotations work (f67514e)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.32.1 (cdd6efe)

  • chore(deps): update dependency commitizen to v2.32.1 (9787c5c)

  • chore(deps): update dependency types-requests to v2.28.9 (be932f6)

  • chore(deps): update dependency types-setuptools to v64 (4c97f26)

  • chore(deps): update pre-commit hook pycqa/flake8 to v5 (835d884)

  • chore(deps): update dependency types-requests to v2.28.8 (8e5b86f)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.31.0 (71d37d9)

  • chore(deps): update dependency commitizen to v2.31.0 (4ff0894)

Feature#

  • feat: add support for deployment approval endpoint

Add support for the deployment approval endpoint[1]

[1] https://docs.gitlab.com/ee/api/deployments.html#approve-or-reject-a-blocked-deployment Closes: #2253 (9c9eeb9)

  • feat: add support for merge_base API (dd4fbd5)

Unknown#

  • Merge pull request #2255 from python-gitlab/jlvillal/noop

chore: fix issue if only run test_gitlab.py func test (e095735)

  • Merge pull request #2241 from python-gitlab/renovate/pycqa-flake8-5.x

chore(deps): update pre-commit hook pycqa/flake8 to v5 (13d4927)

  • Merge pull request #2239 from python-gitlab/renovate/commitizen-tools-commitizen-2.x

chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.31.0 (9381a44)

  • Merge pull request #2238 from python-gitlab/renovate/commitizen-2.x

chore(deps): update dependency commitizen to v2.31.0 (b432e47)

v3.8.1 (2022-08-10)#

Chore#

  • chore(deps): update dependency commitizen to v2.29.5 (181390a)

  • chore(deps): update dependency flake8 to v5.0.4 (50a4fec)

  • chore(deps): update dependency sphinx to v5 (3f3396e)

  • chore: remove broad Exception catching from config.py

Change “except Exception:” catching to more granular exceptions.

A step in enabling the “broad-except” check in pylint. (0abc90b)

  • chore: add license badge to readme (9aecc9e)

  • chore: consolidate license and authors (366665e)

Fix#

  • fix(client): do not assume user attrs returned for auth()

This is mostly relevant for people mocking the API in tests. (a07547c)

Unknown#

  • Merge pull request #2233 from python-gitlab/fix/do-not-require-web-url (99d580a)

  • Merge pull request #2153 from python-gitlab/renovate/sphinx-5.x

chore(deps): update dependency sphinx to v5 (1e12eaf)

  • Merge pull request #2212 from python-gitlab/jlvillal/config

chore: remove broad Exception catching from config.py (70e67bf)

v3.8.0 (2022-08-04)#

Chore#

  • chore: use urlunparse instead of string replace

Use the urlunparse() function to reconstruct the URL without the query parameters. (6d1b62d)

  • chore(ci): bump semantic-release for fixed commit parser (1e063ae)

  • chore: enable mypy check disallow_any_generics (24d17b4)

  • chore: enable mypy check no_implicit_optional (64b208e)

  • chore(deps): update dependency types-requests to v2.28.6 (54dd4c3)

  • chore(deps): update dependency flake8 to v5 (cdc384b)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.29.2 (4988c02)

  • chore(deps): update dependency commitizen to v2.29.2 (30274ea)

  • chore: change _repr_attr for Project to be path_with_namespace

Previously _repr_attr was path but that only gives the basename of the path. So https://gitlab.com/gitlab-org/gitlab would only show “gitlab”. Using path_with_namespace it will now show “gitlab-org/gitlab” (7cccefe)

  • chore: make code PEP597 compliant

Use encoding=&#34;utf-8&#34; in open() and open-like functions.

https://peps.python.org/pep-0597/ (433dba0)

  • chore: enable mypy check warn_return_any

Update code so that the warn_return_any check passes. (76ec4b4)

  • chore(clusters): deprecate clusters support

Cluster support was deprecated in GitLab 14.5 [1]. And disabled by default in GitLab 15.0 [2]

  • Update docs to mark clusters as deprecated

  • Remove testing of clusters

[1] https://docs.gitlab.com/ee/api/project_clusters.html [2] https://gitlab.com/groups/gitlab-org/configure/-/epics/8 (b46b379)

  • chore(topics): ‘title’ is required when creating a topic

In GitLab >= 15.0 title is required when creating a topic. (271f688)

Documentation#

  • docs: describe self-revoking personal access tokens (5ea48fc)

Feature#

  • feat(client): warn user on misconfigured URL in auth() (0040b43)

  • feat: Support downloading archive subpaths (cadb0e5)

Fix#

  • fix(client): ensure encoded query params are never duplicated (1398426)

  • fix: optionally keep user-provided base URL for pagination (#2149) (e2ea8b8)

Refactor#

  • refactor(client): factor out URL check into a helper (af21a18)

  • refactor(client): remove handling for incorrect link header

This was a quirk only present in GitLab 13.0 and fixed with 13.1. See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/33714 and https://gitlab.com/gitlab-org/gitlab/-/issues/218504 for more context. (77c04b1)

Test#

  • test(unit): reproduce duplicate encoded query params (6f71c66)

  • test: attempt to make functional test startup more reliable

The functional tests have been erratic. Current theory is that we are starting the tests before the GitLab container is fully up and running.

  • Add checking of the Health Check[1] endpoints.

  • Add a 20 second delay after we believe it is up and running.

  • Increase timeout from 300 to 400 seconds

[1] https://docs.gitlab.com/ee/user/admin_area/monitoring/health_check.html (67508e8)

Unknown#

  • Merge pull request #2221 from python-gitlab/jlvillal/unparse

chore: use urlunparse instead of string replace (9e0b60f)

  • Merge pull request #2219 from python-gitlab/fix/no-duplicate-params

fix(client): ensure encoded query params are never duplicated (d263f57)

  • Merge pull request #2220 from python-gitlab/chore/bump-semantic-release

chore(ci): bump semantic-release for fixed commit parser (2ebfc70)

  • Merge pull request #2211 from python-gitlab/jlvillal/mypy_step_step

chore: enable mypy check disallow_any_generics (1136b17)

  • Merge pull request #2208 from python-gitlab/renovate/commitizen-tools-commitizen-2.x

chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.29.2 (6cedbc8)

  • Merge pull request #2210 from python-gitlab/jlvillal/mypy_step_by_step

chore: enable mypy check no_implicit_optional (1c91b24)

  • Merge pull request #2209 from python-gitlab/renovate/flake8-5.x

chore(deps): update dependency flake8 to v5 (d81cec3)

  • Merge pull request #2203 from python-gitlab/jlvillal/project_repr

chore: change _repr_attr for Project to be path_with_namespace (98bdb98)

  • Merge pull request #2188 from python-gitlab/jlvillal/fix_functional_ci

test: attempt to make functional test startup more reliable (17414f7)

  • Merge pull request #2199 from orf/patch-1

Support downloading archive subpaths (5e1df65)

  • Merge pull request #2157 from python-gitlab/jlvillal/mypy_step_by_step

chore: enable mypy check warn_return_any (b8be32a)

  • Merge pull request #2201 from python-gitlab/jlvillal/encoding_warning

chore: make code PEP597 compliant (1b7cd31)

  • Merge pull request #2194 from python-gitlab/jlvillal/update-gitlab

test(functional): bump GitLab docker image to 15.2.0-ee.0 (7a53c69)

v3.7.0 (2022-07-28)#

Chore#

  • chore: revert “test(functional): simplify token creation”

This reverts commit 67ab24fe5ae10a9f8cc9122b1a08848e8927635d. (4b798fc)

  • chore: enable using GitLab EE in functional tests

Enable using GitLab Enterprise Edition (EE) in the functional tests. This will allow us to add functional tests for EE only features in the functional tests. (17c01ea)

  • chore(deps): update dependency mypy to v0.971 (7481d27)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.29.0 (ad8d62a)

  • chore(deps): update typing dependencies (f2209a0)

  • chore(deps): update dependency commitizen to v2.29.0 (c365be1)

  • chore(authors): fix email and do the ABC (9833632)

  • chore: make reset_gitlab() better

Saw issues in the CI where reset_gitlab() would fail. It would fail to delete the group that is created when GitLab starts up. Extending the timeout didn’t fix the issue.

Changed the code to use the new helpers.safe_delete() function. Which will delete the resource and then make sure it is deleted before returning.

Also added some logging functionality that can be seen if logging is turned on in pytest. (d87d6b1)

  • chore: fixtures: after delete() wait to verify deleted

In our fixtures that create:

  • groups

  • project merge requests

  • projects

  • users

They delete the created objects after use. Now wait to ensure the objects are deleted before continuing as having unexpected objects existing can impact some of our tests. (1f73b6b)

  • chore: add a lazy boolean attribute to RESTObject

This can be used to tell if a RESTObject was created using lazy=True.

Add a message to the AttributeError if attribute access fails for an instance created with lazy=True. (a7e8cfb)

  • chore: enable mypy check strict_equality

Enable the mypy strict_equality check. (a29cd6c)

  • chore: change name of API functional test to api_func_v4

The CLI test is cli_func_v4 and using api_func_v4 matches with that naming convention. (8cf5cd9)

  • chore(deps): update typing dependencies (e772248)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.14.5 (c75a1d8)

  • chore(deps): update dependency pylint to v2.14.5 (e153636)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.28.0 (d238e1b)

  • chore(deps): update dependency commitizen to v2.28.0 (8703dd3)

  • chore(deps): update black to v22.6.0 (82bd596)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.14.4 (5cd39be)

  • chore(ci_lint): add create attributes (6e1342f)

  • chore(deps): update dependency requests to v2.28.1 (be33245)

  • chore(deps): update dependency pylint to v2.14.4 (2cee2d4)

  • chore: simplify multi-nested try blocks

Instead of have a multi-nested series of try blocks. Convert it to a more readable series of if statements. (e734470)

  • chore(docs): convert tabs to spaces

Some tabs snuck into the documentation. Convert them to 4-spaces. (9ea5520)

Documentation#

  • docs(cli): showcase use of token scopes (4a6f8d6)

  • docs(projects): document export with upload to URL (03f5484)

  • docs: describe fetching existing export status (9c5b8d5)

  • docs(authors): add John (e2afb84)

  • docs: document CI Lint usage (d5de4b1)

  • docs(users): add docs about listing a user’s projects

Add docs about listing a user’s projects.

Update docs on the membership API to update the URL to the upstream docs and also add a note that it requires Administrator access to use. (065a1a5)

  • docs: update return type of pushrules

Update the return type of pushrules to surround None with back-ticks to make it code-formatted. (53cbecc)

  • docs: describe ROPC flow in place of password authentication (91c17b7)

  • docs(readme): Remove redundant -v that breaks the command Remove redundant -v that breaks the command (c523e18)

Feature#

  • feat: allow sort/ordering for project releases

See: https://docs.gitlab.com/ee/api/releases/#list-releases (b1dd284)

  • feat(cli): add a custom help formatter

Add a custom argparse help formatter that overrides the output format to list items vertically.

The formatter is derived from argparse.HelpFormatter with minimal changes.

Co-authored-by: John Villalovos <john@sodarock.com> Co-authored-by: Nejc Habjan <nejc.habjan@siemens.com> (005ba93)

  • feat: add support for iterations API (194ee01)

  • feat(groups): add support for shared projects API (66461ba)

  • feat(issues): add support for issue reorder API (8703324)

  • feat(namespaces): add support for namespace existence API (4882cb2)

  • feat: add support for group and project invitations API (7afd340)

  • feat(projects): add support for project restore API (4794ecc)

  • feat: add support for filtering jobs by scope

See: ‘scope’ here: https://docs.gitlab.com/ee/api/jobs.html#list-project-jobs (0e1c0dd)

  • feat: add asdict() and to_json() methods to Gitlab Objects

Add an asdict() method that returns a dictionary representation copy of the Gitlab Object. This is a copy and changes made to it will have no impact on the Gitlab Object.

The asdict() method name was chosen as both the dataclasses and attrs libraries have an asdict() function which has the similar purpose of creating a dictionary represenation of an object.

Also add a to_json() method that returns a JSON string representation of the object.

Closes: #1116 (08ac071)

  • feat(api): add support for instance-level registry repositories (284d739)

  • feat(groups): add support for group-level registry repositories (70148c6)

  • feat: Add ‘merge_pipelines_enabled’ project attribute

Boolean. Enable or disable merge pipelines.

See: https://docs.gitlab.com/ee/api/projects.html#edit-project https://docs.gitlab.com/ee/ci/pipelines/merged_results_pipelines.html (fc33c93)

  • feat: support validating CI lint results (3b1ede4)

  • feat(cli): add support for global CI lint (3f67c4b)

  • feat(objects): add Project CI Lint support

Add support for validating a project’s CI configuration [1]

[1] https://docs.gitlab.com/ee/api/lint.html (b213dd3)

  • feat: add support for group push rules

Add the GroupPushRules and GroupPushRulesManager classes.

Closes: #1259 (b5cdc09)

  • feat(api): add support for get for a MR approval rule

In GitLab 14.10 they added support to get a single merge request approval rule [1]

Add support for it to ProjectMergeRequestApprovalRuleManager

[1] https://docs.gitlab.com/ee/api/merge_request_approvals.html#get-a-single-merge-request-level-rule (89c18c6)

Fix#

  • fix: support array types for most resources (d9126cd)

  • fix: use the [] after key names for array variables in params

  1. If a value is of type ArrayAttribute then append ‘[]’ to the name of the value for query parameters (params).

This is step 3 in a series of steps of our goal to add full support for the GitLab API data types[1]:

  • array

  • hash

  • array of hashes

Step one was: commit 5127b1594c00c7364e9af15e42d2e2f2d909449b Step two was: commit a57334f1930752c70ea15847a39324fa94042460

Fixes: #1698

[1] https://docs.gitlab.com/ee/api/#encoding-api-parameters-of-array-and-hash-types (1af44ce)

  • fix(runners): fix listing for /runners/all (c6dd57c)

  • fix(config): raise error when gitlab id provided but no config section found (1ef7018)

  • fix(config): raise error when gitlab id provided but no config file found (ac46c1c)

  • fix: add get_all param (and --get-all) to allow passing all to API (7c71d5d)

  • fix: results returned by attributes property to show updates

Previously the attributes method would show the original values in a Gitlab Object even if they had been updated. Correct this so that the updated value will be returned.

Also use copy.deepcopy() to ensure that modifying the dictionary returned can not also modify the object. (e5affc8)

  • fix: Enable epic notes

Add the notes attribute to GroupEpic (5fc3216)

  • fix(cli): remove irrelevant MR approval rule list filters (0daec5f)

  • fix: ensure path elements are escaped

Ensure the path elements that are passed to the server are escaped. For example a “/” will be changed to “%2F”

Closes: #2116 (5d9c198)

Refactor#

  • refactor: migrate services to integrations (a428051)

  • refactor(objects): move ci lint to separate file (6491f1b)

  • refactor(test-projects): apply suggestions and use fixtures (a51f848)

Test#

  • test(cli): add tests for token scopes (263fe3d)

  • test: add test to show issue fixed

https://github.com/python-gitlab/python-gitlab/issues/1698 has been fixed. Add test to show that. (75bec7d)

  • test(functional): bump GitLab docker image to 15.2.0-ee.0

Use the GitLab docker image 15.2.0-ee.0 in the functional testing. (69014e9)

  • test: always ensure clean config environment (8d4f13b)

  • test(ee): add an EE specific test (10987b3)

  • test(functional): simplify token creation (67ab24f)

  • test: fix broken test if user had config files

Use monkeypatch to ensure that no config files are reported for the test.

Closes: #2172 (864fc12)

  • test: allow podman users to run functional tests

Users of podman will likely have DOCKER_HOST set to something like unix:///run/user/1000/podman/podman.sock

Pass this environment variable so that it will be used during the functional tests. (ff215b7)

  • test(api_func_v4): catch deprecation warning for gl.lint()

Catch the deprecation warning for the call to gl.lint(), so it won’t show up in the log. (95fe924)

  • test(functional): use both get_all and all in list() tests (201298d)

  • test: add more tests for container registries (f6b6e18)

  • test(functional): replace len() calls with list membership checks (97e0eb9)

Unknown#

  • Merge pull request #2198 from nickbroon/nickbroon-release-sort-order

feat: allow sort/ordering for project releases (c33cb20)

  • Merge pull request #2195 from python-gitlab/jlvillal/array_test

test: add test to show issue fixed (1cf5932)

  • Merge pull request #1699 from python-gitlab/jlvillal/arrays

fix: use the [] after key names for array variables in params (510ec30)

  • Merge pull request #1778 from python-gitlab/jlvillal/gitlab-ee

chore: enable using GitLab EE in functional tests (b661003)

  • Merge pull request #2184 from python-gitlab/renovate/commitizen-tools-commitizen-2.x

chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.29.0 (346cf76)

  • Merge pull request #2182 from python-gitlab/renovate/commitizen-2.x

chore(deps): update dependency commitizen to v2.29.0 (e2ca0b4)

  • Merge pull request #2173 from python-gitlab/jlvillal/config_test_fix

test: fix broken test if user had config files (1ecbc7c)

  • Merge pull request #2166 from python-gitlab/jlvillal/podman

test: allow podman users to run functional tests (0b02b95)

  • Merge pull request #1785 from python-gitlab/jlvillal/reset_gitlab

chore: make reset_gitlab() better (789ef81)

  • Merge pull request #1784 from python-gitlab/jlvillal/sidekiq

chore: fixtures: after delete() wait to verify deleted (916b1db)

  • Merge pull request #2163 from python-gitlab/jlvillal/lint_warning

test(api_func_v4): catch deprecation warning for gl.lint() (1855279)

  • Merge pull request #2161 from nickbroon/nickbroon-jobs_scope

feat: add support for filtering jobs by scope (0549afa)

  • Merge pull request #2160 from python-gitlab/docs-author-add-john

docs(authors): add John (ead9f15)

  • Merge pull request #1872 from python-gitlab/jlvillal/as_dict

feat: add asdict() and to_json() methods to Gitlab Objects (fcbced8)

  • Merge pull request #2082 from python-gitlab/jlvillal/mark_lazy_state

chore: add a lazy boolean attribute to RESTObject (2c90fd0)

  • Merge pull request #2146 from python-gitlab/jlvillal/mypy_strict_step_by_step

chore: enable mypy check strict_equality (c84379d)

  • Merge pull request #2147 from python-gitlab/jlvillal/api_func_v4

chore: change name of API functional test to api_func_v4 (ed110bd)

  • Merge pull request #2141 from nickbroon/nickbroon-merge_pipelines_enabled

feat: Add ‘merge_pipelines_enabled’ project attribute (e409811)

  • Merge pull request #2125 from python-gitlab/jlvillal/user_docs

docs(users): add docs about listing a user’s projects (1fbfb22)

  • Merge pull request #1896 from python-gitlab/jlvillal/ci_lint

feat: add Project CI Lint support (d15fea0)

  • Merge pull request #2126 from python-gitlab/jlvillal/push_rules

docs: update return type of pushrules (88a1535)

  • Merge pull request #1266 from gokeefe/gokeefe/group_push_rules

#1259 Add GroupPushRules and GroupPushRulesManager classes (768890a)

  • Merge pull request #2114 from python-gitlab/jlvillal/remove_trys

chore: simplify multi-nested try blocks (3df404c)

  • Merge pull request #2117 from python-gitlab/jlvillal/encodedid_path

fix: ensure path elements are escaped (04c6063)

  • Merge pull request #2113 from tuxiqae/patch-1

Remove redundant -v that breaks the command (ca3b438)

  • Merge pull request #2069 from antoineauger/test/unit-tests-projects

test(projects): add unit tests for projects (0e4db56)

  • Merge pull request #2110 from python-gitlab/jlvillal/mr_approval_rules

feat(api): add support for get for a MR approval rule (389e1e6)

  • Merge pull request #2111 from python-gitlab/jlvillal/meta_fix

chore: fix misspelling (6486566)

  • Merge pull request #2112 from python-gitlab/jlvillal/doc_remove_tabs

chore(docs): convert tabs to spaces (8771ad8)

v3.6.0 (2022-06-28)#

Chore#

  • chore(deps): ignore python-semantic-release updates (f185b17)

  • chore(workflows): explicitly use python-version (eb14475)

  • chore(deps): update typing dependencies (acc5c39)

  • chore(deps): update actions/setup-python action to v4 (77c1f03)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.14.3 (d1fe838)

  • chore(ci): increase timeout for docker container to come online

Have been seeing timeout issues more and more. Increase timeout from 200 seconds to 300 seconds (5 minutes). (bda020b)

  • chore(docs): ignore nitpicky warnings (1c3efb5)

  • chore: patch sphinx for explicit re-exports (06871ee)

  • chore: bump mypy pre-commit hook (0bbcad7)

  • chore(gitlab): fix implicit re-exports for mpypy (981b844)

  • chore: add link to Commitizen in Github workflow

Add a link to the Commitizen website in the Github workflow. Hopefully this will help people when their job fails. (d08d07d)

  • chore(deps): update dependency pylint to v2.14.3 (9a16bb1)

  • chore(deps): update pre-commit hook commitizen-tools/commitizen to v2.27.1 (22c5db4)

  • chore(deps): update dependency requests to v2.28.0 (d361f4b)

  • chore: fix issue found with pylint==2.14.3

A new error was reported when running pylint==2.14.3: gitlab/client.py:488:0: W1404: Implicit string concatenation found in call (implicit-str-concat)

Fixed this issue. (eeab035)

  • chore(deps): update dependency mypy to v0.961 (f117b2f)

  • chore(deps): update typing dependencies (aebf9c8)

  • chore(deps): update dependency mypy to v0.960 (8c016c7)

  • chore(cli): rename “object” to “GitLab resource”

Make the parser name more user friendly by renaming from generic “object” to “GitLab resource” (62e64a6)

  • chore: use multiple processors when running PyLint

Use multiple processors when running PyLint. On my system it took about 10.3 seconds to run PyLint before this change. After this change it takes about 5.8 seconds to run PyLint. (7f2240f)

  • chore: rename whaction and action to resource_action in CLI

Rename the variables whaction and action to resource_action to improve code-readability. (fb3f28a)

  • chore: enable pylint check: “redefined-outer-name”,

Enable the pylint check “redefined-outer-name” and fix the errors detected. (1324ce1)

  • chore: enable pylint check: “no-self-use”

Enable the pylint check “no-self-use” and fix the errors detected. (80aadaf)

  • chore: enable pylint check: “no-else-return”

Enable the pylint check “no-else-return” and fix the errors detected. (d0b0811)

  • chore: enable pylint check: “attribute-defined-outside-init”

Enable the pylint check: “attribute-defined-outside-init” and fix errors detected. (d6870a9)

  • chore: enable pylint check “raise-missing-from”

Enable the pylint check “raise-missing-from” and fix errors detected. (1a2781e)

  • chore: enable pylint checks which require no changes

Enabled the pylint checks that don’t require any code changes. Previously these checks were disabled. (50fdbc4)

  • chore: enable pylint checks

Enable the pylint checks:

  • unnecessary-pass

  • unspecified-encoding

Update code to resolve errors found (1e89164)

  • chore: rename what to gitlab_resource

Naming a variable what makes it difficult to understand what it is used for.

Rename it to gitlab_resource as that is what is being stored.

The Gitlab documentation talks about them being resources: https://docs.gitlab.com/ee/api/api_resources.html

This will improve code readability. (c86e471)

  • chore: rename __call__() to run() in GitlabCLI

Less confusing to have it be a normal method. (6189437)

  • chore: enable ‘consider-using-sys-exit’ pylint check

Enable the ‘consider-using-sys-exit’ pylint check and fix errors raised. (0afcc3e)

  • chore: require f-strings

We previously converted all string formatting to use f-strings. Enable pylint check to enforce this. (96e994d)

  • chore(ci): pin 3.11 to beta.1 (7119f2d)

  • chore(cli): ignore coverage on exceptions triggering cli.die (98ccc3c)

  • chore: move utils._validate_attrs inside types.RequiredOptional

Move the validate_attrs function to be inside the RequiredOptional class. It makes sense for it to be part of the class as it is working on data related to the class. (9d629bb)

  • chore: remove use of ‘%’ string formatter in gitlab/utils.py

Replace usage with f-string (0c5a121)

  • chore: have EncodedId creation always return EncodedId

There is no reason to return an int as we can always return a str version of the int

Change EncodedId to always return an EncodedId. This removes the need to have mypy ignore the error raised. (a1a246f)

  • chore: move RequiredOptional to the gitlab.types module

By having RequiredOptional in the gitlab.base module it makes it difficult with circular imports. Move it to the gitlab.types module which has no dependencies on any other gitlab module. (7d26530)

  • chore: update type-hints return signature for GetWithoutIdMixin methods

Commit f0152dc3cc9a42aa4dc3c0014b4c29381e9b39d6 removed situation where get() in a GetWithoutIdMixin based class could return None

Update the type-hints to no longer return Optional AKA None (aa972d4)

  • chore(deps): update dependency commitizen to v2.27.1 (456f9f1)

  • chore(deps): update typing dependencies (f3f79c1)

  • chore: correct ModuleNotFoundError() arguments

Previously in commit 233b79ed442aac66faf9eb4b0087ea126d6dffc5 I had used the name argument for ModuleNotFoundError(). This basically is the equivalent of not passing any message to ModuleNotFoundError(). So when the exception was raised it wasn’t very helpful.

Correct that and add a unit-test that shows we get the message we expect. (0b7933c)

  • chore(mixins): remove None check as http_get always returns value (f0152dc)

Documentation#

  • docs(api): add separate section for advanced usage (22ae101)

  • docs(api): document usage of head() methods (f555bfb)

  • docs(projects): provide more detailed import examples (8f8611a)

  • docs(projects): document 404 gotcha with unactivated integrations (522ecff)

  • docs(variables): instruct users to follow GitLab rules for values (194b6be)

  • docs(api): stop linking to python-requests.org (49c7e83)

  • docs(api): fix incorrect docs for merge_request_approvals (#2094)

  • docs(api): fix incorrect docs for merge_request_approvals

The set_approvers() method is on the ProjectApprovalManager class. It is not part of the ProjectApproval class.

The docs were previously showing to call set_approvers using a ProjectApproval instance, which would fail. Correct the documentation.

This was pointed out by a question on the Gitter channel.

Co-authored-by: Nejc Habjan <nejc.habjan@siemens.com> (5583eaa)

  • docs(api-usage): add import os in example (2194a44)

  • docs: drop deprecated setuptools build_sphinx (048d66a)

  • docs(usage): refer to upsteam docs instead of custom attributes (ae7d3b0)

  • docs(ext): fix rendering for RequiredOptional dataclass (4d431e5)

  • docs: documentation updates to reflect addition of mutually exclusive attributes (24b720e)

  • docs: use as_list=False or all=True in Getting started

In the “Getting started with the API” section of the documentation, use either as_list=False or all=True in the example usages of the list() method.

Also add a warning about the fact that list() by default does not return all items. (de8c6e8)

Feature#

  • feat(downloads): allow streaming downloads access to response iterator (#1956)

  • feat(downloads): allow streaming downloads access to response iterator

Allow access to the underlying response iterator when downloading in streaming mode by specifying iterator=True.

Update type annotations to support this change.

  • docs(api-docs): add iterator example to artifact download

Document the usage of the iterator=True option when downloading artifacts

  • test(packages): add tests for streaming downloads (b644721)

  • feat(api): support head() method for get and list endpoints (ce9216c)

  • feat(api): implement HEAD method (90635a7)

  • feat(users): add approve and reject methods to User

As requested in #1604.

Co-authored-by: John Villalovos <john@sodarock.com> (f57139d)

  • feat(api): convert gitlab.const to Enums

This allows accessing the elements by value, i.e.:

import gitlab.const gitlab.const.AccessLevel(20) (c3c6086)

  • feat: Add support for Protected Environments

  • https://docs.gitlab.com/ee/api/protected_environments.html

  • https://github.com/python-gitlab/python-gitlab/issues/1130

no write operation are implemented yet as I have no use case right now and am not sure how it should be done (1dc9d0f)

  • feat(users): add ban and unban methods (0d44b11)

  • feat(docker): provide a Debian-based slim image (384031c)

  • feat: support mutually exclusive attributes and consolidate validation to fix board lists (#2037)

add exclusive tuple to RequiredOptional data class to support for mutually exclusive attributes

consolidate _check_missing_create_attrs and _check_missing_update_attrs from mixins.py into _validate_attrs in utils.py

change _create_attrs in board list manager classes from required=(‘label_ld’,) to exclusive=(‘label_id’,’asignee_id’,’milestone_id’)

closes https://github.com/python-gitlab/python-gitlab/issues/1897 (3fa330c)

  • feat(client): introduce iterator=True and deprecate as_list=False in list()

as_list=False is confusing as it doesn’t explain what is being returned. Replace it with iterator=True which more clearly explains to the user that an iterator/generator will be returned.

This maintains backward compatibility with as_list but does issue a DeprecationWarning if as_list is set. (cdc6605)

Fix#

  • fix(base): do not fail repr() on lazy objects (1efb123)

  • fix(cli): project-merge-request-approval-rule

Using the CLI the command: gitlab project-merge-request-approval-rule list –mr-iid 1 –project-id foo/bar

Would raise an exception. This was due to the fact that _id_attr and _repr_attr were set for keys which are not returned in the response.

Add a unit test which shows the repr function now works. Before it did not.

This is an EE feature so we can’t functional test it.

Closes: #2065 (15a242c)

  • fix(cli): fix project export download for CLI

Since ac1c619cae6481833f5df91862624bf0380fef67 we delete parent arg keys from the args dict so this has been trying to access the wrong attribute. (5d14867)

Refactor#

  • refactor: do not recommend plain gitlab.const constants (d652133)

  • refactor: avoid possible breaking change in iterator (#2107)

Commit b6447211754e126f64e12fc735ad74fe557b7fb4 inadvertently introduced a possible breaking change as it added a new argument iterator and added it in between existing (potentially positional) arguments.

This moves the iterator argument to the end of the argument list and requires it to be a keyword-only argument. (212ddfc)

  • refactor: remove no-op id argument in GetWithoutIdMixin (0f2a602)

  • refactor(test-projects): remove test_restore_project (9be0875)

  • refactor(mixins): extract custom type transforms into utils (09b3b22)

Test#

  • test: add tests and clean up usage for new enums (323ab3c)

  • test(pylint): enable pylint “unused-argument” check

Enable the pylint “unused-argument” check and resolve issues it found.

  • Quite a few functions were accepting **kwargs but not then passing them on through to the next level. Now pass **kwargs to next level.

  • Other functions had no reason to accept **kwargs, so remove it

  • And a few other fixes. (23feae9)

  • test(api): add tests for HEAD method (b0f02fa)

  • test(projects): add unit tests for projects (67942f0)

  • test: move back to using latest Python 3.11 version (8c34781)

  • test: increase client coverage (00aec96)

  • test: add more tests for RequiredOptional (ce40fde)

  • test(cli): improve coverage for custom actions (7327f78)

  • test(gitlab): increase unit test coverage (df072e1)

Unknown#

  • Merge pull request #2105 from python-gitlab/renovate/actions-setup-python-4.x

chore(deps): update actions/setup-python action to v4 (ebd5795)

  • Merge pull request #2100 from python-gitlab/jlvillal/pylint_2022-06-26

test(pylint): enable pylint “unused-argument” check (3c3f865)

  • Merge pull request #2061 from bgamari/patch-1

feat(users): add approve and reject methods to User (f9b7c7b)

  • Merge pull request #2089 from python-gitlab/jlvillal/more_time

chore(ci): increase timeout for docker container to come online (a825844)

  • Merge pull request #1688 from jspricke/enum

feat(api): Convert gitlab.const to Enums (f0ac3cd)

  • Merge pull request #2084 from calve/protected-environments

feat: Add support for Protected Environments (1feabc0)

  • Merge pull request #2083 from python-gitlab/jlvillal/cz

chore: add link to Commitizen in Github workflow (8342f53)

  • Merge pull request #2066 from python-gitlab/jlvillal/approval_rule_id

fix(cli): project-merge-request-approval-rule (41ceaca)

  • Merge pull request #2076 from python-gitlab/renovate/pylint-2.x

chore(deps): update dependency pylint to v2.14.3 (e48ad91)

  • Merge pull request #2077 from python-gitlab/jlvillal/pylint

chore: fix issue found with pylint==2.14.3 (8e0cd8b)

  • Merge pull request #2064 from antoineauger/feat/user-ban-unban

feat(users): add ban and unban methods (ca98d88)

  • Merge pull request #2057 from walterrowe/main

docs: update docs to reflect addition of mutually exclusive attributes (0f607f6)

  • Merge pull request #2055 from python-gitlab/jlvillal/resource

chore(cli): rename “object” to “GitLab resource” (0e3c461)

  • Merge pull request #2045 from python-gitlab/jlvillal/test_validate_attrs

test: add more tests for RequiredOptional (40c9b4f)

  • Merge pull request #2056 from python-gitlab/jlvillal/pylint_job

chore: use multiple processors when running PyLint (7b9bb3c)

  • Merge pull request #2051 from python-gitlab/jlvillal/more_more_pylint

chore: enable more pylint checks (7a5923c)

  • Merge pull request #2054 from python-gitlab/jlvillal/resource

chore: rename whaction and action to resource_action in CLI (61b8beb)

  • Merge pull request #2049 from python-gitlab/jlvillal/python_311

test: move back to using latest Python 3.11 version (6cdccd9)

  • Merge pull request #2053 from python-gitlab/jlvillal/resource

chore: rename what to gitlab_resource (8d30b15)

  • Merge pull request #2052 from python-gitlab/jlvillal/cli_minor_clean

chore: rename __call__() to run() in GitlabCLI (4eb5bad)

  • Merge pull request #2050 from python-gitlab/jlvillal/more_pylint

chore: enable ‘consider-using-sys-exit’ pylint check (9ab3c10)

  • Merge pull request #2043 from python-gitlab/jlvillal/f-string

chore: require f-strings (3d000d3)

  • Merge pull request #2042 from python-gitlab/jlvillal/exclusive

Clean-up the validate_attrs method/function (28cf3c3)

  • Merge pull request #2040 from python-gitlab/jlvillal/type_alias

chore: have EncodedId creation always return EncodedId (dea9435)

  • Merge pull request #2039 from python-gitlab/jlvillal/required_optional

chore: move RequiredOptional to the gitlab.types module (37eb8e0)

  • Merge pull request #2036 from python-gitlab/jlvillal/get_not_none

chore: update type-hints return signature for GetWithoutIdMixin methods (1f17349)

  • Merge pull request #2033 from python-gitlab/jlvillal/module_not_found_error

chore: correct ModuleNotFoundError() arguments (b2e6f3b)

  • Merge pull request #2034 from python-gitlab/renovate/typing-dependencies

chore(deps): update typing dependencies (38218e5)

  • Merge pull request #2035 from python-gitlab/renovate/commitizen-2.x

chore(deps): update dependency commitizen to v2.27.1 (91e60ba)

  • Merge pull request #2032 from python-gitlab/jlvillal/i_hate_as_list

feat(client): introduce iterator=True and deprecate as_list=False in list() (c51b538)

  • Merge pull request #1884 from python-gitlab/jlvillal/list_docs

docs: use as_list=False or all=True in Getting started (5ae18d0)

v3.5.0 (2022-05-28)#

Chore#

  • chore(ci): fix prefix for action version (1c02189)

  • chore(ci): pin semantic-release version (0ea61cc)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.9 (1e22790)

  • chore(deps): update dependency pylint to v2.13.9 (4224950)

  • chore: run the pylint check by default in tox

Since we require pylint to pass in the CI. Let’s run it by default in tox. (55ace1d)

  • chore: rename the test which runs flake8 to be flake8

Previously the test was called pep8. The test only runs flake8 so call it flake8 to be more precise. (78b4f99)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.8 (1835593)

  • chore(deps): update dependency pylint to v2.13.8 (b235bb0)

  • chore: add cz to default tox environment list and skip_missing_interpreters

Add the cz (comittizen) check by default.

Set skip_missing_interpreters = True so that when a user runs tox and doesn’t have a specific version of Python it doesn’t mark it as an error. (ba8c052)

  • chore: exclude build/ directory from mypy check

The build/ directory is created by the tox environment twine-check. When the build/ directory exists mypy will have an error. (989a12b)

  • chore(deps): update dependency types-requests to v2.27.25 (d6ea47a)

  • chore(ci): replace commitlint with commitizen (b8d15fe)

  • chore(renovate): set schedule to reduce noise (882fe7a)

  • chore(deps): update dependency types-requests to v2.27.24 (f88e3a6)

  • chore(deps): update dependency types-requests to v2.27.23 (a6fed8b)

Documentation#

  • docs: update issue example and extend API usage docs (aad71d2)

  • docs(CONTRIBUTING.rst): fix link to conventional-changelog commit format documentation (2373a4f)

  • docs: add missing Admin access const value

As shown here, Admin access is set to 60: https://docs.gitlab.com/ee/api/protected_branches.html#protected-branches-api (3e0d4d9)

  • docs(merge_requests): add new possible merge request state and link to the upstream docs

The actual documentation do not mention the locked state for a merge request (e660fa8)

Feature#

  • feat(objects): support get project storage endpoint (8867ee5)

  • feat: display human-readable attribute in repr() if present (6b47c26)

  • feat(ux): display project.name_with_namespace on project repr

This change the repr from:

$ gitlab.projects.get(id=some_id) <Project id:some_id>

To:

$ gitlab.projects.get(id=some_id) <Project id:some_id name_with_namespace:”group_name / project_name”>

This is especially useful when working on random projects or listing of projects since users generally don’t remember projects ids. (e598762)

Fix#

  • fix(cli): changed default allow_abbrev value to fix arguments collision problem (#2013)

fix(cli): change default allow_abbrev value to fix argument collision (d68cacf)

  • fix: duplicate subparsers being added to argparse

Python 3.11 added an additional check in the argparse libary which detected duplicate subparsers being added. We had duplicate subparsers being added.

Make sure we don’t add duplicate subparsers.

Closes: #2015 (f553fd3)

Test#

  • test(projects): add tests for list project methods (fa47829)

Unknown#

  • Merge pull request #2022 from MichaelSweikata/feat/documentation-update

docs: update issue example and extend API usage docs (792cee9)

  • Merge pull request #2012 from rnoberger/rnoberger/test-projects

test: increase projects coverage (fd9154e)

  • Merge pull request #2019 from python-gitlab/jlvillal/tox

Some improvements to our tox environment defaults (d121d2d)

  • Merge pull request #2018 from python-gitlab/renovate/pycqa-pylint-2.x

chore(deps): update pre-commit hook pycqa/pylint to v2.13.8 (9e64645)

  • Merge pull request #2017 from python-gitlab/renovate/pylint-2.x

chore(deps): update dependency pylint to v2.13.8 (0049f83)

  • Merge pull request #2014 from python-gitlab/jlvillal/python3.11beta1

fix: duplicate subparsers being added to argparse (7d5a0c9)

  • Merge pull request #1996 from Psycojoker/project-name-in-repr

feat(ux): display project.name_with_namespace on project repr (82c9a07)

  • Merge pull request #2008 from python-gitlab/jlvillal/mypy-tox

chore: exclude build/ directory from mypy check (d169983)

  • Merge pull request #2009 from python-gitlab/jlvillal/tox-env

chore: add cz to default tox environment list and skip_missing_interpreters (5cb2859)

  • Merge pull request #2005 from carlosduelo/patch-1

merge request can have state locked (ef207da)

  • Merge pull request #2001 from python-gitlab/renovate/typing-dependencies

chore(deps): update dependency types-requests to v2.27.25 (04e0d24)

  • Merge pull request #1994 from python-gitlab/renovate/typing-dependencies

chore(deps): update dependency types-requests to v2.27.24 (79b903d)

v3.4.0 (2022-04-28)#

Chore#

  • chore(deps): update dependency mypy to v0.950 (241e626)

  • chore(deps): update dependency types-requests to v2.27.22 (22263e2)

  • chore(deps): update dependency types-requests to v2.27.21 (0fb0955)

  • chore(deps): update dependency pytest to v7.1.2 (fd3fa23)

  • chore(deps): update typing dependencies (c12466a)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.7 (1396221)

  • chore(deps): update dependency pylint to v2.13.7 (5fb2234)

  • chore(deps): update typing dependencies (d27cc6a)

  • chore(deps): update dependency pylint to v2.13.5 (5709675)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.5 (17d5c6c)

  • chore(deps): update codecov/codecov-action action to v3 (292e91b)

  • chore(deps): update dependency types-setuptools to v57.4.12 (6551353)

  • chore(client): remove duplicate code (5cbbf26)

  • chore(deps): update dependency types-requests to v2.27.16 (ad799fc)

  • chore(deps): upgrade gitlab-ce to 14.9.2-ce.0 (d508b18)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.4 (9d0b252)

  • chore(deps): update dependency pylint to v2.13.4 (a9a9392)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.3 (8f0a3af)

  • chore(deps): update dependency pylint to v2.13.3 (0ae3d20)

  • chore(deps): update black to v22.3.0 (8d48224)

Documentation#

  • docs(api-docs): docs fix for application scopes (e1ad93d)

Feature#

  • feat: emit a warning when using a list() method returns max

A common cause of issues filed and questions raised is that a user will call a list() method and only get 20 items. As this is the default maximum of items that will be returned from a list() method.

To help with this we now emit a warning when the result from a list() method is greater-than or equal to 20 (or the specified per_page value) and the user is not using either all=True, all=False, as_list=False, or page=X. (1339d64)

  • feat(objects): support getting project/group deploy tokens by id (fcd37fe)

  • feat(user): support getting user SSH key by id (6f93c05)

  • feat(api): re-add topic delete endpoint

This reverts commit e3035a799a484f8d6c460f57e57d4b59217cd6de. (d1d96bd)

Fix#

  • fix: add ChunkedEncodingError to list of retryable exceptions (7beb20f)

  • fix: avoid passing redundant arguments to API (3431887)

  • fix(cli): add missing filters for project commit list (149d244)

  • fix: add 52x range to retry transient failures and tests (c3ef1b5)

  • fix: also retry HTTP-based transient errors (3b49e4d)

Unknown#

  • Merge pull request #1988 from python-gitlab/renovate/mypy-0.x

chore(deps): update dependency mypy to v0.950 (0c0035e)

  • Merge pull request #1986 from python-gitlab/renovate/typing-dependencies

chore(deps): update dependency types-requests to v2.27.21 (ab8352e)

  • Merge pull request #1983 from python-gitlab/renovate/pytest-7.x

chore(deps): update dependency pytest to v7.1.2 (4a6bd90)

  • Merge pull request #1981 from python-gitlab/renovate/typing-dependencies

chore(deps): update typing dependencies (cf2953e)

  • Merge pull request #1980 from python-gitlab/renovate/pycqa-pylint-2.x

chore(deps): update pre-commit hook pycqa/pylint to v2.13.7 (0305979)

  • Merge pull request #1979 from python-gitlab/renovate/pylint-2.x

chore(deps): update dependency pylint to v2.13.7 (396e30c)

  • Merge pull request #1965 from python-gitlab/fix/redundant-args-api

fix: avoid passing redundant arguments to API (ba7692a)

  • Merge pull request #1974 from Sineaggi/add-chunked-to-list-of-retryable-exceptions

Add ChunkedEncodingError to list of retryable exceptions (07a16af)

  • Merge pull request #1963 from python-gitlab/feat/deploy-token-get

feat(objects): support getting project/group deploy tokens by id (69ace2d)

  • Merge pull request #1962 from python-gitlab/feat/user-ssh-key

feat(user): support getting user SSH key by id (68bf5d8)

  • Merge pull request #1875 from python-gitlab/jlvillal/list_warning

feat: emit a warning when using a list() method returns max (4d6f125)

  • Merge pull request #1971 from python-gitlab/renovate/pycqa-pylint-2.x

chore(deps): update pre-commit hook pycqa/pylint to v2.13.5 (5370979)

  • Merge pull request #1964 from python-gitlab/fix/missing-commit-list-filters

fix(cli): add missing filters for project commit list (3b0806e)

  • Merge pull request #1968 from python-gitlab/renovate/codecov-codecov-action-3.x

chore(deps): update codecov/codecov-action action to v3 (de8cfd9)

  • Merge pull request #1967 from python-gitlab/renovate/typing-dependencies

chore(deps): update dependency types-setuptools to v57.4.12 (3be5ac2)

  • Merge pull request #1904 from Sineaggi/retry-additional-http-transient-errors

Retry additional http transient errors (0353bd4)

  • Merge pull request #1961 from python-gitlab/renovate/typing-dependencies

chore(deps): update dependency types-requests to v2.27.16 (19ab07d)

  • Merge pull request #1959 from python-gitlab/renovate/pycqa-pylint-2.x

chore(deps): update pre-commit hook pycqa/pylint to v2.13.4 (8db6841)

  • Merge pull request #1958 from python-gitlab/renovate/pylint-2.x

chore(deps): update dependency pylint to v2.13.4 (400d8e5)

  • Merge pull request #1951 from wacuuu/main

docs: small docs fix-up for application scopes (8e241e4)

  • Merge pull request #1954 from python-gitlab/renovate/pycqa-pylint-2.x

chore(deps): update pre-commit hook pycqa/pylint to v2.13.3 (eee173e)

  • Merge pull request #1953 from python-gitlab/renovate/pylint-2.x

chore(deps): update dependency pylint to v2.13.3 (5498f9e)

  • Merge pull request #1952 from python-gitlab/renovate/black

chore(deps): update black to v22.3.0 (f942e65)

v3.3.0 (2022-03-28)#

Chore#

  • chore(deps): update dependency sphinx to v4.5.0 (36ab769)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.2 (14d367d)

  • chore(deps): update dependency pylint to v2.13.2 (10f15a6)

  • chore(deps): update dependency types-requests to v2.27.15 (2e8ecf5)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.1 (1d0c6d4)

  • chore(deps): update dependency types-requests to v2.27.14 (be6b54c)

  • chore(deps): update dependency pylint to v2.13.1 (eefd724)

  • chore(deps): update pre-commit hook pycqa/pylint to v2.13.0 (9fe60f7)

  • chore(deps): update dependency pylint to v2.13.0 (5fa403b)

  • chore(deps): update dependency mypy to v0.942 (8ba0f8c)

  • chore(deps): update dependency pytest-console-scripts to v1.3.1 (da392e3)

  • chore(deps): update dependency pytest to v7.1.1 (e31f2ef)

  • chore(deps): update typing dependencies (21e7c37)

  • chore(deps): update dependency mypy to v0.941 (3a9d4f1)

  • chore(deps): update dependency pytest to v7.1.0 (27c7e33)

  • chore(deps): update dependency types-requests to v2.27.12 (8cd668e)

  • chore(deps): update dependency mypy to v0.940 (dd11084)

  • chore(deps): update dependency types-setuptools to v57.4.10 (b37fc41)

  • chore(deps): update dependency pytest to v7 (ae8d70d)

  • chore(deps): update actions/upload-artifact action to v3 (18a0eae)

  • chore(deps): update actions/stale action to v5 (d841185)

  • chore(deps): update actions/setup-python action to v3 (7f845f7)

  • chore(deps): update pre-commit hook alessandrojcm/commitlint-pre-commit-hook to v8 (5440780)

  • chore(deps): update black to v22 (3f84f1b)

  • chore(deps): update dependency sphinx to v4.4.0 (425d161)

  • chore(deps): update actions/checkout action to v3 (7333cbb)

  • chore(deps): update dependency pytest-console-scripts to v1.3 (9c202dd)

  • chore(deps): update dependency mypy to v0.931 (33646c1)

  • chore(deps): update typing dependencies (37a7c40)

  • chore(deps): update dependency requests to v2.27.1 (95dad55)

Documentation#

  • docs: fix typo and incorrect style (2828b10)

  • docs: add pipeline test report summary support (d78afb3)

  • docs(chore): include docs .js files in sdist (3010b40)

Feature#

  • feat(object): add pipeline test report summary support (a97e0cf)

Style#

  • style: reformat for black v22 (93d4403)

Unknown#

  • Merge pull request #1947 from python-gitlab/renovate/typing-dependencies

chore(deps): update dependency types-requests to v2.27.15 (59ae16c)

  • Merge pull request #1895 from python-gitlab/jlvillal/rate-limit

fix: support RateLimit-Reset header (114958e)

  • Merge pull request #1905 from derekschrock/docs-static

docs(chore): Include docs .js files in sdist (363bc87)

  • Merge pull request #1917 from python-gitlab/renovate/major-black

chore(deps): update black to v22 (major) (a4e76eb)

  • Merge pull request #1919 from python-gitlab/renovate/alessandrojcm-commitlint-pre-commit-hook-8.x

chore(deps): update pre-commit hook alessandrojcm/commitlint-pre-commit-hook to v8 (71ebee4)

  • Merge pull request #1915 from kinbald/test-report-summary

feat: add support for test report summary (7966584)

v3.2.0 (2022-02-28)#

Chore#

  • chore: create a custom warnings.warn wrapper

Create a custom warnings.warn wrapper that will walk the stack trace to find the first frame outside of the gitlab/ path to print the warning against. This will make it easier for users to find where in their code the error is generated from (6ca9aa2)

  • chore: correct type-hints for per_page attrbute

There are occasions where a GitLab list() call does not return the x-per-page header. For example the listing of custom attributes.

Update the type-hints to reflect that. (e825653)

  • chore: require kwargs for utils.copy_dict()

The non-keyword arguments were a tiny bit confusing as the destination was first and the source was second.

Change the order and require key-word only arguments to ensure we don’t silently break anyone. (7cf35b2)

  • chore: create new ArrayAttribute class

Create a new ArrayAttribute class. This is to indicate types which are sent to the GitLab server as arrays https://docs.gitlab.com/ee/api/#array

At this stage it is identical to the CommaSeparatedListAttribute class but will be used later to support the array types sent to GitLab.

This is the second step in a series of steps of our goal to add full support for the GitLab API data types[1]:

  • array

  • hash

  • array of hashes

Step one was: commit 5127b1594c00c7364e9af15e42d2e2f2d909449b

[1] https://docs.gitlab.com/ee/api/#encoding-api-parameters-of-array-and-hash-types

Related: #1698 (a57334f)

  • chore(ci): do not run release workflow in forks (2b6edb9)

Documentation#

  • docs: enable gitter chat directly in docs (bd1ecdd)

  • docs: add delete methods for runners and project artifacts (5e711fd)

  • docs: add retry_transient infos

Co-authored-by: Nejc Habjan <hab.nejc@gmail.com> (bb1f054)

  • docs: add transient errors retry info (b7a1266)

  • docs(artifacts): deprecate artifacts() and artifact() methods (64d01ef)

  • docs: revert “chore: add temporary banner for v3” (#1864)

This reverts commit a349793307e3a975bb51f864b48e5e9825f70182.

Co-authored-by: Wadim Klincov <wadim.klincov@siemens.com> (7a13b9b)

Feature#

  • feat(merge_request_approvals): add support for deleting MR approval rules (85a734f)

  • feat(artifacts): add support for project artifacts delete API (c01c034)

  • feat(mixins): allow deleting resources without IDs (0717517)

  • feat(objects): add a complete artifacts manager (c8c2fa7)

Fix#

  • fix: support RateLimit-Reset header

Some endpoints are not returning the Retry-After header when rate-limiting occurrs. In those cases use the RateLimit-Reset [1] header, if available.

Closes: #1889

[1] https://docs.gitlab.com/ee/user/admin_area/settings/user_and_ip_rate_limits.html#response-headers (4060146)

  • fix(services): use slug for id_attr instead of custom methods (e30f39d)

  • fix: remove custom delete method for labels

The usage of deleting was incorrect according to the current API. Remove custom delete() method as not needed.

Add tests to show it works with labels needing to be encoded.

Also enable the test_group_labels() test function. Previously it was disabled.

Add ability to do a get() for group labels.

Closes: #1867 (0841a2a)

Style#

  • style(objects): add spacing to docstrings (700d25d)

Test#

  • test(unit): clean up MR approvals fixtures (0eb4f7f)

  • test(runners): add test for deleting runners by auth token (14b88a1)

  • test(functional): fix GitLab configuration to support pagination

When pagination occurs python-gitlab uses the URL provided by the GitLab server to use for the next request.

We had previously set the GitLab server configuraiton to say its URL was http://gitlab.test which is not in DNS. Set the hostname in the URL to http://127.0.0.1:8080 which is the correct URL for the GitLab server to be accessed while doing functional tests.

Closes: #1877 (5b7d00d)

  • test(services): add functional tests for services (2fea2e6)

  • test(objects): add tests for project artifacts (8ce0336)

Unknown#

  • Merge pull request #1882 from python-gitlab/jlvillal/custom_warn

chore: create a custom warnings.warn wrapper (5beda3b)

  • Merge pull request #1881 from python-gitlab/jlvillal/easy2

test(functional): fix GitLab configuration to support pagination (4cb7d92)

  • Merge pull request #1880 from python-gitlab/jlvillal/easy

chore: correct type-hints for per_page attrbute (5e19694)

  • Merge pull request #1876 from emirot/patch-1

docs: add transient errors retry info (9897c98)

  • Merge pull request #1871 from python-gitlab/jlvillal/copy_dict

chore: require kwargs for utils.copy_dict() (2adf31d)

  • Merge pull request #1868 from python-gitlab/jlvillal/delete_label

fix: remove custom delete method for labels (0ab0fc1)

  • Merge pull request #1866 from python-gitlab/jlvillal/arrays_2

chore: create new ArrayAttribute class (7646360)

v3.1.1 (2022-01-28)#

Chore#

  • chore: use dataclass for RequiredOptional (30117a3)

  • chore: remove redundant list comprehension (271cfd3)

  • chore: consistently use open() encoding and file descriptor (dc32d54)

  • chore: don’t explicitly pass args to super() (618267c)

  • chore: always use context manager for file IO (e8031f4)

  • chore: remove old-style classes (ae2a015)

  • chore: rename types.ListAttribute to types.CommaSeparatedListAttribute

This name more accurately describes what the type is. Also this is the first step in a series of steps of our goal to add full support for the GitLab API data types[1]:

  • array

  • hash

  • array of hashes

[1] https://docs.gitlab.com/ee/api/#encoding-api-parameters-of-array-and-hash-types (5127b15)

  • chore: rename gitlab/__version__.py -> gitlab/_version.py

It is confusing to have a gitlab/__version__.py because we also create a variable gitlab.__version__ which can conflict with gitlab/__version__.py.

For example in gitlab/const.py we have to know that gitlab.__version__ is a module and not the variable due to the ordering of imports. But in most other usage gitlab.__version__ is a version string.

To reduce confusion make the name of the version file gitlab/_version.py. (b981ce7)

  • chore: create return type-hints for get_id() & encoded_id

Create return type-hints for RESTObject.get_id() and RESTObject.encoded_id. Previously was saying they return Any. Be more precise in saying they can return either: None, str, or int. (0c3a1d1)

  • chore(tests): use method projects.transfer()

When doing the functional tests use the new function projects.transfer instead of the deprecated function projects.transfer_project() (e5af2a7)

Documentation#

  • docs: enhance release docs for CI_JOB_TOKEN usage (5d973de)

  • docs(changelog): add missing changelog items (01755fb)

Fix#

  • fix(cli): make ‘per_page’ and ‘page’ type explicit (d493a5e)

  • fix(cli): make ‘timeout’ type explicit (bbb7df5)

  • fix(cli): allow custom methods in managers (8dfed0c)

  • fix(objects): make resource access tokens and repos available in CLI (e0a3a41)

Style#

  • style: use f-strings where applicable (cfed622)

  • style: use literals to declare data structures (019a40f)

Test#

  • test: add a meta test to make sure that v4/objects/ files are imported

Add a test to make sure that all of the gitlab/v4/objects/ files are imported in gitlab/v4/objects/__init__.py (9c8c804)

  • test: convert usage of match_querystring to match

In the responses library the usage of match_querystring is deprecated. Convert to using match (d16e41b)

  • test: remove usage of httpmock library

Convert all usage of the httpmock library to using the responses library. (5254f19)

  • test: use ‘responses’ in test_mixins_methods.py

Convert from httmock to responses in test_mixins_methods.py

This leaves only one file left to convert (208da04)

Unknown#

  • Merge pull request #1862 from thomasgl-orange/cli-fix-timeout

fix(cli): make ‘timeout’, ‘per_page’ and ‘page’ type explicit (3fb4486)

  • Merge pull request #1858 from python-gitlab/jlvillal/attribute_rename

chore: rename types.ListAttribute to types.CommaSeparatedListAttribute (39e7435)

  • Merge pull request #1848 from python-gitlab/jlvillal/objects_imported

test: add a meta test to make sure that v4/objects/ files are imported (07539c9)

  • Merge pull request #1854 from MRigal/docs/small-releases-additions

Enhance releases API docs for CI_JOB_TOKEN usage (ff04900)

  • Merge pull request #1845 from python-gitlab/jlvillal/rm_httmock

Remove usage of httmock and clean up deprecations (ff4b1cc)

  • Merge pull request #1838 from python-gitlab/jlvillal/version_mv

chore: rename gitlab/__version__.py to gitlab/_version.py (8af403c)

  • Merge pull request #1843 from python-gitlab/jlvillal/rm_httmock

test: use ‘responses’ in test_mixins_methods.py (fe14dd5)

  • Merge pull request #1841 from python-gitlab/jlvillal/get_id

chore: create return type-hints for get_id() & encoded_id (1ac982a)

  • Merge pull request #1840 from python-gitlab/docs/missing-changelog-items

docs(changelog): add missing changelog items (a1dbe86)

  • Merge pull request #1839 from python-gitlab/jlvillal/catch_warnings

chore(tests): use method projects.transfer() (48b06a9)

v3.1.0 (2022-01-14)#

Chore#

  • chore(groups): use encoded_id for group path (868f243)

  • chore(objects): use self.encoded_id where applicable

Updated a few remaining usages of self.id to use self.encoded_id as for the most part we shouldn’t be using self.id

There are now only a few (4 lines of code) remaining uses of self.id, most of which seem that they should stay that way. (75758bf)

  • chore(objects): use self.encoded_id where could be a string

Updated a few remaining usages of self.id to use self.encoded_id where it could be a string value. (c3c3a91)

  • chore(projects): fix typing for transfer method

Co-authored-by: John Villalovos <john@sodarock.com> (0788fe6)

  • chore: ignore intermediate coverage artifacts (110ae91)

  • chore: replace usage of utils._url_encode() with utils.EncodedId()

utils.EncodedId() has basically the same functionalityy of using utils._url_encode(). So remove utils._url_encode() as we don’t need it. (b07eece)

  • chore: add EncodedId string class to use to hold URL-encoded paths

Add EncodedId string class. This class returns a URL-encoded string but ensures it will only URL-encode it once even if recursively called.

Also added some functional tests of ‘lazy’ objects to make sure they work. (a2e7c38)

  • chore: add pprint() and pformat() methods to RESTObject

This is useful in debugging and testing. As can easily print out the values from an instance in a more human-readable form. (d69ba04)

  • chore: add logging to tests/functional/conftest.py

I have found trying to debug issues in the functional tests can be difficult. Especially when trying to figure out failures in the CI running on Github.

Add logging to tests/functional/conftest.py to have a better understanding of what is happening during a test run which is useful when trying to troubleshoot issues in the CI. (a1ac9ae)

  • chore(docs): use admonitions consistently (55c67d1)

  • chore: fix functional test failure if config present

Previously c8256a5933d745f70c7eea0a7d6230b51bac0fbc was done to fix this but it missed two other failures. (c9ed3dd)

  • chore: fix missing comma

There was a missing comma which meant the strings were concatenated instead of being two separate strings. (7c59fac)

  • chore(dist): add docs *.md files to sdist

build_sphinx to fail due to setup.cfg warning-is-error (d9457d8)

  • chore: add a stale workflow

Use the stale action to close issues and pull-requests with no activity.

Issues: It will mark them as stale after 60 days and then close them once they have been stale for 15 days.

Pull-Requests: It will mark pull-requests as stale after 90 days and then close them once they have been stale for 15 days.

https://github.com/actions/stale

Closes: #1649 (2c036a9)

  • chore: add temporary banner for v3 (a349793)

Ci#

  • ci: don’t fail CI if unable to upload the code coverage data

If a CI job can’t upload coverage results to codecov.com it causes the CI to fail and code can’t be merged. (d5b3744)

Documentation#

  • docs: update project access token API reference link (73ae955)

  • docs(cli): make examples more easily navigable by generating TOC (f33c523)

Feature#

  • feat: add support for Groups API method transfer() (0007006)

  • feat(api): add project.transfer() and deprecate transfer_project() (259668a)

  • feat(api): return result from SaveMixin.save()

Return the new object data when calling SaveMixin.save().

Also remove check for None value when calling self.manager.update() as that method only returns a dictionary.

Closes: #1081 (e6258a4)

  • feat: add support for Group Access Token API

See https://docs.gitlab.com/ee/api/group_access_tokens.html (c01b7c4)

Fix#

  • fix(cli): add missing list filters for environments (6f64d40)

  • fix: use url-encoded ID in all paths

Make sure all usage of the ID in the URL path is encoded. Normally it isn’t an issue as most IDs are integers or strings which don’t contain a slash (‘/’). But when the ID is a string with a slash character it will break things.

Add a test case that shows this fixes wikis issue with subpages which use the slash character.

Closes: #1079 (12435d7)

  • fix(members): use new *All objects for *AllManager managers

Change it so that:

GroupMemberAllManager uses GroupMemberAll object ProjectMemberAllManager uses ProjectMemberAll object

Create GroupMemberAll and ProjectMemberAll objects that do not support any Mixin type methods. Previously we were using GroupMember and ProjectMember which support the save() and delete() methods but those methods will not work with objects retrieved using the /members/all/ API calls.

list() API calls: [1] GET /groups/:id/members/all GET /projects/:id/members/all

get() API calls: [2] GET /groups/:id/members/all/:user_id GET /projects/:id/members/all/:user_id

Closes: #1825 Closes: #848

[1] https://docs.gitlab.com/ee/api/members.html#list-all-members-of-a-group-or-project-including-inherited-and-invited-members [2] https://docs.gitlab.com/ee/api/members.html#get-a-member-of-a-group-or-project-including-inherited-and-invited-members (755e0a3)

  • fix(api): services: add missing lazy parameter

Commit 8da0b758c589f608a6ae4eeb74b3f306609ba36d added the lazy parameter to the services get() method but missed then using the lazy parameter when it called super(...).get(...)

Closes: #1828 (888f332)

  • fix: broken URL for FAQ about attribute-error-list

The URL was missing a ‘v’ before the version number and thus the page did not exist.

Previously the URL for python-gitlab 3.0.0 was: https://python-gitlab.readthedocs.io/en/3.0.0/faq.html#attribute-error-list

Which does not exist.

Change it to: https://python-gitlab.readthedocs.io/en/v3.0.0/faq.html#attribute-error-list add the ‘v’ ————————–^ (1863f30)

  • fix: remove custom URL encoding

We were using str.replace() calls to take care of URL encoding issues.

Switch them to use our utils._url_encode() function which itself uses urllib.parse.quote()

Closes: #1356 (3d49e5e)

  • fix: remove default arguments for mergerequests.merge()

The arguments should_remove_source_branch and merge_when_pipeline_succeeds are optional arguments. We should not be setting any default value for them.

https://docs.gitlab.com/ee/api/merge_requests.html#accept-mr

Closes: #1750 (8e589c4)

  • fix(cli): url-encode path components of the URL

In the CLI we need to make sure the components put into the path portion of the URL are url-encoded. Otherwise they will be interpreted as part of the path. For example can specify the project ID as a path, but in the URL it must be url-encoded or it doesn’t work.

Also stop adding the components of the path as query parameters in the URL.

Closes: #783 Closes: #1498 (ac1c619)

  • fix: change to http_list for some ProjectCommit methods

Fix the type-hints and use http_list() for the ProjectCommits methods:

  • diff()

  • merge_requests()

  • refs()

This will enable using the pagination support we have for lists.

Closes: #1805 Closes: #1231 (497e860)

Test#

  • test(groups): enable group transfer tests (57bb67a)

Unknown#

  • Merge pull request #1836 from python-gitlab/jlvillal/id_to_encodedid

chore(objects): use self.encoded_id where applicable (2c62d91)

  • Merge pull request #1835 from python-gitlab/jlvillal/id_to_encodedid

chore(objects): use self.encoded_id where could be a string (34110dd)

  • Merge pull request #1832 from python-gitlab/jlvillal/return_save

feat(api): return result from SaveMixin.save() (27e0742)

  • Merge pull request #1834 from python-gitlab/jlvillal/cover_no_fail

ci: don’t fail CI if unable to upload the code coverage data (da30753)

  • Merge pull request #1831 from python-gitlab/chore/ignore-coverage

chore: ignore intermediate coverage artifacts (8b14ff0)

  • Merge pull request #1819 from python-gitlab/jlvillal/encoded_id

fix: use url-encoded ID in all paths (bc48840)

  • Merge pull request #1827 from python-gitlab/jlvillal/all_objects

fix: members: use new *All objects for *AllManager managers (58e5b25)

  • Merge pull request #1829 from python-gitlab/jlvillal/lazy_service

fix(api): services: add missing lazy parameter (824151c)

  • Merge pull request #1823 from python-gitlab/jlvillal/fix_url

fix: broken URL for FAQ about attribute-error-list (4a000b6)

  • Merge pull request #1812 from python-gitlab/jlvillal/pprint

chore: add pprint() and pformat() methods to RESTObject (bdc19b1)

  • Merge pull request #1786 from python-gitlab/jlvillal/logging

test: add logging to tests/functional/conftest.py (ac81272)

  • Merge pull request #1816 from python-gitlab/jlvillal/remove_replace

fix: remove custom URL encoding (24d2766)

  • Merge pull request #1818 from python-gitlab/jlvillal/merge_request_merge_defaults

fix: remove default arguments for mergerequests.merge() (0dba899)

  • Merge pull request #1790 from python-gitlab/jlvillal/parent_attrs

fix(cli): url-encode path components of the URL (22a1516)

  • Merge pull request #1809 from python-gitlab/jlvillal/list_api

fix: change to http_list for some ProjectCommit methods (d45b59e)

  • Merge pull request #1813 from derekschrock/missing-dist

chore(dist): add docs *.md files to sdist (4861883)

  • Merge pull request #1814 from python-gitlab/jlvillal/missing_comma

chore: fix missing comma (fd523b3)

  • Merge pull request #1789 from python-gitlab/jlvillal/stale

chore: add a stale workflow (9896340)

  • Merge pull request #1803 from python-gitlab/jlvillal/test_1425

chore: add functional test of mergerequest.get() (bc6c6e6)

v3.0.0 (2022-01-05)#

Breaking#

  • feat(cli): allow options from args and environment variables

BREAKING-CHANGE: The gitlab CLI will now accept CLI arguments and environment variables for its global options in addition to configuration file options. This may change behavior for some workflows such as running inside GitLab CI and with certain environment variables configured. (ca58008)

  • fix: stop encoding ‘.’ to ‘%2E’

Forcing the encoding of ‘.’ to ‘%2E’ causes issues. It also goes against the RFC: https://datatracker.ietf.org/doc/html/rfc3986.html#section-2.3

From the RFC: For consistency, percent-encoded octets in the ranges of ALPHA (%41-%5A and %61-%7A), DIGIT (%30-%39), hyphen (%2D), period (%2E), underscore (%5F), or tilde (%7E) should not be created by URI producers…

Closes #1006 Related #1356 Related #1561

BREAKING CHANGE: stop encoding ‘.’ to ‘%2E’. This could potentially be a breaking change for users who have incorrectly configured GitLab servers which don’t handle period ‘.’ characters correctly. (702e41d)

  • feat(cli): do not require config file to run CLI

BREAKING CHANGE: A config file is no longer needed to run the CLI. python-gitlab will default to https://gitlab.com with no authentication if there is no config file provided. python-gitlab will now also only look for configuration in the provided PYTHON_GITLAB_CFG path, instead of merging it with user- and system-wide config files. If the environment variable is defined and the file cannot be opened, python-gitlab will now explicitly fail. (92a893b)

  • feat: remove support for Python 3.6, require 3.7 or higher

Python 3.6 is End-of-Life (EOL) as of 2021-12 as stated in https://www.python.org/dev/peps/pep-0494/

By dropping support for Python 3.6 and requiring Python 3.7 or higher it allows python-gitlab to take advantage of new features in Python 3.7, which are documented at: https://docs.python.org/3/whatsnew/3.7.html

Some of these new features that may be useful to python-gitlab are:

  • PEP 563, postponed evaluation of type annotations.

  • dataclasses: PEP 557 – Data Classes

  • importlib.resources

  • PEP 562, customization of access to module attributes.

  • PEP 560, core support for typing module and generic types.

  • PEP 565, improved DeprecationWarning handling

BREAKING CHANGE: As of python-gitlab 3.0.0, Python 3.6 is no longer supported. Python 3.7 or higher is required. (414009d)

  • chore: rename master branch to main

BREAKING CHANGE: As of python-gitlab 3.0.0, the default branch for development has changed from master to main. (545f8ed)

  • refactor(objects): remove deprecated branch protect methods

BREAKING CHANGE: remove deprecated branch protect methods in favor of the more complete protected branches API. (9656a16)

  • fix(api): replace deprecated attribute in delete_in_bulk() (#1536)

BREAKING CHANGE: The deprecated name_regex attribute has been removed in favor of name_regex_delete. (see https://gitlab.com/gitlab-org/gitlab/-/commit/ce99813cf54) (c59fbdb)

  • fix(objects): rename confusing to_project_id argument

BREAKING CHANGE: rename confusing to_project_id argument in transfer_project to project_id (--project-id in CLI). This is used for the source project, not for the target namespace. (ce4bc0d)

  • refactor(objects): remove deprecated constants defined in objects

BREAKING CHANGE: remove deprecated constants defined in gitlab.v4.objects, and use only gitlab.const module (3f320af)

  • refactor(objects): remove deprecated tag release API

BREAKING CHANGE: remove deprecated tag release API. This was removed in GitLab 14.0 (2b8a94a)

  • refactor(objects): remove deprecated project.issuesstatistics

BREAKING CHANGE: remove deprecated project.issuesstatistics in favor of project.issues_statistics (ca7777e)

  • refactor(objects): remove deprecated members.all() method

BREAKING CHANGE: remove deprecated members.all() method in favor of members_all.list() (4d7b848)

  • refactor(objects): remove deprecated pipelines() method

BREAKING CHANGE: remove deprecated pipelines() methods in favor of pipelines.list() (c4f5ec6)

  • feat: default to gitlab.com if no URL given

BREAKING CHANGE: python-gitlab will now default to gitlab.com if no URL is given (8236281)

  • fix!: raise error if there is a 301/302 redirection

Before we raised an error if there was a 301, 302 redirect but only from an http URL to an https URL. But we didn’t raise an error for any other redirects.

This caused two problems:

  1. PUT requests that are redirected get changed to GET requests which don’t perform the desired action but raise no error. This is because the GET response succeeds but since it wasn’t a PUT it doesn’t update. See issue: https://github.com/python-gitlab/python-gitlab/issues/1432

  2. POST requests that are redirected also got changed to GET requests. They also caused hard to debug tracebacks for the user. See issue: https://github.com/python-gitlab/python-gitlab/issues/1477

Correct this by always raising a RedirectError exception and improve the exception message to let them know what was redirected.

Closes: #1485 Closes: #1432 Closes: #1477 (d56a434)

Chore#

  • chore: fix typo in MR documentation (2254222)

  • chore: add functional test of mergerequest.get()

Add a functional test of test mergerequest.get() and mergerequest.get(…, lazy=True)

Closes: #1425 (a92b55b)

  • chore(deps): update dependency argcomplete to v2 (c6d7e9a)

  • chore(deps): update dependency requests to v2.27.0 (f8c3d00)

  • chore: add test case to show branch name with period works

Add a test case to show that a branch name with a period can be fetched with a get()

Closes: #1715 (ea97d7a)

  • chore(deps): update typing dependencies (1f95613)

  • chore(deps): update dependency mypy to v0.930 (ccf8190)

  • chore(deps): upgrade mypy pre-commit hook (e19e4d7)

  • chore: fix functional test failure if config present

Fix functional test failure if config present and configured with token.

Closes: #1791 (c8256a5)

  • chore: ensure reset_gitlab() succeeds

Ensure reset_gitlab() succeeds by waiting to make sure everything has been deleted as expected. If the timeout is exceeded fail the test.

Not using wait_for_sidekiq as it didn’t work. During testing I didn’t see any sidekiq processes as being busy even though not everything was deleted. (0aa0b27)

  • chore: skip a functional test if not using >= py3.9

One of the tests requires Python 3.9 or higher to run. Mark the test to be skipped if running Python less than 3.9. (ac9b595)

  • chore: update version in docker-compose.yml

When running with docker-compose on Ubuntu 20.04 I got the error:

$ docker-compose up ERROR: The Compose file ‘./docker-compose.yml’ is invalid because: networks.gitlab-network value Additional properties are not allowed (‘name’ was unexpected)

Changing the version in the docker-compose.yml file fro ‘3’ to ‘3.5’ resolved the issue. (79321aa)

  • chore: add and document optional parameters for get MR

Add and document (some of the) optional parameters that can be done for a project.merge_requests.get()

Closes #1775 (bfa3dbe)

  • chore: generate artifacts for the docs build in the CI

When building the docs store the created documentation as an artifact so that it can be viewed.

This will create a html-docs.zip file which can be downloaded containing the contents of the build/sphinx/html/ directory. It can be downloaded, extracted, and then viewed. This can be useful in reviewing changes to the documentation.

See https://github.com/actions/upload-artifact for more information on how this works. (85b43ae)

  • chore(deps): update pre-commit hook pycqa/flake8 to v4 (98a5592)

  • chore(deps): update pre-commit hook psf/black to v21 (b86e819)

  • chore(deps): update pre-commit hook pycqa/isort to v5.10.1 (8ac4f4a)

  • chore: remove ‘# type: ignore’ for new mypy version

mypy 0.920 now understands the type of ‘http.client.HTTPConnection.debuglevel’ so we remove the ‘type: ignore’ comment to make mypy pass (34a5f22)

  • chore(deps): update dependency mypy to v0.920 (a519b2f)

  • chore(deps): update pre-commit hook alessandrojcm/commitlint-pre-commit-hook to v6 (fb9110b)

  • chore(ci): enable renovate for pre-commit (1ac4329)

  • chore: fix unit test if config file exists locally

Closes #1764 (c80b3b7)

  • chore(deps): update dependency sphinx to v4.3.2 (2210e56)

  • chore: add .env as a file that search tools should not ignore

The .env file was not set as a file that should not be ignored by search tools. We want to have the search tools search any .env files. (c9318a9)

  • chore(deps): update dependency types-requests to v2.26.2 (ac7e329)

  • chore: add Python 3.11 testing

Add a unit test for Python 3.11. This will use the latest version of Python 3.11 that is available from https://github.com/actions/python-versions/

At this time it is 3.11.0-alpha.2 but will move forward over time until the final 3.11 release and updates. So 3.11.0, 3.11.1, … will be matched. (b5ec192)

  • chore(api): temporarily remove topic delete endpoint

It is not yet available upstream. (e3035a7)

  • chore: fix renovate setup for gitlab docker image (49af15b)

  • chore: add get() methods for GetWithoutIdMixin based classes

Add the get() methods for the GetWithoutIdMixin based classes.

Update the tests/meta/test_ensure_type_hints.py tests to check to ensure that the get methods are defined with the correct return type. (d27c50a)

  • chore: github workflow: cancel prior running jobs on new push

If new new push is done to a pull-request, then cancel any already running github workflow jobs in order to conserve resources. (fd81569)

  • chore: fix pylint error “expression-not-assigned”

Fix pylint error “expression-not-assigned” and remove check from the disabled list.

And I personally think it is much more readable now and is less lines of code. (a90eb23)

  • chore: add running unit tests on windows/macos

Add running the unit tests on windows-latest and macos-latest with Python 3.10. (ad5d60c)

  • chore: set pre-commit mypy args to empty list

https://github.com/pre-commit/mirrors-mypy/blob/master/.pre-commit-hooks.yaml

Sets some default args which seem to be interfering with things. Plus we set all of our args in the pyproject.toml file. (b67a6ad)

  • chore: run pre-commit on changes to the config file

If .pre-commit-config.yaml or .github/workflows/pre_commit.yml are updated then run pre-commit. (5f10b3b)

  • chore: add initial pylint check

Initial pylint check is added. A LONG list of disabled checks is also added. In the future we should work through the list and resolve the errors or disable them on a more granular level. (041091f)

  • chore: enable ‘warn_redundant_casts’ for mypy

Enable ‘warn_redundant_casts’for mypy and resolve one issue. (f40e9b3)

  • chore: enable subset of the ‘mypy –strict’ options that work

Enable the subset of the ‘mypy –strict’ options that work with no changes to the code. (a86d049)

  • chore(deps): update dependency black to v21.12b0 (ab841b8)

  • chore: use constants from gitlab.const module

Have code use constants from the gitlab.const module instead of from the top-level gitlab module. (6b8067e)

  • chore: attempt to be more informative for missing attributes

A commonly reported issue from users on Gitter is that they get an AttributeError for an attribute that should be present. This is often caused due to the fact that they used the list() method to retrieve the object and objects retrieved this way often only have a subset of the full data.

Add more details in the AttributeError message that explains the situation to users. This will hopefully allow them to resolve the issue.

Update the FAQ in the docs to add a section discussing the issue.

Closes #1138 (1839c9e)

  • chore(docs): link to main, not master (af0cb4d)

  • chore(docs): use builtin autodoc hints (5e9c943)

  • chore(docs): load autodoc-typehints module (bd366ab)

  • chore(tests): apply review suggestions (381c748)

  • chore(deps): update dependency sphinx to v4.3.1 (93a3893)

  • chore: remove pytest-console-scripts specific config

Remove the pytest-console-scripts specific config from the global ‘[pytest]’ config section.

Use the command line option --script-launch-mode=subprocess

Closes #1713 (e80dcb1)

  • chore(deps): update typing dependencies (8d4c953)

  • chore: remove duplicate/no-op tests from meta/test_ensure_type_hints

Before we were generating 725 tests for the meta/test_ensure_type_hints.py tests. Which isn’t a huge concern as it was fairly fast. But when we had a failure we would usually get two failures for each problem as the same test was being run multiple times.

Changed it so that:

  1. Don’t add tests that are not for *Manager classes

  2. Use a set so that we don’t have duplicate tests.

After doing that our generated test count in meta/test_ensure_type_hints.py went from 725 to 178 tests.

Additionally removed the parsing of pyproject.toml to generate files to ignore as we have finished adding type-hints to all files in gitlab/v4/objects/. This also means we no longer use the toml library so remove installation of types-toml.

To determine the test count the following command was run: $ tox -e py39 – -k test_ensure_type_hints (a2f59f4)

  • chore(deps): update dependency types-setuptools to v57.4.3 (ec2c68b)

  • chore(deps): update dependency black to v21 (5bca87c)

  • chore: have renovate upgrade black version (#1700)

renovate is not upgrading the black package. There is an open issue[1] about this.

Also change .commitlintrc.json to allow 200 character footer lines in the commit message. Otherwise would be forced to split the URL across multiple lines making it un-clickable :(

Use suggested work-arounds from: https://github.com/renovatebot/renovate/issues/7167#issuecomment-904106838 https://github.com/scop/bash-completion/blob/e7497f6ee8232065ec11450a52a1f244f345e2c6/renovate.json#L34-L38

[1] https://github.com/renovatebot/renovate/issues/7167 (21228cd)

  • chore: add type-hints to gitlab/v4/objects/files.py (0c22bd9)

  • chore: add type-hints to gitlab/v4/objects/labels.py (d04e557)

  • chore: add type-hints to gitlab/v4/objects/sidekiq.py (a91a303)

  • chore: add type-hints to gitlab/v4/objects/services.py (8da0b75)

  • chore: add type-hints to gitlab/v4/objects/repositories.py (00d7b20)

  • chore: add type-hints to gitlab/v4/objects/pipelines.py (cb3ad6c)

  • chore: add type-hints to gitlab/v4/objects/milestones.py (8b6078f)

  • chore: add type-hints to gitlab/v4/objects/jobs.py (e8884f2)

  • chore: add type-hints to gitlab/v4/objects/issues.py (93e39a2)

  • chore: add type-hints to gitlab/v4/objects/geo_nodes.py (13243b7)

  • chore: add type-hints to gitlab/v4/objects/epics.py (d4adf8d)

  • chore: fix issue with adding type-hints to ‘manager’ attribute

When attempting to add type-hints to the the ‘manager’ attribute into a RESTObject derived class it would break things.

This was because our auto-manager creation code would automatically add the specified annotated manager to the ‘manager’ attribute. This breaks things.

Now check in our auto-manager creation if our attribute is called ‘manager’. If so we ignore it. (9a451a8)

  • chore: correct test_groups.py test

The test was checking twice if the same group3 was not in the returned list. Should have been checking for group3 and group4.

Also added a test that only skipped one group and checked that the group was not in the returned list and a non-skipped group was in the list. (9c878a4)

  • chore: add type-hints to gitlab/v4/objects/merge_request_approvals.py (cf3a99a)

  • chore: enable mypy for tests/meta/* (ba7707f)

  • chore: check setup.py with mypy

Prior commit 06184daafd5010ba40bb39a0768540b7e98bd171 fixed the type-hints for setup.py. But missed removing ‘setup’ from the exclude list in pyproject.toml for mypy checks.

Remove ‘setup’ from the exclude list in pyproject.toml from mypy checks. (77cb7a8)

  • chore: ensure get() methods have correct type-hints

Fix classes which don’t have correct ‘get()’ methods for classes derived from GetMixin.

Add a unit test which verifies that classes have the correct return type in their ‘get()’ method. (46773a8)

  • chore: create a ‘tests/meta/’ directory and put test_mro.py in it

The ‘test_mro.py’ file is not really a unit test but more of a ‘meta’ check on the validity of the code base. (94feb8a)

  • chore: add type-hints to setup.py and check with mypy (06184da)

  • chore: add type-hints to gitlab/v4/objects/snippets.py (f256d4f)

  • chore(deps): update dependency types-pyyaml to v6.0.1 (a544cd5)

  • chore(deps): update dependency sphinx to v4.3.0 (57283fc)

  • chore(deps): update dependency types-requests to v2.26.0 (7528d84)

  • chore(deps): update dependency isort to v5.10.1 (2012975)

  • chore(deps): update dependency types-requests to v2.25.12 (205ad5f)

  • chore: enforce type-hints on most files in gitlab/v4/objects/

    • Add type-hints to some of the files in gitlab/v4/objects/

    • Fix issues detected when adding type-hints

    • Changed mypy exclusion to explicitly list the 13 files that have not yet had type-hints added. (7828ba2)

  • chore: add type hints for gitlab/v4/objects/commits.py (dc096a2)

  • chore(ci): add workflow to lock old issues (a7d64fe)

  • chore: add type-hints to multiple files in gitlab/v4/objects/

Add and/or check type-hints for the following files gitlab.v4.objects.access_requests gitlab.v4.objects.applications gitlab.v4.objects.broadcast_messages gitlab.v4.objects.deployments gitlab.v4.objects.keys gitlab.v4.objects.merge_trains gitlab.v4.objects.namespaces gitlab.v4.objects.pages gitlab.v4.objects.personal_access_tokens gitlab.v4.objects.project_access_tokens gitlab.v4.objects.tags gitlab.v4.objects.templates gitlab.v4.objects.triggers

Add a ‘get’ method with the correct type for Managers derived from GetMixin. (8b75a77)

  • chore: add type-hints to gitlab/v4/objects/groups.py

  • Add type-hints to gitlab/v4/objects/groups.py

  • Have share() function update object attributes.

  • Add ‘get()’ method so that type-checkers will understand that getting a group is of type Group. (94dcb06)

  • chore: add type-hints to gitlab/v4/objects/merge_requests.py

  • Add type-hints to gitlab/v4/objects/merge_requests.py

  • Add return value to cancel_merge_when_pipeline_succeeds() function as GitLab docs show it returns a value.

  • Add return value to approve() function as GitLab docs show it returns a value.

  • Add ‘get()’ method so that type-checkers will understand that getting a project merge request is of type ProjectMergeRequest. (f9c0ad9)

  • chore(deps): update dependency isort to v5.10.0 (ae62468)

  • chore(ci): wait for all coverage jobs before posting comment (c7fdad4)

  • chore(deps): update dependency types-pyyaml to v6 (0b53c0a)

  • chore(deps): update typing dependencies (4170dbe)

  • chore(deps): update dependency flake8 to v4 (79785f0)

  • chore(deps): update typing dependencies (4eb8ec8)

  • chore(deps): upgrade gitlab-ce to 14.3.2-ce.0 (5a1678f)

  • chore(objects): remove non-existing trigger ownership method (8dc7f40)

  • chore(deps): update dependency types-requests to v2.25.9 (e3912ca)

  • chore: fix type-check issue shown by new requests-types

types-requests==2.25.9 changed a type-hint. Update code to handle this change. (0ee9aa4)

  • chore(deps): update dependency sphinx to v4 (73745f7)

  • chore(deps): update python docker tag to v3.10 (b3d6d91)

  • chore: clean up install docs (a5d8b7f)

  • chore: attempt to fix flaky functional test

Add an additional check to attempt to solve the flakiness of the test_merge_request_should_remove_source_branch() test. (487b9a8)

  • chore: convert to using type-annotations for managers

Convert our manager usage to be done via type annotations.

Now to define a manager to be used in a RESTObject subclass can simply do: class ExampleClass(CRUDMixin, RESTObject): my_manager: MyManager

Any type-annotation that annotates it to be of type *Manager (with the exception of RESTManager) will cause the manager to be created on the object. (d8de4dc)

  • chore: add type-hints to gitlab/v4/objects/users.py

Adding type-hints to gitlab/v4/objects/users.py (88988e3)

  • chore: improve type-hinting for managers

The ‘managers’ are dynamically created. This unfortunately means that we don’t have any type-hints for them and so editors which understand type-hints won’t know that they are valid attributes.

  • Add the type-hints for the managers we define.

  • Add a unit test that makes sure that the type-hints and the ‘_managers’ attribute are kept in sync with each other.

  • Add unit test that makes sure specified managers in ‘_managers’ have a name ending in ‘Managers’ to keep with current convention.

  • Make RESTObject._managers always present with a default value of None.

  • Fix a type-issue revealed now that mypy knows what the type is (c9b5d3b)

  • chore(deps): update dependency types-pyyaml to v5.4.10 (bdb6cb9)

Documentation#

  • docs: switch to Furo and refresh introduction pages (ee6b024)

  • docs: correct documentation for updating discussion note

Closes #1777 (ee66f4a)

  • docs: rename documentation files to match names of code files

Rename the merge request related documentation files to match the code files. This will make it easier to find the documentation quickly.

Rename: docs/gl_objects/mrs.rst -&gt; docs/gl_objects/merge_requests.rst   docs/gl_objects/mr_approvals.rst -> docs/gl_objects/merge_request_approvals.rst (ee3f865)

  • docs(project): remove redundant encoding parameter (fed613f)

  • docs: use annotations for return types (79e785e)

  • docs: update docs to use gitlab.const for constants

Update the docs to use gitlab.const to access constants. (b3b0b5f)

  • docs: only use type annotations for documentation (b7dde0d)

  • docs: add links to the GitLab API docs

Add links to the GitLab API docs for merge_requests.py as it contains code which spans two different API documentation pages. (e3b5d27)

  • docs: fix API delete key example (b31bb05)

  • docs(pipelines): document take_ownership method (69461f6)

  • docs(api): document the update method for project variables (7992911)

  • docs(api): clarify job token usage with auth()

See issue #1620 (3f423ef)

  • docs: fix a few typos

There are small typos in:

  • docs/gl_objects/deploy_tokens.rst

  • gitlab/base.py

  • gitlab/mixins.py

  • gitlab/v4/objects/features.py

  • gitlab/v4/objects/groups.py

  • gitlab/v4/objects/packages.py

  • gitlab/v4/objects/projects.py

  • gitlab/v4/objects/sidekiq.py

  • gitlab/v4/objects/todos.py

Fixes:

  • Should read treatment rather than reatment.

  • Should read transferred rather than transfered.

  • Should read registered rather than registred.

  • Should read occurred rather than occured.

  • Should read overridden rather than overriden.

  • Should read marked rather than maked.

  • Should read instantiate rather than instanciate.

  • Should read function rather than fonction. (7ea4ddc)

  • docs: consolidate changelogs and remove v3 API docs (90da8ba)

  • docs: correct documented return type

repository_archive() returns ‘bytes’ not ‘str’

https://docs.gitlab.com/ee/api/repositories.html#get-file-archive

Fixes: #1584 (acabf63)

Feature#

  • feat(docker): remove custom entrypoint from image

This is no longer needed as all of the configuration is handled by the CLI and can be passed as arguments. (80754a1)

  • feat(api): support file format for repository archive (83dcabf)

  • feat: add support for squash_option in Projects

There is an optional squash_option parameter which can be used when creating Projects and UserProjects.

Closes #1744 (a246ce8)

  • feat(api): add support for Topics API (e7559bf)

  • feat: add delete on package_file object (124667b)

  • feat: add support for projects.groups.list()

Add support for projects.groups.list() endpoint.

Closes #1717 (68ff595)

  • feat(api): add support for epic notes

Added support for notes on group epics

Signed-off-by: Raimund Hook <raimund.hook@exfo.com> (7f4edb5)

  • feat(api): add project milestone promotion

Adds promotion to Project Milestones

Signed-off-by: Raimund Hook <raimund.hook@exfo.com> (f068520)

  • feat(api): add merge trains

Add support for merge trains (fd73a73)

  • feat(api): add merge request approval state

Add support for merge request approval state (f41b093)

  • feat(api): add project label promotion

Adds a mixin that allows the /promote endpoint to be called.

Signed-off-by: Raimund Hook <raimund.hook@exfo.com> (6d7c88a)

  • feat(objects): support delete package files API (4518046)

  • feat(objects): list starred projects of a user (47a5606)

  • feat(build): officially support and test python 3.10 (c042ddc)

  • feat(objects): support Create and Revoke personal access token API (e19314d)

  • feat: allow global retry_transient_errors setup

retry_transient_errors can now be set through the Gitlab instance and global configuration

Documentation for API usage has been updated and missing tests have been added. (3b1d3a4)

Fix#

  • fix: handle situation where GitLab does not return values

If a query returns more than 10,000 records than the following values are NOT returned: x.total_pages x.total

Modify the code to allow no value to be set for these values. If there is not a value returned the functions will now return None.

Update unit test so no longer xfail

https://docs.gitlab.com/ee/user/gitlab_com/index.html#pagination-response-headers

Closes #1686 (cb824a4)

  • fix(build): do not include docs in wheel package (68a97ce)

  • fix(api): delete invalid ‘project-runner get’ command (#1628)

  • fix(api): delete ‘group-runner get’ and ‘group-runner delete’ commands

Co-authored-by: Léo GATELLIER <git@leogatellier.fr> (905781b)

  • fix(build): do not package tests in wheel (969dccc)

Refactor#

  • refactor: deprecate accessing constants from top-level namespace

We are planning on adding enumerated constants into gitlab/const.py, but if we do that than they will end up being added to the top-level gitlab namespace. We really want to get users to start using gitlab.const. to access the constant values in the future.

Add the currently defined constants to a list that should not change. Use a module level getattr function so that we can deprecate access to the top-level constants.

Add a unit test which verifies we generate a warning when accessing the top-level constants. (c0aa0e1)

  • refactor: use new-style formatting for named placeholders (c0d8810)

  • refactor: use f-strings for string formatting (7925c90)

Test#

  • test: reproduce missing pagination headers in tests (501f9a1)

  • test: drop httmock dependency in test_gitlab.py (c764bee)

  • test(api): fix current user mail count in newer gitlab (af33aff)

  • test(cli): improve basic CLI coverage (6b892e3)

  • test(build): add smoke tests for sdist & wheel package (b8a47ba)

Unknown#

  • Merge pull request #1804 from mlegner/patch-1

chore: fix typo in MR documentation (1582387)

  • Merge pull request #1800 from python-gitlab/jlvillal/dot_branch

chore: add test case to show branch name with period works (896a8c7)

  • Merge pull request #1799 from python-gitlab/renovate/mypy-0.x

chore(deps): update dependency mypy to v0.930 (2323a7c)

  • Merge pull request #1792 from python-gitlab/jlvillal/cli_test

chore: fix functional test failure if config present (2ac2a68)

  • Merge pull request #1773 from python-gitlab/jlvillal/pagination

fix: handle situation where gitlab.com does not return values (a3eafab)

  • Merge pull request #1783 from python-gitlab/jlvillal/sidekiq

chore: ensure reset_gitlab() succeeds (f26bf7d)

  • Merge pull request #1782 from python-gitlab/jlvillal/repository_func_tests

chore: skip a functional test if not using >= py3.9 (d65ce36)

  • Merge pull request #1781 from python-gitlab/jlvillal/docker_compose

chore: update version in docker-compose.yml (171df89)

  • Merge pull request #1774 from python-gitlab/jlvillal/doc_artifacts

chore: generate artifacts for the docs build in the CI (3cb2352)

  • Merge pull request #1776 from python-gitlab/jlvillal/rebase_in_progress

Add some docs for getting the status of a merge_request rebase (e7d4d91)

  • Merge pull request #1766 from python-gitlab/jlvillal/leave_dot

fix: stop encoding ‘.’ to ‘%2E’ (eef8059)

  • Merge pull request #1770 from python-gitlab/renovate/alessandrojcm-commitlint-pre-commit-hook-6.x

chore(deps): update pre-commit hook alessandrojcm/commitlint-pre-commit-hook to v6 (182ab92)

  • Merge pull request #1753 from python-gitlab/renovate/mypy-0.x

chore(deps): update dependency mypy to v0.920 (5ea5392)

  • Merge pull request #1765 from python-gitlab/jlvillal/unit_test_config

chore: fix unit test if config file exists locally (ccefe80)

  • Merge pull request #1757 from python-gitlab/jlvillal/gitignore

chore: add .env as a file that search tools should not ignore (3ee061c)

  • Merge pull request #1746 from python-gitlab/jlvillal/squash_option

feat: add support for squash_option in Projects (7799cb9)

  • Merge pull request #1743 from python-gitlab/feat/cli-without-config-file

feat(cli): do not require config file to run CLI (170a4d9)

  • Merge pull request #1742 from python-gitlab/jlvillal/py311_alpha

chore: add Python 3.11 testing (74d4e4b)

  • Merge pull request #1710 from python-gitlab/jlvillal/get_without_id

chore: add get() methods for GetWithoutIdMixin based classes (ac5defa)

  • Merge pull request #1733 from simonisateur/fix-package-file-delete

feat: package file delete on package file object (2f37ccb)

  • Merge pull request #1736 from python-gitlab/jlvillal/workflow

chore: github workflow: cancel prior running jobs on new push (4945353)

  • Merge pull request #1726 from python-gitlab/jlvillal/windows

chore: add running unit tests on windows/macos (83f36d6)

  • Merge pull request #1738 from python-gitlab/jlvillal/pylint_fixes

chore: fix pylint error “expression-not-assigned” (3679591)

  • Merge pull request #1729 from python-gitlab/jlvillal/pylint

chore: add initial pylint check (3a7d6f6)

  • Merge pull request #1727 from python-gitlab/jlvillal/mypy_strict_two_steps

Enable more strict mypy checking (1c33080)

  • Merge pull request #1709 from python-gitlab/docs/sphinx-annotations

docs: only use type annotations for documentation (2708f91)

  • Merge pull request #1702 from python-gitlab/jlvillal/attribute_help

chore: attempt to be more informative for missing attributes (387e59f)

  • Merge pull request #1694 from python-gitlab/jlvillal/const_explicit

refactor: explicitly import gitlab.const values into top-level namespace (e6582a3)

  • Merge pull request #1721 from python-gitlab/test/cli-coverage

test(cli): improve basic CLI coverage (09a973e)

  • Merge pull request #1714 from python-gitlab/jlvillal/pytest_script_launch_mode

chore: remove pytest-console-scripts specific config (1badfeb)

  • Merge pull request #1712 from StingRayZA/Epicnotes

feat(api): add support for epic notes (70b9870)

  • Merge pull request #1718 from python-gitlab/jlvillal/project_groups

feat: add support for projects.groups.list() (64f2360)

  • Merge pull request #1707 from python-gitlab/jlvillal/reduce_meta_tests

chore: remove duplicate/no-op tests from meta/test_ensure_type_hints (3225f2c)

  • Merge pull request #1695 from python-gitlab/jlvillal/mypy_epics

chore: add type-hints to remaining gitlab/v4/objects/*.py files (7ba5995)

  • Merge pull request #1705 from python-gitlab/jlvillal/drop_py_36

feat: remove support for Python 3.6, require 3.7 or higher (a390ec3)

  • Merge pull request #1693 from python-gitlab/jlvillay/mypy_test_meta

chore: enable mypy for tests/meta/* (9b78c10)

  • Merge pull request #1701 from python-gitlab/jlvillal/func_test

chore: correct test_groups.py test (178ec1a)

  • Merge pull request #1696 from python-gitlab/jlvillal/mypy_merge_request_approvals

chore: add type-hints to gitlab/v4/objects/merge_request_approvals.py (2cd15ac)

  • Merge pull request #1692 from python-gitlab/jlvillal/mypy_setup

chore: check setup.py with mypy (500895a)

  • Merge pull request #1681 from python-gitlab/jlvillal/mypy_ensure_type_hints

Ensure get() methods have correct type-hints (0951989)

  • Merge pull request #1683 from python-gitlab/jlvillal/mypy_setup

chore: add type-hints to setup.py and check with mypy (a553ee7)

  • Merge pull request #1691 from python-gitlab/jlvillal/mypy_snippets

chore: add type-hints to gitlab/v4/objects/snippets.py (f775668)

  • Merge pull request #1680 from python-gitlab/jlvillal/mypy_small_files_1

chore: enforce type-hints on most files in gitlab/v4/objects/ (472b300)

  • Merge pull request #1678 from python-gitlab/jlvillal/mypy_commits

chore: add type hints for gitlab/v4/objects/commits.py (9a2f54c)

  • Merge pull request #1677 from python-gitlab/chore/ci-lock-threads

chore(ci): add workflow to lock old issues (0e6fb5e)

  • Merge pull request #1674 from python-gitlab/jlvillal/mypy_small_files_1

chore: add type-hints to multiple files in gitlab/v4/objects/ (cf801d8)

  • Merge pull request #1668 from python-gitlab/jlvillal/mypy_groups

chore: add type-hints to gitlab/v4/objects/groups.py (f3688dc)

  • Merge pull request #1673 from python-gitlab/jlvillal/mypy_merge_requests

chore: add type-hints to gitlab/v4/objects/merge_requests.py (32ea954)

  • Merge pull request #1670 from python-gitlab/jlvillal/merge_requests_api

docs: add links to the GitLab API docs (4ab9e92)

  • Merge pull request #1665 from python-gitlab/renovate/isort-5.x

chore(deps): update dependency isort to v5.10.0 (f51d9be)

  • Merge pull request #1646 from JacobHenner/add-merge-trains

feat(api): add merge trains (ed88bce)

  • Merge pull request #1655 from StingRayZA/add-milestone-promote

feat(api): add project milestone promotion (5ce3b17)

  • Merge pull request #1641 from JacobHenner/add-merge-request-approval-state

feat(api): add merge request approval state (422309f)

  • Merge pull request #1610 from StingRayZA/add-label-promote

feat(api): add project label promotion (853d850)

  • Merge pull request #1629 from python-gitlab/chore/master-to-main

chore: rename master branch to main (63b2070)

  • Merge pull request #1616 from lmmx/patch-1

Document the update method for project variables (e851eed)

  • Merge pull request #1624 from axl89/docs-clarification

Clarified CI Job Token auth() caveats (49fae96)

  • Merge pull request #1515 from JohnVillalovos/jlvillal/mypy_v4_obj_users

chore: add type-hints to gitlab/v4/objects/users.py (7753fa2)

  • Merge pull request #1621 from JohnVillalovos/jlvillal/mypy_dep

chore: fix type-check issue shown by new requests-types (e93f84b)

  • Merge pull request #1619 from python-gitlab/renovate/python-3.x

chore(deps): update python docker tag to v3.10 (d97f79d)

  • Merge pull request #1617 from python-gitlab/feat/support-3.10

feat(build): officially support and test python 3.10 (5c17c36)

  • Merge pull request #1450 from python-gitlab/renovate/sphinx-4.x

chore(deps): update dependency sphinx to v4 (6ce56c2)

  • Merge pull request #1603 from timgates42/bugfix_typos

docs: fix a few typos (227607c)

  • Merge pull request #1486 from JohnVillalovos/jlvillal/prohibit_redirection

fix!: raise error if there is a 301/302 redirection (3742405)

  • Merge pull request #1512 from JohnVillalovos/jlvillal/type_managers

chore: improve type-hinting for managers (5247e8b)

  • Merge pull request #1585 from JohnVillalovos/jlvillal/archive_type

docs: correct documented return type (557c7d2)

  • Merge pull request #1565 from javatarz/master

feat: allow global retry_transient_errors (d98d948)

v2.10.1 (2021-08-28)#

Chore#

  • chore(deps): update dependency types-pyyaml to v5.4.8 (2ae1dd7)

  • chore(deps): update dependency types-pyyaml to v5.4.7 (ec8be67)

  • chore(deps): update codecov/codecov-action action to v2 (44f4fb7)

  • chore(deps): update typing dependencies (34fc210)

  • chore: define root dir in mypy, not tox (7a64e67)

  • chore(deps): group typing requirements with mypy additional_dependencies (38597e7)

  • chore: fix mypy pre-commit hook (bd50df6)

  • chore(deps): update dependency types-requests to v2.25.2 (4782678)

  • chore(deps): update wagoid/commitlint-github-action action to v4 (ae97196)

  • chore(deps): update dependency types-requests to v2.25.1 (a2d133a)

  • chore(deps): update precommit hook pycqa/isort to v5.9.3 (e1954f3)

  • chore(deps): update dependency isort to v5.9.3 (ab46e31)

Documentation#

  • docs(mergequests): gl.mergequests.list documentation was missleading (5b5a7bc)

Fix#

  • fix(mixins): improve deprecation warning

Also note what should be changed (57e0187)

  • fix(deps): upgrade requests to 2.25.0 (see CVE-2021-33503) (ce995b2)

Unknown#

  • Merge pull request #1550 from python-gitlab/renovate/codecov-codecov-action-2.x

chore(deps): update codecov/codecov-action action to v2 (e54832a)

  • Merge pull request #1566 from Psycojoker/doc/mergequest_list_missleading_doc

docs(mergerequests): gl.mergerequests.list documentation was misleading (8e27721)

  • Merge pull request #1571 from python-gitlab/fix-mixings-improve-deprecation-warning

fix(mixins): improve deprecation warning (e2fdfbb)

v2.10.0 (2021-07-28)#

Chore#

  • chore(deps): update dependency requests to v2.26.0 (d3ea203)

  • chore(deps): update precommit hook pycqa/isort to v5.9.2 (521cddd)

  • chore(deps): update dependency isort to v5.9.2 (d5dcf1c)

Documentation#

  • docs(readme): move contributing docs to CONTRIBUTING.rst

Move the Contributing section of README.rst to CONTRIBUTING.rst, so it is recognized by GitHub and shown when new contributors make pull requests. (edf49a3)

  • docs: add example for mr.merge_ref

Signed-off-by: Matej Focko <mfocko@redhat.com> (b30b8ac)

  • docs(project): add example on getting a single project using name with namespace (ef16a97)

Feature#

  • feat(api): add merge_ref for merge requests

Support merge_ref on merge requests that returns commit of attempted merge of the MR.

Signed-off-by: Matej Focko <mfocko@redhat.com> (1e24ab2)

  • feat(api): add name_regex_keep attribute in delete_in_bulk() (e49ff3f)

Fix#

  • fix(api): do not require Release name for creation

Stop requiring a name attribute for creating a Release, since a release name has not been required since GitLab 12.5. (98cd03b)

Test#

  • test(functional): add mr.merge_ref tests

  • Add test for using merge_ref on non-merged MR

  • Add test for using merge_ref on MR with conflicts

Signed-off-by: Matej Focko <mfocko@redhat.com> (a9924f4)

Unknown#

  • Merge pull request #1537 from antti-mikael/feat/registry-deleteinbulk-keepregex

feat(api): add name_regex_keep attribute in delete_in_bulk() (85713bb)

v2.9.0 (2021-06-28)#

Chore#

  • chore: skip EE test case in functional tests (953f207)

  • chore(deps): update dependency mypy to v0.910 (02a56f3)

  • chore(deps): update dependency types-requests to v2 (a81a926)

  • chore(deps): update precommit hook pycqa/isort to v5.9.1 (c57ffe3)

  • chore(deps): update dependency isort to v5.9.1 (0479dba)

  • chore(deps): update dependency types-requests to v0.1.13 (c3ddae2)

  • chore(deps): update dependency types-requests to v0.1.12 (f84c2a8)

  • chore(deps): update dependency types-pyyaml to v5 (5c22634)

  • chore(deps): update dependency types-pyyaml to v0.1.9 (1f5b3c0)

  • chore(deps): update dependency types-pyyaml to v0.1.8 (e566767)

  • chore(deps): update dependency mypy to v0.902 (19c9736)

  • chore(deps): update dependency types-requests to v0.1.11 (6ba629c)

  • chore: add type-hints to gitlab/v4/objects/projects.py

Adding type-hints to gitlab/v4/objects/projects.py (872dd6d)

Documentation#

  • docs(tags): remove deprecated functions (1b1a827)

  • docs(release): add update example (6254a5f)

  • docs: make Gitlab class usable for intersphinx (8753add)

Feature#

  • feat(release): allow to update release

Release API now supports PUT. (b4c4787)

  • feat(api): add group hooks (4a7e9b8)

  • feat(api): remove responsibility for API inconsistencies for MR reviewers (3d985ee)

  • feat(api): add MR pipeline manager in favor of pipelines() method (954357c)

Test#

  • test(releases): integration for release PUT (13bf61d)

  • test(releases): add unit-tests for release update (5b68a5a)

Unknown#

  • Merge pull request #1533 from sugonyak/add-group-hooks

feat(api): add group hooks (6abf13a)

  • Merge pull request #1522 from PPaques/1521-releases-edit

Support Release Update API (33d3428)

  • Merge pull request #1396 from spyoungtech/merge_request_reviewers

feat(api): add support for creating/editing reviewers in project MRs (2c86003)

  • Merge pull request #1528 from python-gitlab/renovate/types-requests-2.x

chore(deps): update dependency types-requests to v2 (af7aae7)

  • Merge pull request #1323 from python-gitlab/feat/mr-pipeline-manager

feat(api): add merge request pipeline manager and deprecate mr.pipelines() method (e77554c)

  • Merge pull request #1513 from python-gitlab/renovate/types-pyyaml-0.x

chore(deps): update dependency types-pyyaml to v0.1.8 (e3aa023)

  • Merge pull request #1514 from python-gitlab/renovate/types-requests-0.x

chore(deps): update dependency types-requests to v0.1.11 (82973ce)

  • Merge pull request #1504 from python-gitlab/renovate/mypy-0.x

chore(deps): update dependency mypy to v0.902 (387e147)

  • Merge pull request #1505 from JohnVillalovos/jlvillal/mypy-deps

chore: add new required type packages for mypy (5446423)

  • Merge pull request #1511 from JohnVillalovos/jlvillal/testing-type-hints

chore: add type-hints to gitlab/v4/objects/projects.py (8e6aaf5)

v2.8.0 (2021-06-10)#

Chore#

  • chore: add new required type packages for mypy

New version of mypy flagged errors for missing types. Install the recommended type-* packages that resolve the issues. (a7371e1)

  • chore: sync create and update attributes for Projects

Sync the create attributes with: https://docs.gitlab.com/ee/api/projects.html#create-project

Sync the update attributes with documentation at: https://docs.gitlab.com/ee/api/projects.html#edit-project

As a note the ordering of the attributes was done to match the ordering of the attributes in the documentation.

Closes: #1497 (0044bd2)

  • chore: add missing linters to pre-commit and pin versions (85bbd1a)

  • chore(ci): use admin PAT for release workflow (d175d41)

  • chore: add missing optional create parameter for approval_rules

Add missing optional create parameter (‘protected_branch_ids’) to the project approvalrules.

https://docs.gitlab.com/ee/api/merge_request_approvals.html#create-project-level-rule (06a6001)

  • chore: apply typing suggestions

Co-authored-by: John Villalovos <john@sodarock.com> (a11623b)

  • chore: add type-hints to gitlab/v4/cli.py

    • Add type-hints to gitlab/v4/cli.py

    • Add required type-hints to other files based on adding type-hints to gitlab/v4/cli.py (2673af0)

  • chore(ci): ignore .python-version from pyenv (149953d)

  • chore: apply suggestions (fe7d19d)

  • chore: clean up tox, pre-commit and requirements (237b97c)

  • chore: make certain dotfiles searchable by ripgrep

By explicitly NOT excluding the dotfiles we care about to the .gitignore file we make those files searchable by tools like ripgrep.

By default dotfiles are ignored by ripgrep and other search tools (not grep) (e4ce078)

  • chore: use built-in function issubclass() instead of getmro()

Code was using inspect.getmro() to replicate the functionality of the built-in function issubclass()

Switch to using issubclass() (81f6386)

  • chore: correct a type-hint (046607c)

  • chore: move ‘gitlab/tests/’ dir to ‘tests/unit/’

Move the ‘gitlab/tests/’ directory to ‘tests/unit/’ so we have all the tests located under the ‘tests/’ directory. (1ac0722)

  • chore: rename ‘tools/functional/’ to ‘tests/functional/’

Rename the ‘tools/functional/’ directory to ‘tests/functional/’

This makes more sense as these are functional tests and not tools.

This was dicussed in: https://github.com/python-gitlab/python-gitlab/discussions/1468 (502715d)

  • chore: add a merge_request() pytest fixture and use it

Added a pytest.fixture for merge_request(). Use this fixture in tools/functional/api/test_merge_requests.py (8be2838)

  • chore: simplify functional tests

Add a helper function to have less code duplication in the functional testing. (df9b5f9)

  • chore: add functional test mr.merge() with long commit message

Functional test to show that https://github.com/python-gitlab/python-gitlab/issues/1452 is fixed.

Added a functional test to ensure that we can use large commit message (10_000+ bytes) in mr.merge()

Related to: #1452 (cd5993c)

  • chore: add a functional test for issue #1120

Going to switch to putting parameters from in the query string to having them in the ‘data’ body section. Add a functional test to make sure that we don’t break anything.

https://github.com/python-gitlab/python-gitlab/issues/1120 (7d66115)

  • chore: fix import ordering using isort

Fix the import ordering using isort.

https://pycqa.github.io/isort/ (f3afd34)

  • chore: add an isort tox environment and run isort in CI

    • Add an isort tox environment

    • Run the isort tox environment using –check in the Github CI

https://pycqa.github.io/isort/ (dda646e)

  • chore(deps): update precommit hook alessandrojcm/commitlint-pre-commit-hook to v5 (9ff349d)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.11.4-ce.0 (4223269)

  • chore(deps): update dependency docker-compose to v1.29.2 (fc241e1)

  • chore(ci): ignore debug and type_checking in coverage (885b608)

  • chore(ci): automate releases (0ef497e)

  • chore(docs): fix import order for readthedocs build (c3de1fb)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.11.3-ce.0 (f0b52d8)

  • chore: have black run at the top-level

This will ensure everything is formatted with black, including setup.py. (429d6c5)

  • chore: have flake8 check the entire project

Have flake8 run at the top-level of the projects instead of just the gitlab directory. (ab343ef)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.11.2-ce.0 (434d15d)

  • chore: mypy: Disallow untyped definitions

Be more strict and don’t allow untyped definitions on the files we check.

Also this adds type-hints for two of the decorators so that now functions/methods decorated by them will have their types be revealed correctly. (6aef2da)

  • chore: remove commented-out print (0357c37)

Documentation#

  • docs: fix typo in http_delete docstring (5226f09)

  • docs(api): add behavior in local attributes when updating objects (38f65e8)

  • docs: fail on warnings during sphinx build

This is useful when docs aren’t included in the toctree and don’t show up on RTD. (cbd4d52)

Feature#

  • feat: add keys endpoint (a81525a)

  • feat(objects): add support for Group wikis (#1484)

feat(objects): add support for Group wikis (74f5e62)

  • feat(objects): add support for generic packages API (79d88bd)

  • feat(api): add support for creating/editing reviewers in project merge requests (676d1f6)

  • feat(api): add deployment mergerequests interface (fbbc0d4)

  • feat(objects): support all issues statistics endpoints (f731707)

  • feat(objects): add support for descendant groups API (1b70580)

  • feat(objects): add pipeline test report support (ee9f96e)

  • feat(objects): add support for billable members (fb0b083)

  • feat: add feature to get inherited member for project/group (e444b39)

  • feat: add code owner approval as attribute

The python API was missing the field code_owner_approval_required as implemented in the GitLab REST API. (fdc46ba)

  • feat: indicate that we are a typed package

By adding the file: py.typed it indicates that python-gitlab is a typed package and contains type-hints.

https://www.python.org/dev/peps/pep-0561/ (e4421ca)

Fix#

  • fix: catch invalid type used to initialize RESTObject

Sometimes we have errors where we don’t get a dictionary passed to RESTObject.init() method. This breaks things but in confusing ways.

Check in the init() method and raise an exception if it occurs. (c7bcc25)

  • fix: functional project service test (#1500)

chore: fix functional project service test (093db9d)

  • fix: ensure kwargs are passed appropriately for ObjectDeleteMixin (4e690c2)

  • fix(cli): add missing list filter for jobs (b3d1c26)

  • fix: change mr.merge() to use ‘post_data’

MR https://github.com/python-gitlab/python-gitlab/pull/1121 changed mr.merge() to use ‘query_data’. This appears to have been wrong.

From the Gitlab docs they state it should be sent in a payload body https://docs.gitlab.com/ee/api/README.html#request-payload since mr.merge() is a PUT request.

> Request Payload

> API Requests can use parameters sent as query strings or as a > payload body. GET requests usually send a query string, while PUT > or POST requests usually send the payload body

Fixes: #1452 Related to: #1120 (cb6a3c6)

  • fix(cli): fix parsing CLI objects to classnames (4252070)

  • fix(objects): return server data in cancel/retry methods (9fed061)

  • fix(objects): add missing group attributes (d20ff4f)

  • fix(objects): allow lists for filters for in all objects (603a351)

  • fix: iids not working as a list in projects.issues.list()

Set the ‘iids’ values as type ListAttribute so it will pass the list as a comma-separated string, instead of a list.

Add a functional test.

Closes: #1407 (45f806c)

Style#

  • style: clean up test run config (dfa40c1)

Test#

  • test(functional): force delete users on reset

Timing issues between requesting group deletion and GitLab enacting that deletion resulted in errors while attempting to delete a user which was the sole owner of said group (see: test_groups). Pass the ‘hard_delete’ parameter to ensure user deletion. (8f81456)

  • test(api): fix issues test

Was incorrectly using the issue ‘id’ vs ‘iid’. (8e5b0de)

  • test(functional): explicitly remove deploy tokens on reset

Deploy tokens would remain in the instance if the respective project or group was deleted without explicitly revoking the deploy tokens first. (19a55d8)

  • test(cli): replace assignment expression

This is a feature added in 3.8, removing it allows for the test to run with lower python versions. (11ae11b)

  • test(functional): optionally keep containers running post-tests

Additionally updates token creation to make use of first_or_create(), to avoid errors from the script caused by GitLab constraints preventing duplicate tokens with the same value. (4c475ab)

  • test(cli): add more real class scenarios (8cf5031)

  • test(functional): add test for skip_groups list filter (a014774)

  • test(functional): start tracking functional test coverage (f875786)

Unknown#

  • Merge pull request #1487 from JohnVillalovos/jlvillal/check_attrs

fix: catch invalid type used to initialize RESTObject (600a2c1)

  • Merge pull request #1489 from python-gitlab/chore/release-action-gh-token

chore(ci): use PAT for release workflow (161bb0b)

  • Merge pull request #1499 from JohnVillalovos/jlvillal/projects_attrs

chore: sync create and update attributes for Projects (f91b72a)

  • Merge pull request #1490 from benjamb/benbrown/keys

feat: add keys endpoint (d3fac50)

  • Merge pull request #1478 from benjamb/benbrown/keep-containers

Optionally keep containers after running integration tests (d981956)

  • Merge pull request #1483 from JohnVillalovos/jlvillal/mypy_cli

chore: add type-hints to gitlab/v4/cli.py (55ae61a)

  • Merge pull request #1488 from JohnVillalovos/jlvillal/add_missing_option

chore: add missing optional create parameter for approval_rules (ac92205)

  • Merge pull request #1249 from rmonat/master

feat: add pipeline test report support (fb7174e)

  • Merge pull request #1475 from JohnVillalovos/jlvillal/gitignore

chore: make certain dotfiles searchable by ripgrep (861d3d2)

  • Merge pull request #1481 from JohnVillalovos/jlvillal/no_getmro

chore: use built-in function issubclass() instead of getmro() (489b0d3)

  • Merge pull request #1474 from JohnVillalovos/jlvillal/mv_unit_tests

chore: move ‘gitlab/tests/’ dir to ‘tests/unit/’ (56770ce)

  • Merge pull request #1480 from JohnVillalovos/jlvillal/fix_hint

chore: correct a type-hint (8eb911d)

  • Merge pull request #1469 from JohnVillalovos/jlvillal/test_directory

chore: rename ‘tools/functional/’ to ‘tests/functional/’ (90ecf2f)

  • Merge pull request #1465 from JohnVillalovos/jlvillal/fix_1452_query_parameters

Switch mr.merge() to use post_data (was using query_data) (9beff0d)

  • Merge pull request #1456 from python-gitlab/feat/billable-members

feat(objects): add support for billable members (184b94b)

  • Merge pull request #1463 from JohnVillalovos/jlvillal/isort

chore: add isort as a checker (7824811)

  • Merge pull request #1290 from python-gitlab/fix/parse-cli-objects-camelcase

fix(cli): fix parsing CLI objects to classnames (1508eb7)

  • Merge pull request #1459 from python-gitlab/renovate/alessandrojcm-commitlint-pre-commit-hook-5.x

chore(deps): update precommit hook alessandrojcm/commitlint-pre-commit-hook to v5 (ce0e642)

  • Merge pull request #1376 from Shkurupii/feat-get-inherited-members

feat: get inherited member for project/group (f35c73e)

  • Merge pull request #1455 from python-gitlab/renovate/gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.11.4-ce.0 (c4979a8)

  • Merge pull request #1451 from python-gitlab/renovate/docker-compose-1.x

chore(deps): update dependency docker-compose to v1.29.2 (3628949)

  • Merge pull request #1427 from python-gitlab/chore/automate-releases

chore(ci): automate releases (25695d9)

  • Merge pull request #1448 from python-gitlab/docs/local-object-attributes

docs(api): add behavior in local attributes when updating objects (b0b2113)

  • Merge pull request #1449 from python-gitlab/chore/ignore-typing-coverage

chore(ci): ignore debug and type_checking in coverage (62b544d)

  • Merge pull request #1440 from python-gitlab/test/functional-test-coverage

test(functional): start tracking functional test coverage (0d3b8ae)

  • Merge pull request #1420 from python-gitlab/fix/missing-list-attributes

fix(objects): make lists work for filters in all objects (45edae9)

  • Merge pull request #1444 from python-gitlab/fix/return-retry-cancel-output

fix(objects): return server data in cancel/retry methods (1ddb54a)

  • Merge pull request #1409 from JohnVillalovos/jlvillal/untyped_defs

chore: mypy: Disallow untyped definitions (562fbbd)

  • Merge pull request #1442 from python-gitlab/chore/fix-readthedocs

chore(docs): fix import order for readthedocs build (b563cdc)

  • Merge pull request #1441 from python-gitlab/docs/no-manpages-warnings

docs: fail on warnings during sphinx build (e46cacf)

  • Merge pull request #1438 from python-gitlab/fix/missing-group-attributes

fix(objects): add missing group attributes (5061972)

  • Merge pull request #1434 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.11.3-ce.0 (1e6305e)

  • Merge pull request #1437 from daniellanner/feat/api-code-owner-approval

feat: add code owner approval as attribute (d61e669)

  • Merge pull request #1433 from JohnVillalovos/jlvillal/black

chore: have black run at the top-level (09ef8d4)

  • Merge pull request #1429 from JohnVillalovos/jlvillal/flake8

chore: have flake8 check the entire project (b498ebd)

  • Merge pull request #1421 from JohnVillalovos/jlvillal/typed_gitlab

feat: indicate that we are a typed package (98891eb)

  • Merge pull request #1413 from JohnVillalovos/jlvillal/1407

fix: iids not working as a list in projects.issues.list() (a6b6cd4)

  • Merge pull request #1352 from JohnVillalovos/jlvillal/fix_mro

fix: add a check to ensure the MRO is correct (909aa9a)

  • Merge pull request #1415 from JohnVillalovos/jlvillal/list_attribute_int

feat: add support for lists of integers to ListAttribute (dde01c7)

  • Merge pull request #1412 from JohnVillalovos/jlvillal/optional_get_attrs

chore: make Get.*Mixin._optional_get_attrs always present (5b81d7d)

v2.7.1 (2021-04-26)#

Feature#

  • feat: add support for lists of integers to ListAttribute

Previously ListAttribute only support lists of integers. Now be more flexible and support lists of items which can be coerced into strings, for example integers.

This will help us fix issue #1407 by using ListAttribute for the ‘iids’ field. (115938b)

Fix#

  • fix(files): do not url-encode file paths twice (8e25cec)

Unknown#

  • Merge pull request #1418 from python-gitlab/fix/urlencode-file-paths

fix(files): do not url-encode filepaths twice (37af229)

v2.7.0 (2021-04-25)#

Chore#

  • chore(objects): remove noisy deprecation warning for audit events

It’s mostly an internal thing anyway and can be removed in 3.0.0 (2953642)

  • chore: make Get.*Mixin._optional_get_attrs always present

Always create GetMixin/GetWithoutIdMixin._optional_get_attrs attribute with a default value of tuple()

This way we don’t need to use hasattr() and we will know the type of the attribute. (3c1a0b3)

  • chore: make ListMixin._list_filters always present

Always create ListMixin._list_filters attribute with a default value of tuple().

This way we don’t need to use hasattr() and we will know the type of the attribute. (8933113)

  • chore: make RESTObject._short_print_attrs always present

Always create RESTObject._short_print_attrs with a default value of None.

This way we don’t need to use hasattr() and we will know the type of the attribute. (6d55120)

  • chore: bump version to 2.7.0 (34c4052)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.11.1-ce.0 (3088714)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.11.0-ce.0 (711896f)

  • chore: remove unused function sanitize_parameters()

The function sanitize_parameters() was used when the v3 API was in use. Since v3 API support has been removed there are no more users of this function. (443b934)

  • chore: fix F841 errors reported by flake8

Local variable name is assigned to but never used

https://www.flake8rules.com/rules/F841.html (40f4ab2)

  • chore: fix F401 errors reported by flake8

F401: Module imported but unused

https://www.flake8rules.com/rules/F401.html (ff21eb6)

  • chore: fix E711 error reported by flake8

E711: Comparison to none should be ‘if cond is none:’

https://www.flake8rules.com/rules/E711.html (630901b)

  • chore: fix E712 errors reported by flake8

E712: Comparison to true should be ‘if cond is true:’ or ‘if cond:’

https://www.flake8rules.com/rules/E712.html (83670a4)

  • chore: fix E741/E742 errors reported by flake8

Fixes to resolve errors for: https://www.flake8rules.com/rules/E741.html Do not use variables named ‘I’, ‘O’, or ‘l’ (E741)

https://www.flake8rules.com/rules/E742.html
  Do not define classes named &#39;I&#39;, &#39;O&#39;, or &#39;l&#39; (E742) ([`380f227`](https://github.com/python-gitlab/python-gitlab/commit/380f227a1ecffd5e22ae7aefed95af3b5d830994))
  • chore: fix typo in mr events (c5e6fb3)

  • chore(config): allow simple commands without external script (91ffb8e)

  • chore: have _create_attrs & _update_attrs be a namedtuple

Convert _create_attrs and _update_attrs to use a NamedTuple (RequiredOptional) to help with code readability. Update all code to use the NamedTuple. (aee1f49)

  • chore(deps): update dependency docker-compose to v1.29.1 (a89ec43)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.10.3-ce.0 (eabe091)

  • chore(deps): update dependency sphinx to v3.5.4 (a886d28)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.10.1-ce.0 (1995361)

  • chore(deps): update dependency docker-compose to v1.28.6 (46b05d5)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.10.0-ce.0 (5221e33)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.9.4-ce.0 (939f769)

  • chore: remove usage of getattr()

Remove usage of getattr(self, “_update_uses_post”, False)

Instead add it to class and set default value to False.

Add a tests that shows it is set to True for the ProjectMergeRequestApprovalManager and ProjectApprovalManager classes. (2afd18a)

  • chore: fix package file test naming (8c80268)

  • chore: add _create_attrs & _update_attrs to RESTManager

Add the attributes: _create_attrs and _update_attrs to the RESTManager class. This is so that we stop using getattr() if we don’t need to.

This also helps with type-hints being available for these attributes. (147f05d)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.9.3-ce.0 (2ddf45f)

  • chore: make _types always present in RESTManager

We now create _types = {} in RESTManager class.

By making _types always present in RESTManager it makes the code simpler. We no longer have to do: types = getattr(self, “_types”, {})

And the type checker now understands the type. (924f83e)

  • chore: make lint happy (7a7c9fd)

  • chore: make lint happy (b5f43c8)

  • chore: make lint happy (732e49c)

  • chore: import audit events in objects (35a190c)

  • chore: add type-hints for gitlab/mixins.py

    • Added type-hints for gitlab/mixins.py

    • Changed use of filter with a lambda expression to list-comprehension. mypy was not able to understand the previous code. Also list-comprehension is better :) (baea721)

  • chore(deps): update dependency sphinx to v3.5.2 (9dee5c4)

  • chore: add test (f8cf1e1)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.9.2-ce.0 (933ba52)

  • chore: put assert statements inside ‘if TYPE_CHECKING:’

To be safe that we don’t assert while running, put the assert statements, which are used by mypy to check that types are correct, inside an ‘if TYPE_CHECKING:’ block.

Also, instead of asserting that the item is a dict, instead assert that it is not a requests.Response object. Theoretically the JSON could return as a list or dict, though at this time we are assuming a dict. (b562458)

  • chore: add type hints to gitlab/base.py:RESTManager

Add some additional type hints to gitlab/base.py (9c55593)

  • chore: del ‘import *’ in gitlab/v4/objects/project_access_tokens.py

Remove usage of ‘import *’ in gitlab/v4/objects/project_access_tokens.py. (9efbe12)

  • chore: disallow incomplete type defs

Don’t allow a partially annotated function definition. Either none of the function is annotated or all of it must be.

Update code to ensure no-more partially annotated functions.

Update gitlab/cli.py with better type-hints. Changed Tuple[Any, …] to Tuple[str, …] (907634f)

  • chore(api): move repository endpoints into separate module (1ed154c)

  • chore: add additional type-hints for gitlab/base.py

Add type-hints for the variables which are set via self.dict

mypy doesn’t see them when they are assigned via self.dict. So declare them in the class definition. (ad72ef3)

  • chore: add and fix some type-hints in gitlab/client.py

Was able to figure out better type-hints for gitlab/client.py (8837207)

  • chore: remove import of gitlab.utils from init.py

Initially when extracting out the gitlab/client.py code we tried to remove this but functional tests failed.

Later we fixed the functional test that was failing, so now remove the unneeded import. (39b9183)

  • chore: add type-hints to gitlab/client.py

Adding some initial type-hints to gitlab/client.py (c9e5b4f)

  • chore: improve type-hints for gitlab/base.py

Determined the base class for obj_cls and adding type-hints for it. (cbd43d0)

  • chore(deps): update dependency docker-compose to v1.28.5 (f4ab558)

  • chore: add type-hints to gitlab/cli.py (10b7b83)

  • chore: add type-hints to gitlab/config.py (213e563)

  • chore: add type hints to gitlab/utils.py (acd9294)

  • chore: add type-hints to gitlab/const.py (a10a777)

  • chore(deps): update wagoid/commitlint-github-action action to v3 (b3274cf)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.9.1-ce.0 (f6fd995)

  • chore: remove usage of ‘from … import *’

In gitlab/v4/objects/*.py remove usage of:

  • from gitlab.base import *

  • from gitlab.mixins import *

Change them to:

  • from gitlab.base import CLASS_NAME

  • from gitlab.mixins import CLASS_NAME

Programmatically update code to explicitly import needed classes only.

After the change the output of: $ flake8 gitlab/v4/objects/*py | grep ‘REST|Mixin’

Is empty. Before many messages about unable to determine if it was a valid name. (c83eaf4)

  • chore: remove unused function _construct_url()

The function _construct_url() was used by the v3 API. All usage of the function was removed in commit fe89b949922c028830dd49095432ba627d330186 (009d369)

  • chore: add type hints to gitlab/base.py (3727cbd)

  • chore: remove usage of ‘from … import *’ in client.py

In gitlab/client.py remove usage of:

  • from gitlab.const import *

  • from gitlab.exceptions import *

Change them to:

  • import gitlab.const

  • import gitlab.exceptions

Update code to explicitly reference things in gitlab.const and gitlab.exceptions

A flake8 run no longer lists any undefined variables. Before it listed possible undefined variables. (bf0c8c5)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.9.0-ce.0 (3aef19c)

  • chore: explicitly import gitlab.v4.objects/cli

As we only support the v4 Gitlab API, explicitly import gitlab.v4.objects and gitlab.v4.clie instead of dynamically importing it depending on the API version.

This has the added benefit of mypy being able to type check the Gitlab init() function as currently it will fail if we enable type checking of init() it will fail.

Also, this also helps by not confusing tools like pyinstaller/cx_freeze with dynamic imports so you don’t need hooks for standalone executables. And according to https://docs.gitlab.com/ee/api/,

&#34;GraphQL co-exists with the current v4 REST API. If we have a v5 API, this
should be a compatibility layer on top of GraphQL.&#34; ([`233b79e`](https://github.com/python-gitlab/python-gitlab/commit/233b79ed442aac66faf9eb4b0087ea126d6dffc5))
  • chore(objects): make Project refreshable

Helps getting the real state of the project from the server. (958a6aa)

  • chore(tests): remove unused URL segment (66f0b6c)

  • chore(deps): update dependency docker-compose to v1.28.4 (8938484)

  • chore(deps): update dependency docker-compose to v1.28.3 (2358d48)

  • chore(deps): update dependency sphinx to v3.5.1 (f916f09)

  • chore: remove unused ALLOWED_KEYSET_ENDPOINTS variable

The variable ALLOWED_KEYSET_ENDPOINTS was added in commit f86ef3bbdb5bffa1348a802e62b281d3f31d33ad.

Then most of that commit was removed in commit e71fe16b47835aa4db2834e98c7ffc6bdec36723, but ALLOWED_KEYSET_ENDPOINTS was missed. (3d5d5d8)

  • chore: remove Python 2 code

httplib is a Python 2 library. It was renamed to http.client in Python 3.

https://docs.python.org/2.7/library/httplib.html (b5d4e40)

  • chore(deps): update dependency sphinx to v3.5.0 (188c5b6)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.8.4-ce.0 (832cb88)

  • chore(ci): deduplicate PR jobs (63918c3)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.8.3-ce.0 (e6c20f1)

  • chore(deps): update precommit hook alessandrojcm/commitlint-pre-commit-hook to v4 (505a8b8)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.8.2-ce.0 (7c12038)

  • chore(deps): update dependency sphinx to v3.4.3 (37c992c)

Documentation#

  • docs(api): add examples for resource state events (4d00c12)

  • docs: add information about the gitter community

Add a section in the README.rst about the gitter community. The badge already exists and is useful but very easy to miss. (6ff67e7)

  • docs(api): add release links API docs (36d65f0)

  • docs: add docs and examples for custom user agent (a69a214)

  • docs: change travis-ci badge to githubactions (2ba5ba2)

Feature#

  • feat(objects): add support for resource state events API (d4799c4)

  • feat: add ProjectPackageFile

Add ProjectPackageFile and the ability to list project package package_files.

Fixes #1372 (b9d469b)

  • feat(objects): add support for group audit events API (2a0fbdf)

  • feat: option to add a helper to lookup token (8ecf559)

  • feat(users): add follow/unfollow API (e456869)

  • feat(projects): add project access token api (1becef0)

  • feat: add an initial mypy test to tox.ini

Add an initial mypy test to test gitlab/base.py and gitlab/init.py (fdec039)

  • feat(objects): add Release Links API support (28d7518)

  • feat: add project audit endpoint (6660dbe)

  • feat: add personal access token API

See: https://docs.gitlab.com/ee/api/personal_access_tokens.html (2bb16fa)

  • feat(issues): add missing get verb to IssueManager (f78ebe0)

  • feat: import from bitbucket server

I’d like to use this libary to automate importing Bitbucket Server repositories into GitLab. There is a GitLab API endpoint to do this, but it is not exposed through this library.

  • Add an import_bitbucket_server method to the ProjectManager. This method calls this GitLab API endpoint: https://docs.gitlab.com/ee/api/import.html#import-repository-from-bitbucket-server

  • Modify import_gitlab method docstring for python3 compatibility

  • Add a skipped stub test for the existing import_github method (ff3013a)

  • feat(api,cli): make user agent configurable (4bb201b)

Fix#

  • fix: add a check to ensure the MRO is correct

Add a check to ensure the MRO (Method Resolution Order) is correct for classes in gitlab.v4.objects when doing type-checking.

An example of an incorrect definition: class ProjectPipeline(RESTObject, RefreshMixin, ObjectDeleteMixin): ^^^^^^^^^^ This should be at the end.

Correct way would be: class ProjectPipeline(RefreshMixin, ObjectDeleteMixin, RESTObject): Correctly at the end ^^^^^^^^^^

Also fix classes which have the issue. (565d548)

  • fix: correct ProjectFile.decode() documentation

ProjectFile.decode() returns ‘bytes’ and not ‘str’.

Update the method’s doc-string and add a type-hint.

ProjectFile.decode() returns the result of a call to base64.b64decode()

The docs for that function state it returns ‘bytes’: https://docs.python.org/3/library/base64.html#base64.b64decode

Fixes: #1403 (b180baf)

  • fix: update user’s bool data and avatar

If we want to update email, avatar and do not send email confirmation change (skip_reconfirmation = True), MultipartEncoder will try to encode everything except None and bytes. So it tries to encode bools. Casting bool’s values to their stringified int representation fix it. (3ba27ff)

  • fix: argument type was not a tuple as expected

While adding type-hints mypy flagged this as an issue. The third argument to register_custom_action is supposed to be a tuple. It was being passed as a string rather than a tuple of strings. (062f8f6)

  • fix: correct some type-hints in gitlab/mixins.py

Commit baea7215bbbe07c06b2ca0f97a1d3d482668d887 introduced type-hints for gitlab/mixins.py.

After starting to add type-hints to gitlab/v4/objects/users.py discovered a few errors.

Main error was using ‘=’ instead of ‘:’. For example: _parent = Optional[…] should be _parent: Optional[…]

Resolved those issues. (8bd3124)

  • fix: only append kwargs as query parameters

Some arguments to http_request were being read from kwargs, but kwargs is where this function creates query parameters from, by default. In the absence of a query_parameters param, the function would construct URLs with query parameters such as retry_transient_errors=True despite those parameters having no meaning to the API to which the request was sent.

This change names those arguments that are specific to http_request so that they do not end up as query parameters read from kwargs. (b9ecc9a)

  • fix: only add query_parameters to GitlabList once

Fixes #1386 (ca2c3c9)

  • fix(types): prevent dir from producing duplicates (5bf7525)

  • fix: checking if RESTManager._from_parent_attrs is set

Prior to commit 3727cbd21fc40b312573ca8da56e0f6cf9577d08 RESTManager._from_parent_attrs did not exist unless it was explicitly set. But commit 3727cbd21fc40b312573ca8da56e0f6cf9577d08 set it to a default value of {}.

So the checks using hasattr() were no longer valid.

Update the checks to check if RESTManager._from_parent_attrs has a value. (8224b40)

  • fix: handling config value in _get_values_from_helper (9dfb4cd)

  • fix: update doc for token helper (3ac6fa1)

  • fix: let the homedir be expanded in path of helper (fc7387a)

  • fix: make secret helper more user friendly (fc2798f)

  • fix(objects): add single get endpoint for instance audit events (c3f0a6f)

  • fix: linting issues and test (b04dd2c)

  • fix: better real life token lookup example (9ef8311)

  • fix: handle tags like debian/2%2.6-21 as identifiers

Git refnames are relatively free-form and can contain all sort for special characters, not just / and #, see http://git-scm.com/docs/git-check-ref-format

In particular, Debian’s DEP-14 standard for storing packaging in git repositories mandates the use of the % character in tags in some cases like debian/2%2.6-21.

Unfortunately python-gitlab currently only escapes / to %2F and in some cases # to %23. This means that when using the commit API to retrieve information about the debian/2%2.6-21 tag only the slash is escaped before being inserted in the URL path and the % is left untouched, resulting in something like /api/v4/projects/123/repository/commits/debian%2F2%2.6-21. When urllib3 seees that it detects the invalid % escape and then urlencodes the whole string, resulting in /api/v4/projects/123/repository/commits/debian%252F2%252.6-21, where the original / got escaped twice and produced %252F.

To avoid the issue, fully urlencode identifiers and parameters to avoid the urllib3 auto-escaping in all cases.

Signed-off-by: Emanuele Aina <emanuele.aina@collabora.com> (b4dac5c)

  • fix: remove duplicate class definitions in v4/objects/users.py

The classes UserStatus and UserStatusManager were each declared twice. Remove the duplicate declarations. (7c4e625)

  • fix: wrong variable name

Discovered this when I ran flake8 on the file. Unfortunately I was the one who introduced this wrong variable name :( (15ec41c)

  • fix: tox pep8 target, so that it can run

Previously running the pep8 target would fail as flake8 was not installed.

Now install flake8 for the pep8 target.

NOTE: Running the pep8 target fails as there are many warnings/errors. But it does allow us to run it and possibly work on reducing these warnings/errors in the future.

In addition, add two checks to the ignore list as black takes care of formatting. The two checks added to the ignore list are:

  • E501: line too long

  • W503: line break before binary operator (f518e87)

  • fix: undefined name errors

Discovered that there were some undefined names. (48ec9e0)

  • fix: extend wait timeout for test_delete_user()

Have been seeing intermittent failures of the test_delete_user() functional test. Have made the following changes to hopefully resolve the issue and if it still fails to know better why the failure occurred.

  • Extend the wait timeout for test_delete_user() from 30 to 60 tries of 0.5 seconds each.

  • Modify wait_for_sidekiq() to return True if sidekiq process terminated. Return False if the timeout expired.

  • Modify wait_for_sidekiq() to loop through all processes instead of assuming there is only one process. If all processes are not busy then return.

  • Modify wait_for_sidekiq() to sleep at least once before checking for processes being busy.

  • Check for True being returned in test_delete_user() call to wait_for_sidekiq() (19fde8e)

  • fix: test_update_group() dependency on ordering

Since there are two groups we can’t depend on the one we changed to always be the first one returned.

Instead fetch the group we want and then test our assertion against that group. (e78a8d6)

  • fix: honor parameter value passed

Gitlab allows setting the defaults for MR to delete the source. Also the inline help of the CLI suggest that a boolean is expected, but no matter what value you set, it will always delete. (c2f8f0e)

Refactor#

  • refactor(objects): move instance audit events where they belong (48ba88f)

  • refactor: move Gitlab and GitlabList to gitlab/client.py

Move the classes Gitlab and GitlabList from gitlab/init.py to the newly created gitlab/client.py file.

Update one test case that was depending on requests being defined in gitlab/init.py (53a7645)

  • refactor(api): explicitly export classes for star imports (f05c287)

  • refactor(v4): split objects and managers per API resource (a5a48ad)

Test#

  • test(object): add test for dir duplicates (a8e591f)

  • test(objects): add tests for resource state events (10225cf)

  • test(objects): add unit test for instance audit events (84e3247)

  • test: don’t add duplicate fixture

Co-authored-by: Nejc Habjan <hab.nejc@gmail.com> (5d94846)

  • test(api): add functional test for release links API (ab2a1c8)

  • test(api,cli): add tests for custom user agent (c5a37e7)

Unknown#

  • Merge pull request #1408 from python-gitlab/chore/bump-to-2-7-0

chore: bump version to 2.7.0 (e37de18)

  • Merge pull request #1411 from JohnVillalovos/jlvillal/list_filters

chore: make ListMixin._list_filters always present (62c75b5)

  • Merge pull request #1410 from JohnVillalovos/jlvillal/short_print_attr

chore: make RESTObject._short_print_attrs always present (09522b3)

  • Merge pull request #1414 from python-gitlab/chore/remove-noisy-deprecation-warning

chore(objects): remove noisy deprecation warning for audit events (0a0fcaf)

  • Merge pull request #1392 from bbatliner/patch-1

Improvements to HTTP requests (cfc42d2)

  • Merge pull request #1406 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.11.1-ce.0 (4f79dff)

  • Merge pull request #1405 from JohnVillalovos/jlvillal/returns_bytes

fix: correct ProjectFile.decode() documentation (c055de0)

  • Merge pull request #1397 from JohnVillalovos/jlvillal/flake8

Fix all issues reported by running: tox -e pep8 and enable pep8 as a linter check (976e14d)

  • Merge pull request #1404 from DylannCordel/fix-upd-user-bool-data-and-avatar

fix: update user’s bool data and avatar (5fac07a)

  • Merge pull request #1383 from spyoungtech/dirfix

fix(types): prevent dir in RestObject from producing duplicates (60c5fd8)

  • Merge pull request #1400 from JohnVillalovos/jlvillal/sanitize

chore: remove unused function sanitize_parameters() (dd236a0)

  • Merge pull request #1398 from JohnVillalovos/jlvillal/mypy_mixins

fix: correct some type-hints in gitlab/mixins.py (5b18d20)

  • Merge pull request #1399 from JohnVillalovos/jlvillal/fix_custom_action

fix: argument type was not a tuple as expected (fc4f7fd)

  • Merge pull request #1364 from python-gitlab/feat/resource-state-events

feat: add support for resource state events API (916a7fe)

  • Merge pull request #1359 from klorenz/feat_token_lookup

feat(config): allow using a credential helper to lookup tokens (af781c1)

  • Merge pull request #1375 from JohnVillalovos/jlvillal/update_uses_post

chore: remove usage of getattr() (d236267)

  • Merge pull request #1366 from JohnVillalovos/jlvillal/create_attrs

chore: have _create_attrs & _update_attrs be a namedtuple (d1697d4)

  • Merge pull request #1391 from python-gitlab/renovate/docker-compose-1.x

chore(deps): update dependency docker-compose to v1.29.1 (a6d3556)

  • Merge pull request #1380 from python-gitlab/renovate/sphinx-3.x

chore(deps): update dependency sphinx to v3.5.4 (6b86878)

  • Merge pull request #1363 from python-gitlab/feat/all-audit-events

Feat: cover all audit events (02ce49e)

  • Merge pull request #1382 from python-gitlab/renovate/docker-compose-1.x

chore(deps): update dependency docker-compose to v1.28.6 (e798c9b)

  • Merge pull request #1373 from JacobHenner/jacobhenner/add-package_files

feat: add support for Project Package Files (8ace76a)

  • Merge pull request #1371 from JohnVillalovos/jlvillal/create_attrs_1

chore: add _create_attrs & _update_attrs to RESTManager (8603248)

  • Merge pull request #1369 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.9.3-ce.0 (6fde243)

  • Merge pull request #1367 from JohnVillalovos/jlvillal/from_parent_attrs

fix: checking if RESTManager._from_parent_attrs is set (f93b9b5)

  • Merge pull request #1365 from JohnVillalovos/jlvillal/getattr

chore: make _types always present in RESTManager (de73ea7)

  • Merge pull request #1336 from em-/fix/quote-everything

fix: handle tags like debian/2%2.6-21 as identifiers (48fc907)

  • Merge pull request #1344 from JohnVillalovos/jlvillal/mixins

chore: add type-hints for gitlab/mixins.py (63ecd2e)

  • Merge pull request #1353 from JohnVillalovos/jlvillal/mypy_base

chore: add type hints to gitlab/base.py:RESTManager (ebdfec7)

  • Merge pull request #1350 from JohnVillalovos/jlvillal/isinstance

chore: Put assert statements inside ‘if TYPE_CHECKING:’ (c530f75)

  • Merge pull request #1361 from python-gitlab/renovate/sphinx-3.x

chore(deps): update dependency sphinx to v3.5.2 (c7a0669)

  • Merge pull request #1358 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.9.2-ce.0 (aa13214)

  • Merge pull request #1351 from JohnVillalovos/jlvillal/import_start

chore: del ‘import *’ in gitlab/v4/objects/project_access_tokens.py (96d2805)

  • Merge pull request #1342 from JohnVillalovos/jlvillal/mypy_incomplete

chore: disallow incomplete type defs (5f23ed9)

  • Merge pull request #1347 from python-gitlab/chore/split-repository-methods

chore(api): move repository endpoints into separate module (d8b8a0a)

  • Merge pull request #1343 from JohnVillalovos/jlvillal/mypy_testing_things

chore: add and fix some type-hints in gitlab/client.py (f5a65f0)

  • Merge pull request #1345 from JohnVillalovos/jlvillal/mypy_base_fixes

chore: add additional type-hints for gitlab/base.py (7441455)

  • Merge pull request #1333 from python-gitlab/feat/user-follow-api

feat(users): add follow/unfollow API (5bc158d)

  • Merge pull request #1339 from JohnVillalovos/jlvillal/mypy_client_py

chore: add type-hints to gitlab/client.py (b0d75d9)

  • Merge pull request #1341 from JohnVillalovos/jlvillal/gitter

doc: add information about the gitter community (adab83a)

  • Merge pull request #1340 from JohnVillalovos/jlvillal/gitlab_init

chore: remove import of gitlab.utils from init.py (d0eb1b5)

  • Merge pull request #1338 from JohnVillalovos/jlvillal/mypy_base

Improve type-hints for gitlab/base.py (cbd4f1e)

  • Merge pull request #1334 from JohnVillalovos/jlvillal/mypy_cli

chore: add type-hints to gitlab/cli.py (f909cae)

  • Merge pull request #1337 from python-gitlab/renovate/docker-compose-1.x

chore(deps): update dependency docker-compose to v1.28.5 (bd62fed)

  • Merge pull request #1335 from JohnVillalovos/jlvillal/remove_dup_classes

fix: remove duplicate class definitions in v4/objects/users.py (ecb686d)

  • Merge pull request #1328 from python-gitlab/renovate/wagoid-commitlint-github-action-3.x

chore(deps): update wagoid/commitlint-github-action action to v3 (6662252)

  • Merge pull request #1329 from JohnVillalovos/jlvillal/mypy_const

Add type-hints to gitlab/const.py (ca4c1d9)

  • Merge pull request #1330 from JohnVillalovos/jlvillal/mypy_utils

chore: add type hints to gitlab/utils.py (a1a8bfe)

  • Merge pull request #1331 from JohnVillalovos/jlvillal/mypy_config

chore: add type-hints to gitlab/config.py (d207074)

  • Merge pull request #1332 from JohnVillalovos/jlvillal/fix_variable

chore: fix wrong variable name in cli.py (665c0c3)

  • Merge pull request #1319 from JohnVillalovos/jlvillal/import_star

chore: remove usage of ‘from … import *’ (0b67ca2)

  • Merge pull request #1327 from python-gitlab/feat/project-access-token-api

feat(projects): add project access token api (e06c51b)

  • Merge pull request #1325 from JohnVillalovos/jlvillal/pep8

fix: tox pep8 target, so that it can run (bb227d3)

  • Merge pull request #1322 from JohnVillalovos/jlvillal/missing_vars

fix: undefined name errors in v4 objects (a7ec67f)

  • Merge pull request #1321 from JohnVillalovos/jlvillal/remove_cruft

chore: remove unused function _construct_url() (d90be1e)

  • Merge pull request #1299 from JohnVillalovos/mypy

Enable mypy type checking and add type hints to gitlab/base.py (a18bc5c)

  • Merge pull request #1318 from JohnVillalovos/jlvillal/testing

chore: remove usage of ‘from … import *’ in client.py (d9fdf1d)

  • Merge pull request #1310 from JohnVillalovos/jlvillal/v4_only

chore: explicitly import gitlab.v4.objects/cli (8c58b07)

  • Merge pull request #1316 from JohnVillalovos/jlvillal/test_wait

test: extend wait timeout for test_delete_user() (5cc60d5)

  • Merge pull request #1314 from python-gitlab/feat/release-links

feat: add release links API support (2b29776)

  • Merge pull request #1311 from JohnVillalovos/jlvillal/fix_functional

fix: test_update_group() dependency on ordering (3381700)

  • Merge pull request #1307 from python-gitlab/renovate/docker-compose-1.x

chore(deps): update dependency docker-compose to v1.28.4 (649385c)

  • Merge pull request #1308 from Sineaggi/add-project-audit-endpoint

feat: add project audit endpoint (0c5a23e)

  • Merge pull request #1301 from JohnVillalovos/refactor_jlvillal

refactor: move Gitlab and GitlabList to gitlab/client.py (2c4fcf8)

  • Merge pull request #1305 from python-gitlab/renovate/docker-compose-1.x

chore(deps): update dependency docker-compose to v1.28.3 (d4e7a03)

  • Merge pull request #1304 from python-gitlab/feat/personal-access-token-api

feat: add personal access token API (ef8fcf7)

  • Merge pull request #1300 from JohnVillalovos/remove_cruft

chore: remove unused ALLOWED_KEYSET_ENDPOINTS variable (bec2094)

  • Merge pull request #1303 from python-gitlab/renovate/sphinx-3.x

chore(deps): update dependency sphinx to v3.5.1 (9f6691d)

  • Merge pull request #1271 from allcloud-jonathan/feature/honor-bool-for-delete-source

fix: honor parameter value passed (1552eb5)

  • Merge pull request #1298 from JohnVillalovos/master

Remove Python 2 code (07edafe)

  • Merge pull request #1288 from python-gitlab/refactor/split-objects

refactor(v4): split objects and managers per API resource (9fcd962)

  • Merge pull request #1295 from python-gitlab/renovate/sphinx-3.x

chore(deps): update dependency sphinx to v3.5.0 (76e6f87)

  • Merge pull request #1292 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.8.4-ce.0 (45fc49e)

  • Merge pull request #1223 from python-gitlab/feat/single-issue-api

feat(issues): add missing get verb to IssueManager (9d6c188)

  • Merge pull request #1287 from python-gitlab/chore/deduplicate-pr-jobs

chore(ci): deduplicate PR jobs (9fe506f)

  • Merge pull request #1283 from fajpunk/import_bitbucket

feat: import from bitbucket server (b48563f)

  • Merge pull request #1244 from python-gitlab/renovate/alessandrojcm-commitlint-pre-commit-hook-4.x

chore(deps): update precommit hook alessandrojcm/commitlint-pre-commit-hook to v4 (3935baf)

  • Merge pull request #1281 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.8.2-ce.0 (1d9155c)

  • Merge pull request #1225 from python-gitlab/renovate/sphinx-3.x

chore(deps): update dependency sphinx to v3.4.3 (a985c34)

  • Merge pull request #1277 from python-gitlab/feat/override-user-agent

feat(api,cli): make user agent configurable (643454c)

  • Merge pull request #1276 from python-gitlab/bufferoverflow-patch-1

docs: switch from travis-ci.org to GitHub Actions (071d699)

v2.6.0 (2021-01-29)#

Chore#

  • chore: offically support and test 3.9 (62dd07d)

  • chore(deps): pin dependency requests-toolbelt to ==0.9.1 (4d25f20)

  • chore(deps): update dependency requests to v2.25.1 (9c2789e)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.8.1-ce.0 (9854d6d)

  • chore(ci): add coverage and docs jobs (2de64cf)

  • chore(ci): force colors in pytest runs (1502079)

  • chore(ci): pin docker-compose install for tests

This ensures python-dotenv with expected behavior for .env processing (1f7a2ab)

  • chore(ci): pin os version (cfa27ac)

  • chore(ci): fix typo in matrix (5e1547a)

  • chore(ci): fix copy/paste oopsie (c6241e7)

  • chore(ci): add pytest PR annotations (8f92230)

  • chore(ci): replace travis with Actions (8bb73a3)

  • chore: move .env into docker-compose dir (55cbd1c)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.5.4-ce.0 (265dbbd)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.5.3-ce.0 (d1b0b08)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.5.2-ce.0 (4a6831c)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.5.1-ce.0 (348e860)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.5.0-ce.0 (fc205cc)

  • chore(docs): always edit the file directly on master

There is no way to edit the raw commit (35e43c5)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.4.3-ce.0 (bc17889)

  • chore(cli): remove python2 code (1030e0a)

  • chore: apply suggestions (65ce026)

  • chore(deps): update python docker tag to v3.9 (1fc65e0)

  • chore: simplified search scope constants (16fc048)

  • chore: added docs for search scopes constants (7565bf0)

  • chore: use helper fixtures for test directories (40ec2f5)

  • chore: allow overriding docker-compose env vars for tag (27109ca)

  • chore: remove unnecessary random function (d4ee0a6)

  • chore(deps): pin dependencies (14d8f77)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.3.6-ce.0 (57b5782)

  • chore(test): remove hacking dependencies (9384493)

  • chore(ci): add .readthedocs.yml (0ad441e)

  • chore(ci): reduce renovate PR noise (f4d7a55)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.3.5-ce.0 (c88d870)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.3.4-ce.0 (e94c4c6)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.3.3-ce.0 (667bf01)

Documentation#

  • docs(cli-usage): fixed term (d282a99)

  • docs(readme): update supported Python versions (20b1e79)

  • docs(cli): use inline anonymous references for external links

There doesn’t seem to be an obvious way to use an alias for identical text labels that link to different targets. With inline links we can work around this shortcoming. Until we know better. (f2cf467)

  • docs(groups): add example for creating subgroups (92eb4e3)

  • docs: clean up grammar and formatting in documentation (aff9bc7)

  • docs: add Project Merge Request approval rule documentation (449fc26)

  • docs(readme): also add hint to delete gitlab-runner-test

Otherwise the whole testsuite will refuse to run (8894f2d)

  • docs(issues): add admin, project owner hint

Closes #1101 (609c03b)

  • docs(projects): correct fork docs

Closes #1126 (54921db)

  • docs(cli): add example for job artifacts download (375b29d)

  • docs(cli): add auto-generated CLI reference (6c21fc8)

Feature#

  • feat: support multipart uploads (2fa3004)

  • feat(tests): test label getter (a41af90)

  • feat: add MINIMAL_ACCESS constant

A “minimal access” access level was introduced in GitLab 13.5. (49eb3ca)

  • feat: unit tests added (f37ebf5)

  • feat: added support for pipeline bridges (05cbdc2)

  • feat: adds support for project merge request approval rules (#1199) (c6fbf39)

  • feat(api): added wip filter param for merge requests (d6078f8)

  • feat(api): added wip filter param for merge requests (aa6e80d)

  • feat(api): add support for user identity provider deletion (e78e121)

Fix#

  • fix(api): use RetrieveMixin for ProjectLabelManager

Allows to get a single label from a project, which was missing before even though the GitLab API has the ability to. (1a14395)

  • fix(base): really refresh object

This fixes and error, where deleted attributes would not show up

Fixes #1155 (e1e0d8c)

  • fix(cli): write binary data to stdout buffer (0733ec6)

  • fix(cli): add missing args for project lists (c73e237)

  • fix: docs changed using the consts (650b65c)

  • fix: typo (9baa905)

  • fix(api): add missing runner access_level param (92669f2)

Refactor#

  • refactor(tests): split functional tests (61e43eb)

Test#

  • test: ignore failing test for now (4b4e253)

  • test: add test_project_merge_request_approvals.py (9f6335f)

  • test(cli): add test for job artifacts download (f4e7950)

  • test(env): replace custom scripts with pytest and docker-compose (79489c7)

  • test: add unit tests for badges API (2720b73)

  • test: add unit tests for resource label events API (e9a211c)

Unknown#

  • Merge pull request #1273 from python-gitlab/chore/python3-9

chore: offically support and test 3.9 (48cb89b)

  • Merge pull request #1230 from manuel-91/patch-1

cli-usage readme: fixed term (55c8c96)

  • Merge pull request #1238 from atombrella/install_version_doc

Updated supported Python versions in install doc (d037a71)

  • Merge pull request #1255 from bittner/docs/fix-external-links-tokens

Use inline anonymous references for external links (762f959)

  • Merge pull request #1251 from hchouraria/patch-1

docs(groups): add example for creating subgroups (5ac309a)

  • Merge pull request #1272 from python-gitlab/renovate/pin-dependencies

chore(deps): pin dependency requests-toolbelt to ==0.9.1 (b567522)

  • Merge pull request #1233 from python-gitlab/renovate/requests-2.x

chore(deps): update dependency requests to v2.25.1 (78a02ce)

  • Merge pull request #1243 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.8.1-ce.0 (cc2dd0c)

  • Merge pull request #1252 from python-gitlab/feat/multipart-uploads

feat: support multipart uploads (4f8d901)

  • Merge pull request #1269 from nejch/fix/test-env

chore(ci): bring test environment back to life (fd179d4)

  • Merge pull request #1250 from JacobHenner/feature/add-minimal-access

feat: Add MINIMAL_ACCESS constant (fac0874)

  • Merge pull request #1263 from ePirat/epirat-fix-get-label

fix(api): add missing GetMixin to ProjectLabelManager (e61a0f2)

  • Merge pull request #1200 from robinson96/feature/project_merge_request_approval_rules

Feature/project merge request approval rules (6035ca8)

  • Merge pull request #1213 from python-gitlab/fix/delete-attr

fix(base): really refresh object (af965d4)

  • Merge pull request #1212 from python-gitlab/chore/docs-edit-on-master

chore(docs): always edit the file directly on master (ce8460f)

  • Merge pull request #1211 from python-gitlab/docs/admin-project-owner

docs(issues): add admin, project owner hint (e5b047d)

  • Merge pull request #1214 from python-gitlab/docs/readme-gitlab-runner-test

docs(readme): also add hint to delete gitlab-runner-test (53b4c2f)

  • Merge pull request #1210 from python-gitlab/docs/projects-correct-fork

docs(projects): correct fork docs (77ac8c3)

  • Merge pull request #1202 from python-gitlab/fix/cli-binary-data

fix(cli): write binary data to stdout buffer (3a38c6d)

  • Merge pull request #1209 from python-gitlab/docs/cli-reference-page

docs(cli): add auto-generated CLI reference (9054a3b)

  • Merge pull request #1131 from valentingregoire/master

feat: added constants for search API (8cb8040)

  • Merge pull request #1205 from python-gitlab/refactor/split-functional-tests

refactor(tests): split functional tests (68a4162)

  • Merge pull request #1204 from python-gitlab/renovate/docker-python-3.x

chore(deps): update python docker tag to v3.9 (2002098)

  • Merge pull request #1203 from intostern/feat/bridge

Added support for pipeline bridges (c303dab)

  • Merge pull request #1206 from python-gitlab/fix/cli-project-list-args

fix(cli): add missing args for project lists (be0afdd)

  • Merge pull request #1178 from python-gitlab/test/cleanup-env

test(env): replace custom scripts with pytest and docker-compose (266030a)

  • Merge pull request #1177 from python-gitlab/renovate/pin-dependencies

chore(deps): pin dependencies (0d89a6e)

  • Merge pull request #1189 from python-gitlab/chore/test-hacking-dependency

chore(test): remove hacking dependencies (d51042a)

  • Merge pull request #1180 from Shkurupii/add-unittests-for-project-badges

test: add unit tests for badges API (6bdb7f8)

  • Merge pull request #1184 from python-gitlab/fix/runner-access-level

fix(api): add missing runner access_level param (a7c20ca)

  • Merge pull request #1182 from jlpospisil/allow-mr-search-by-wip

Added MR wip filter param (74c1e4f)

  • Merge pull request #1181 from python-gitlab/feat/delete-user-identities

feat(api): add support for user identity provider deletion (35f9cb8)

  • Merge pull request #1179 from python-gitlab/chore/readthedocs-yml

chore(ci): add .readthedocs.yml (49a0032)

  • Merge pull request #1175 from python-gitlab/chore/noisy-renovate

chore(ci): reduce renovate PR noise (8d662ab)

  • Merge pull request #1174 from Shkurupii/add-unittests-for-resource-label-events

Add unit tests for resource label events API (b1c2045)

  • Merge pull request #1173 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.3.5-ce.0 (24fdbef)

  • Merge pull request #1172 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.3.4-ce.0 (2a6801e)

  • Merge pull request #1171 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.3.3-ce.0 (769367c)

v2.5.0 (2020-09-01)#

Chore#

  • chore: bump python-gitlab to 2.5.0 (56fef01)

  • chore(deps): update python docker tag to v3.8 (a8070f2)

  • chore(deps): update gitlab/gitlab-ce docker tag to v13.3.2-ce.0 (9fd778b)

  • chore(test): use pathlib for paths (5a56b6b)

  • chore(ci): pin gitlab-ce version for renovate (cb79fb7)

  • chore(env): add pre-commit and commit-msg hooks (82070b2)

  • chore(ci): use fixed black version (9565684)

  • chore: make latest black happy with existing code (6961479)

  • chore: update tools dir for latest black version (f245ffb)

  • chore: make latest black happy with existing code (d299753)

  • chore: update tools dir for latest black version (c2806d8)

  • chore: remove unnecessary import (f337b7a)

  • chore: make latest black happy with existing code (4039c8c)

  • chore: run unittest2pytest on all unit tests (11383e7)

  • chore: remove remnants of python2 imports (402566a)

Documentation#

  • docs(variables): add docs for instance-level variables (ad4b87c)

  • docs(packages): add examples for Packages API and cli usage (a47dfcd)

  • docs(api): add example for latest pipeline job artifacts (d20f022)

  • docs(cli): add examples for group-project list (af86dcd)

  • docs: additional project file delete example

Showing how to delete without having to pull the file (9e94b75)

Feature#

  • feat(api): add support for instance variables (4492fc4)

  • feat(api): add support for Packages API (71495d1)

  • feat(api): add endpoint for latest ref artifacts (b7a07fc)

  • feat: add support to resource milestone events

Fixes #1154 (88f8cc7)

  • feat: add share/unshare group with group (7c6e541)

Fix#

  • fix: wrong reconfirmation parameter when updating user’s email

Since version 10.3 (and later), param to not send (re)confirmation when updating an user is skip_reconfirmation (and not skip_confirmation).

See:

  • https://gitlab.com/gitlab-org/gitlab-foss/-/merge_requests/15175?tab=

  • https://docs.gitlab.com/11.11/ee/api/users.html#user-modification

  • https://docs.gitlab.com/ee/api/users.html#user-modification (b5c267e)

  • fix: tests fail when using REUSE_CONTAINER option

Fixes #1146 (0078f89)

  • fix: implement Gitlab’s behavior change for owned=True (9977799)

Refactor#

  • refactor: turn objects module into a package (da8af6f)

  • refactor: rewrite unit tests for objects with responses (204782a)

  • refactor: split unit tests by GitLab API resources (76b2cad)

Test#

  • test(api): add tests for variables API (66d108d)

  • test(packages): add tests for Packages API (7ea178b)

  • test: add unit tests for resource milestone events API

Fixes #1154 (1317f4b)

Unknown#

  • Merge pull request #1170 from python-gitlab/chore/bump-to-2-5-0

chore: bump python-gitlab to 2.5.0 (784cba6)

  • Merge pull request #1168 from python-gitlab/renovate/docker-python-3.x

chore(deps): update python docker tag to v3.8 (cf32499)

  • Merge pull request #1163 from python-gitlab/feat/instance-variables-api

Feat: add support for instance variables API (723ca88)

  • Merge pull request #1167 from python-gitlab/renovate/docker-gitlab-gitlab-ce-13.x

chore(deps): update gitlab/gitlab-ce docker tag to v13.3.2-ce.0 (6e1ed68)

  • Merge pull request #1165 from DylannCordel/fix-user-email-reconfirmation

fix: wrong reconfirmation parameter when updating user’s email (97e1dcc)

  • Merge pull request #1164 from nejch/master

chore(ci): pin gitlab-ce version for renovate (e6a9ba9)

  • Merge pull request #1162 from python-gitlab/chore/pre-commit-config

chore(env): add pre-commit and commit-msg hooks (97d8261)

  • Merge pull request #1161 from python-gitlab/chore/ci-fixed-black-version

chore(ci): use fixed black version (28aa17e)

  • Merge pull request #1157 from Shkurupii/issue-1154

Add support to resource milestone events (750f4ee)

  • Merge pull request #1159 from python-gitlab/feat/project-artifacts

Feat: Project job artifacts for latest successful pipeline (26f95f3)

  • Merge pull request #1160 from python-gitlab/feat/packages-api

Feat: Add support for packages API (0f42e32)

  • Merge branch ‘master’ into issue-1154 (fa899d7)

  • Merge pull request #1156 from python-gitlab/docs/group-projects-list-cli

docs(cli): add examples for group-project list (a038e95)

  • Merge pull request #1078 from python-gitlab/refactor/split-unit-tests

Refactor: split unit tests by API resources (a7e44a0)

  • Merge pull request #1147 from ericfrederich/fix-1146

fix: tests fail when using REUSE_CONTAINER option (e2dc9ec)

  • Merge pull request #1139 from sathieu/share_group_with_group

feat: add share/unshare the group with a group (cfa8097)

  • Merge pull request #1152 from matthew-a-dunlap/doc-project-file-delete-example

docs: additional project file delete example (5b92de8)

v2.4.0 (2020-07-09)#

Chore#

  • chore: bump version to 2.4.0 (1606310)

  • chore: added constants for search API (8ef53d6)

Feature#

  • feat: added NO_ACCESS const

This constant is useful for cases where no access is granted, e.g. when creating a protected branch.

The NO_ACCESS const corresponds to the definition in https://docs.gitlab.com/ee/api/protected_branches.html (dab4d0a)

Fix#

  • fix: add masked parameter for variables command (b6339bf)

  • fix: do not check if kwargs is none

Co-authored-by: Traian Nedelea <tron1point0@pm.me> (a349b90)

  • fix: make query kwargs consistent between call in init and next (72ffa01)

  • fix: pass kwargs to subsequent queries in gitlab list (1d011ac)

  • fix(merge): parse arguments as query_data (878098b)

Unknown#

  • Merge pull request #1108 from stuartgunter/master

Added NO_ACCESS const (3a76d91)

  • Merge pull request #1092 from aparcar/aparcar-patch-1

Update pipelines_and_jobs.rst (12a40cc)

  • Merge pull request #1124 from tyates-indeed/fix-1123

Pass kwargs to subsequent queries in GitlabList (fixes: #1123) (424a8cb)

  • Merge pull request #1127 from gervasek/master

Add masked parameter for project-variable and group-variable (bfb5034)

  • Merge pull request #1121 from ferhat-aram/fix/bad-merge-request-arg-parsing

fix(merge): parse arguments as query_data (1d82310)

v2.3.1 (2020-06-09)#

Chore#

  • chore: bump version to 2.3.1 (870e7ea)

Fix#

  • fix: disable default keyset pagination

Instead we set pagination to offset on the other paths (e71fe16)

Unknown#

  • Merge pull request #1115 from python-gitlab/fix/keyset-pagination-revert

Fix/keyset pagination revert (3f585ad)

v2.3.0 (2020-06-08)#

Chore#

  • chore: correctly render rst (f674bf2)

  • chore: bump to 2.3.0 (01ff865)

  • chore(ci): add codecov integration to Travis (e230568)

  • chore(test): remove outdated token test (e6c9fe9)

  • chore: bring commit signatures up to date with 12.10 (dc382fe)

  • chore: fix typo in docstring (c20f5f1)

  • chore: remove old builds-email service (c60e2df)

  • chore(services): update available service attributes (7afc357)

  • chore: use pytest for unit tests and coverage (9787a40)

Ci#

  • ci: lint fixes (930122b)

  • ci: add a test for creating and triggering pipeline schedule (9f04560)

Documentation#

  • docs(remote_mirrors): fix create command (1bb4e42)

  • docs(remote_mirrors): fix create command (bab91fe)

  • docs(pipelines): simplify download

This uses a context instead of inventing your own stream handler which makes the code simpler and should be fine for most use cases.

Signed-off-by: Paul Spooren <mail@aparcar.org> (9a068e0)

  • docs: update authors (ac0c84d)

  • docs(readme): add codecov badge for master (e21b2c5)

  • docs(readme): update test docs (6e2b1ec)

Feature#

  • feat: add group runners api (4943991)

  • feat: add play command to project pipeline schedules

fix: remove version from setup

feat: add pipeline schedule play error exception

docs: add documentation for pipeline schedule play (07b9988)

  • feat(api): added support in the GroupManager to upload Group avatars (28eb7ea)

  • feat: allow an environment variable to specify config location

It can be useful (especially in scripts) to specify a configuration location via an environment variable. If the “PYTHON_GITLAB_CFG” environment variable is defined, treat its value as the path to a configuration file and include it in the set of default configuration locations. (401e702)

  • feat(services): add project service list API

Can be used to list available services It was introduced in GitLab 12.7 (fc52221)

  • feat(types): add dir to RESTObject to expose attributes (cad134c)

Fix#

  • fix: use keyset pagination by default for /projects > 50000

Workaround for https://gitlab.com/gitlab-org/gitlab/-/issues/218504. Remove this in 13.1 (f86ef3b)

  • fix(config): fix duplicate code

Fixes #1094 (ee2df6f)

  • fix(project): add missing project parameters (ad8c67d)

Test#

  • test: disable test until Gitlab 13.1 (63ae77a)

  • test(runners): add all runners unit tests (127fa5a)

  • test(cli): convert shell tests to pytest test cases (c4ab4f5)

Unknown#

  • Merge pull request #1112 from python-gitlab/fix/rst-renderer

chore: correctly render rst (1f7dbc8)

  • Merge pull request #1111 from python-gitlab/chore/bump-version-2-3-0

chore: bump to 2.3.0 (a16ff3f)

  • Merge pull request #1110 from python-gitlab/fix/keyset-pagination

Fix keyset pagination in 13.0 (f10dd38)

  • Merge pull request #1102 from dotenorio/master

Update doc for remote_mirrors (ef6181b)

  • Merge branch ‘master’ of github.com:dotenorio/python-gitlab (f5f4e12)

  • Merge pull request #1089 from python-gitlab/feat/group-runners

feat: add group runners api (38e9fde)

  • Merge pull request #1087 from python-gitlab/docs/update-authors

docs: update authors (89007c9)

  • Merge pull request #1099 from python-gitlab/fix/duplicate-code

fix(config): fix duplicate code (242cf65)

  • Merge pull request #1086 from python-gitlab/test/pytest-cli-tests

test(cli): convert CLI shell tests to pytest test cases (74b3ddc)

  • Merge pull request #1085 from python-gitlab/chore/codecov-travis

chore(ci): add codecov integration to Travis (91c1c27)

  • Merge pull request #1082 from python-gitlab/chore/signature-gpg-x509

chore: bring commit signatures up to date with 12.10 (5a75310)

  • Merge pull request #1069 from zillow/feat/add-custom-pipeline-schedule-play

feat: Add play command to project pipeline schedules (9d66cb3)

  • Merge pull request #1077 from Flor1an-dev/master

feat(api): added support in the GroupManager to upload Group avatars (7907e5a)

  • Merge pull request #1075 from python-gitlab/feat/available-services

feat(services): add project service list API (dad505c)

  • Merge pull request #1074 from jeremycline/environment-variable

feat: Allow an environment variable to specify config location (0c3b717)

  • Merge pull request #1073 from python-gitlab/docs/readme-test-docs

docs(readme): update test docs (70cefe4)

  • Merge pull request #1072 from spyoungtech/feat/restobject-dir

feat(types): add dir to RESTObject to expose attributes (c7c431a)

  • Merge pull request #1066 from nejch/chore/pytest-for-unit-tests

chore: use pytest to run unit tests and coverage (efc6182)

  • Merge pull request #1067 from python-gitlab/fix/missing-project-attributes

fix(project): add missing project parameters (29fd95e)

v2.2.0 (2020-04-07)#

Chore#

  • chore: bump to 2.2.0 (22d4b46)

  • chore(group): update group_manager attributes (#1062)

  • chore(group): update group_manager attributes

Co-Authored-By: Nejc Habjan <hab.nejc@gmail.com> (fa34f5e)

  • chore: rename ExportMixin to DownloadMixin (847da60)

  • chore(mixins): factor out export download into ExportMixin (6ce5d1f)

  • chore: use raise..from for chained exceptions (#939) (79fef26)

  • chore: fix typo in allow_failures (265bbdd)

  • chore: pass environment variables in tox (e06d33c)

  • chore: improve and document testing against different images (98d3f77)

  • chore: remove references to python2 in test env (6e80723)

  • chore: clean up for black and flake8 (4fede5d)

  • chore: flatten test_import_github (b8ea96c)

  • chore: move test_import_github into TestProjectImport (a881fb7)

Documentation#

  • docs: add docs for Group Import/Export API (8c3d744)

  • docs: fix comment of prev_page()

Co-Authored-By: Nejc Habjan <hab.nejc@gmail.com> (b066b41)

  • docs: fix comment of prev_page()

Co-Authored-By: Nejc Habjan <hab.nejc@gmail.com> (ac6b2da)

  • docs: fix comment of prev_page() (7993c93)

Feature#

  • feat(api): add support for remote mirrors API (#1056) (4cfaa2f)

  • feat(api): add support for Gitlab Deploy Token API (01de524)

  • feat(api): add support for Group Import/Export API (#1037) (6cb9d92)

  • feat: add support for commit GPG signature API (da7a809)

  • feat: add create from template args to ProjectManager

This commit adds the v4 Create project attributes necessary to create a project from a project, instance, or group level template as documented in https://docs.gitlab.com/ee/api/projects.html#create-project (f493b73)

Fix#

  • fix(types): do not split single value string in ListAttribute (a26e585)

  • fix: add missing import_project param (9b16614)

Test#

  • test(api): add tests for group export/import API (e7b2d6c)

  • test(types): reproduce get_for_api splitting strings (#1057) (babd298)

  • test: create separate module for commit tests (8c03771)

  • test: move mocks to top of module (0bff713)

  • test: add unit tests for Project Import (f7aad5f)

  • test: add unit tests for Project Export (600dc86)

  • test: prepare base project test class for more tests (915587f)

Unknown#

  • Merge pull request #1059 from python-gitlab/fix/raise-from

chore: use raise..from for chained exceptions (#939) (6749859)

  • Merge pull request #1052 from machine424/deploy-tokens-support

feat(api): add support for Gitlab Deploy Token API (5979750)

  • Merge pull request #1064 from python-gitlab/feat/project-remote-mirrors

feat(api): add support for remote mirrors API (#1056) (3396aa5)

  • Merge pull request #1063 from python-gitlab/feat/group-import-export

Feat: support for group import/export API (c161852)

  • Merge pull request #1058 from python-gitlab/fix/listattribute-get-api-splits-string

Fix: ListAttribute get_for_api() splits strings (50fcd12)

  • Merge pull request #1053 from lassimus/master

feat: add create from template args to ProjectManager (c5904c4)

  • Merge pull request #1054 from nejch/chore/cleanup-test-env

chore: improve test environment for upcoming features (8173021)

  • Merge pull request #1055 from nejch/feat/commit-gpg-signature

feat: add support for commit GPG signature (1b8e748)

  • Merge pull request #1049 from donhui/typo-fix

  • docs: fix comment of prev_page() (82deb7d)

  • Merge pull request #1040 from nejch/test/project-export-import

test: update tests and params for project export/import (4ffaf1d)

v2.1.2 (2020-03-09)#

Chore#

  • chore: bump version to 2.1.2 (ad7e2bf)

Unknown#

  • Merge pull request #1045 from python-gitlab/revert-1003-feat/all-keyset-pagination

Revert “feat: use keyset pagination by default for all=True” (6d941bd)

  • Revert “feat: use keyset pagination by default for all=True” (6f843b6)

v2.1.1 (2020-03-09)#

Chore#

  • chore: bump version to 2.1.1 (6c5458a)

  • chore(user): update user attributes to 12.8 (666f880)

Fix#

  • fix(docs): additional project statistics example (5ae5a06)

Unknown#

  • Merge pull request #1043 from python-gitlab/chore/update-user-attributes

chore(user): update user attributes to 12.8 (8c44bb6)

  • Merge pull request #1042 from khuedoan98/patch-1

fix(docs): additional project statistics example (be5b15e)

v2.1.0 (2020-03-08)#

Chore#

  • chore: bump version to 2.1.0 (47cb58c)

  • chore: fix broken requests links

Another case of the double slash rewrite. (b392c21)

  • chore: ensure developers use same gitlab image as Travis (fab17fc)

Documentation#

  • docs: add reference for REQUESTS_CA_BUNDLE (37e8d5d)

  • docs(pagination): clear up pagination docs

Co-Authored-By: Mitar <mitar.git@tnode.com> (1609824)

Feature#

  • feat(api): add support for GitLab OAuth Applications API (4e12356)

  • feat: add support for user memberships API (#1009) (c313c2b)

  • feat: add support for commit revert API (#991) (5298964)

  • feat: add capability to control GitLab features per project or group (7f192b4)

Fix#

  • fix(projects): correct copy-paste error (adc9101)

  • fix: do not require empty data dict for create() (99d959f)

  • fix: remove trailing slashes from base URL (#913) (2e396e4)

  • fix(docs): fix typo in user memberships example (33889bc)

  • fix: return response with commit data (b77b945)

  • fix(objects): add default name data and use http post

Updating approvers new api needs a POST call. Also It needs a name of the new rule, defaulting this to ‘name’. (70c0cfb)

  • fix: remove null values from features POST data, because it fails with HTTP 500 (1ec1816)

Performance#

  • perf: prepare environment when gitlab is reconfigured (3834d9c)

Style#

  • style: fix black violations (ad3e833)

Test#

  • test: add unit tests for base URLs with trailing slashes (32844c7)

  • test: remove duplicate resp_get_project (cb43695)

  • test: use lazy object in unit tests (31c6562)

  • test: add unit tests for revert commit API (d7a3066)

Unknown#

  • Merge pull request #1039 from python-gitlab/fix/set-approvers

Fix/set approvers (481bd4f)

  • Merge pull request #1038 from nejch/fix/allow-empty-create-data

Fix: do not require empty data dict for create() (ca37d23)

  • Merge pull request #1034 from filipowm/feat/api-oauth-applications

feat(api): add support for GitLab OAuth Applications using Applications API (e5afb55)

  • Merge pull request #1032 from nejch/docs/requests-ca-bundle

docs: add reference to REQUESTS_CA_BUNDLE usage (fbcc820)

  • Merge pull request #1003 from python-gitlab/feat/all-keyset-pagination

feat: use keyset pagination by default for all=True (3aa9873)

  • Merge pull request #1022 from nejch/chore/ensure-latest-image

chore: ensure developers use same gitlab image as CI (745bdf7)

  • Merge pull request #1023 from nejch/perf/wait-gitlab-reconfigure

perf: wait for gitlab to reconfigure instead of using hardcoded sleep (2b3871d)

  • Merge pull request #1026 from nejch/feat/user-memberships

feat: add support for user memberships API (#1009) (f071390)

  • Merge pull request #1027 from nejch/fix/base-url-trailing-slash

Fix: remove trailing slash in base URL (292dfff)

  • Merge pull request #1020 from nejch/feat/revert-commit-api

feat: add support for commit revert API (#991) (e8f0921)

  • Merge pull request #1005 from charlesfayal/fix_set_approvers

change path for set_approvers to new api, with defaulted rule_type an… (19242c3)

  • Merge pull request #1008 from filipowm/feature/feature-flags-additional-config

Add capability to control GitLab features per project or group (066fc9b)

v2.0.1 (2020-02-05)#

Chore#

  • chore: revert to 2.0.1

I’ve misread the tag (272db26)

  • chore: bump to 2.1.0

There are a few more features in there (a6c0660)

  • chore: bump version to 2.0.1 (8287a0d)

  • chore(user): update user attributes

This also workarounds an GitLab issue, where private_profile, would reset to false if not supplied (27375f6)

Documentation#

  • docs(auth): remove email/password auth (c9329bb)

Feature#

  • feat: use keyset pagination by default for all=True (99b4484)

Fix#

  • fix(docs): update to new set approvers call for # of approvers

to set the # of approvers for an MR you need to use the same function as for setting the approvers id. (8e0c526)

  • fix(objects): update set_approvers function call

Added a miss paramter update to the set_approvers function (65ecadc)

  • fix(docs and tests): update docs and tests for set_approvers

Updated the docs with the new set_approvers arguments, and updated tests with the arg as well. (2cf12c7)

  • fix(objects): update to new gitlab api for path, and args

Updated the gitlab path for set_approvers to approvers_rules, added default arg for rule type, and added arg for # of approvals required. (e512cdd)

Unknown#

  • Merge pull request #1007 from python-gitlab/chore/user-update

chore(user): update user attributes (f6d9858)

  • Merge pull request #1000 from matusf/update-auth-docs

Update auth docs (7843ace)

v2.0.0 (2020-01-26)#

Chore#

  • chore: build_sphinx needs sphinx >= 1.7.6

Stepping thru Sphinx versions from 1.6.5 to 1.7.5 build_sphinx fails. Once Sphinx == 1.7.6 build_sphinx finished. (528dfab)

  • chore: enforce python version requirements (70176db)

  • chore: bump to 2.0.0

Dropping support for legacy python requires a new major version (c817dcc)

  • chore: drop legacy python tests

Support dropped for: 2.7, 3.4, 3.5 (af8679a)

  • chore: add PyYaml as extra require (7ecd518)

  • chore: bump minimum required requests version

for security reasons (3f78aa3)

Documentation#

  • docs: fix snippet get in project (3a4ff2f)

  • docs(projects): add raw file download docs

Fixes #969 (939e9d3)

Feature#

  • feat: add global order_by option to ease pagination (d187925)

  • feat: support keyset pagination globally (0b71ba4)

  • feat: add appearance API (4c4ac5c)

  • feat: add autocompletion support (973cb8b)

Fix#

  • fix(projects): adjust snippets to match the API (e104e21)

Refactor#

  • refactor: support new list filters

This is most likely only useful for the CLI (bded2de)

  • refactor: remove six dependency (9fb4645)

Test#

  • test: adjust functional tests for project snippets (ac0ea91)

  • test: add project snippet tests (0952c55)

Unknown#

  • Merge pull request #1001 from python-gitlab/feat/keyset-pagination

Feat/keyset pagination (df485a9)

  • Merge pull request #996 from python-gitlab/feat/appearance

feat: add appearance API (7fd3226)

  • Merge pull request #988 from jgroom33/patch-3

docs: fix snippet get in project (afdc43f)

  • Merge pull request #984 from derekschrock/patch-1

chore: build_sphinx needs sphinx >= 1.7.6 (fc2ed13)

  • Merge pull request #982 from python-gitlab/chore/version-requirements

chore: enforce python version requirements (83fcd1b)

  • Merge pull request #980 from python-gitlab/refactor/cleanup-upgrade

Refactor/cleanup upgrade (5fa0e16)

  • Merge pull request #979 from python-gitlab/fix/project-snippets

Fix/project snippets (5a10eb3)

  • Merge pull request #941 from mchlumsky/feat/autocompletion

feat: add autocompletion support (ec6e04c)

v1.15.0 (2019-12-16)#

Chore#

  • chore: bump version to 1.15.0 (2a01326)

  • chore(ci): use correct crane ci (18913dd)

Documentation#

  • docs(projects): fix file deletion docs

The function file.delete() requires branch argument in addition to commit_message. (1c4f1c4)

  • docs: added docs for statistics (8c84cbf)

Feature#

  • feat: allow cfg timeout to be overrided via kwargs

On startup, the timeout parameter is loaded from config and stored on the base gitlab object instance. This instance parameter is used as the timeout for all API requests (it’s passed into the session object when making HTTP calls).

This change allows any API method to specify a timeout argument to **kwargs that will override the global timeout value. This was somewhat needed / helpful for the import_github method.

I have also updated the docs accordingly. (e9a8289)

  • feat: add support for /import/github

Addresses python-gitlab/python-gitlab#952

This adds a method to the ProjectManager called import_github, which maps to the /import/github API endpoint. Calling import_github will trigger an import operation from <repo_id> into <target_namespace>, using <personal_access_token> to authenticate against github. In practice a gitlab server may take many 10’s of seconds to respond to this API call, so we also take the liberty of increasing the default timeout (only for this method invocation).

Unfortunately since import is a protected keyword in python, I was unable to follow the endpoint structure with the manager namespace. I’m open to suggestions on a more sensible interface.

I’m successfully using this addition to batch-import hundreds of github repositories into gitlab. (aa4d41b)

  • feat: nicer stacktrace (697cda2)

  • feat: retry transient HTTP errors

Fixes #970 (59fe271)

  • feat: access project’s issues statistics

Fixes #966 (482e57b)

  • feat: adding project stats

Fixes #967 (db0b00a)

  • feat: add variable_type/protected to projects ci variables

This adds the ci variables types and protected flag for create/update requests.

See https://docs.gitlab.com/ee/api/project_level_variables.html#create-variable (4724c50)

  • feat: add variable_type to groups ci variables

This adds the ci variables types for create/update requests.

See https://docs.gitlab.com/ee/api/group_level_variables.html#create-variable (0986c93)

Fix#

  • fix: ignore all parameter, when as_list=True

Closes #962 (137d72b)

Style#

  • style: format with the latest black version (06a8050)

Test#

  • test: added tests for statistics (8760efc)

  • test: test that all is ignored, when as_list=False (b5e88f3)

Unknown#

  • Merge pull request #959 from andrew-littlebits/feat/import-github

feat: add support for /import/github (97e1fca)

  • Merge pull request #973 from mitar/patch-1

Nicer stacktrace (61eaad2)

  • Merge pull request #971 from jooola/ci_vars_type

feat: add more options for project/group ci variables manipulation (938fc0a)

  • Merge pull request #974 from python-gitlab/docs/file-deletion-docs

docs(projects): fix file deletion docs (59af4e4)

  • Merge pull request #968 from mitar/stats

Stats (62b0b62)

  • Merge pull request #972 from mitar/http-retry

Retry transient HTTP errors (36bbd37)

  • Merge pull request #963 from python-gitlab/fix/as_list

Fix/as list (3e2d694)

v1.14.0 (2019-12-07)#

Chore#

  • chore: bump version to 1.14.0 (164fa4f)

  • chore(ci): switch to crane docker image (#944) (e0066b6)

Documentation#

  • docs(readme): fix Docker image reference

v1.8.0 is not available.

Unable to find image &#39;registry.gitlab.com/python-gitlab/python-gitlab:v1.8.0&#39; locally
docker: Error response from daemon: manifest for registry.gitlab.com/python-gitlab/python-gitlab:v1.8.0 not found: manifest unknown: manifest unknown.
``` ([`b9a40d8`](https://github.com/python-gitlab/python-gitlab/commit/b9a40d822bcff630a4c92c395c134f8c002ed1cb))

* docs(snippets): fix snippet docs

Fixes #954 ([`bbaa754`](https://github.com/python-gitlab/python-gitlab/commit/bbaa754673c4a0bffece482fe33e4875ddadc2dc))

* docs: fix typo ([`d9871b1`](https://github.com/python-gitlab/python-gitlab/commit/d9871b148c7729c9e401f43ff6293a5e65ce1838))

* docs: add project and group cluster examples ([`d15801d`](https://github.com/python-gitlab/python-gitlab/commit/d15801d7e7742a43ad9517f0ac13b6dba24c6283))

* docs(changelog): add notice for release-notes on Github (#938) ([`de98e57`](https://github.com/python-gitlab/python-gitlab/commit/de98e572b003ee4cf2c1ef770a692f442c216247))

### Feature

* feat: add audit endpoint ([`2534020`](https://github.com/python-gitlab/python-gitlab/commit/2534020b1832f28339ef466d6dd3edc21a521260))

* feat: add project and group clusters ([`ebd053e`](https://github.com/python-gitlab/python-gitlab/commit/ebd053e7bb695124c8117a95eab0072db185ddf9))

* feat: add support for include_subgroups filter ([`adbcd83`](https://github.com/python-gitlab/python-gitlab/commit/adbcd83fa172af2f3929ba063a0e780395b102d8))

### Fix

* fix(project-fork): copy create fix from ProjectPipelineManager ([`516307f`](https://github.com/python-gitlab/python-gitlab/commit/516307f1cc9e140c7d85d0ed0c419679b314f80b))

* fix(project-fork): correct path computation for project-fork list ([`44a7c27`](https://github.com/python-gitlab/python-gitlab/commit/44a7c2788dd19c1fe73d7449bd7e1370816fd36d))

* fix(labels): ensure label.save() works

Otherwise, we get:
   File &#34;gitlabracadabra/mixins/labels.py&#34;, line 67, in _process_labels
     current_label.save()
   File &#34;gitlab/exceptions.py&#34;, line 267, in wrapped_f
     return f(*args, **kwargs)
   File &#34;gitlab/v4/objects.py&#34;, line 896, in save
     self._update_attrs(server_data)
   File &#34;gitlab/base.py&#34;, line 131, in _update_attrs
     self.__dict__[&#34;_attrs&#34;].update(new_attrs)
 TypeError: &#39;NoneType&#39; object is not iterable

Because server_data is None. ([`727f536`](https://github.com/python-gitlab/python-gitlab/commit/727f53619dba47f0ab770e4e06f1cb774e14f819))

* fix: added missing attributes for project approvals

Reference: https://docs.gitlab.com/ee/api/merge_request_approvals.html#change-configuration

Missing attributes:
* merge_requests_author_approval
* merge_requests_disable_committers_approval ([`460ed63`](https://github.com/python-gitlab/python-gitlab/commit/460ed63c3dc4f966d6aae1415fdad6de125c6327))

### Unknown

* Merge pull request #949 from idanbensha/add_audit_events

feat: add audit endpoint ([`98e1b0a`](https://github.com/python-gitlab/python-gitlab/commit/98e1b0ae77a627d21ce971ee4df813e1955f69a0))

* Merge pull request #958 from vvv/fix-docker-ref

README.rst: fix the upstream Docker image reference ([`f6f5178`](https://github.com/python-gitlab/python-gitlab/commit/f6f5178c1dc7aeb3fdbee19b1768e30b2be4f4f4))

* Merge pull request #955 from python-gitlab/fix/snippet-docs

docs(snippets): fix snippet docs ([`9961aaa`](https://github.com/python-gitlab/python-gitlab/commit/9961aaa1508e08a567c8c66cb194385788b8113e))

* Merge pull request #953 from bmwiedemann/master

Fix doc typo ([`267a9a1`](https://github.com/python-gitlab/python-gitlab/commit/267a9a151ba9f2338f50fbb118513807ebce9704))

* Merge pull request #947 from lundbird/master

docs: add project and group cluster examples ([`e4cad49`](https://github.com/python-gitlab/python-gitlab/commit/e4cad490b9cd16aa20ea84bb4bd24a6d25b19411))

* Merge pull request #946 from lundbird/master

feat: add project and group clusters ([`da557c9`](https://github.com/python-gitlab/python-gitlab/commit/da557c931fa6c6d50c373fc022d88acf1431c24a))

* Merge pull request #943 from choyrim/942-project-fork-list-404

#942: fix up path computation for project-fork list ([`ecad2c8`](https://github.com/python-gitlab/python-gitlab/commit/ecad2c83635c5e5f7003f61502391446ebc631c9))

* Merge pull request #937 from sathieu/fix_labels_save

fix(labels): ensure label.save() works ([`c937338`](https://github.com/python-gitlab/python-gitlab/commit/c937338b0119b08b358f97b4716c56777ee7bb80))

* Merge pull request #934 from tymonx/fix-missing-attribute-for-project-approvals

Added missing attributes for project approvals ([`9608886`](https://github.com/python-gitlab/python-gitlab/commit/960888628617beae75392dcdcb6ef5a66abd976d))

* Merge pull request #929 from SVLay/docs/pipeline-variables

docs(pipelines_and_jobs): add pipeline custom variables usage example ([`4efa6e6`](https://github.com/python-gitlab/python-gitlab/commit/4efa6e6e5b9b57a3c4eda9ef20a4194b384055dc))

* Merge pull request #932 from ConorNevin/master

Add support for include_subgroups filter ([`1f18230`](https://github.com/python-gitlab/python-gitlab/commit/1f182302c206502f5202d1707fef69adf527fea7))


## v1.13.0 (2019-11-02)

### Chore

* chore: bump version to 1.13.0 ([`d0750bc`](https://github.com/python-gitlab/python-gitlab/commit/d0750bc01ed12952a4d259a13b3917fa404fd435))

* chore(setup): we support 3.8 (#924)

* chore(setup): we support 3.8

* style: format with black ([`6048175`](https://github.com/python-gitlab/python-gitlab/commit/6048175ef2c21fda298754e9b07515b0a56d66bd))

* chore(ci): update latest docker image for every tag ([`01cbc7a`](https://github.com/python-gitlab/python-gitlab/commit/01cbc7ad04a875bea93a08c0ce563ab5b4fe896b))

* chore(dist): add test data

Closes #907 ([`3133ed7`](https://github.com/python-gitlab/python-gitlab/commit/3133ed7d1df6f49de380b35331bbcc67b585a61b))

### Documentation

* docs(pipelines_and_jobs): add pipeline custom variables usage example ([`b275eb0`](https://github.com/python-gitlab/python-gitlab/commit/b275eb03c5954ca24f249efad8125d1eacadd3ac))

* docs: projects get requires id

Also, add an example value for project_id to the other projects.get()
example. ([`5bd8947`](https://github.com/python-gitlab/python-gitlab/commit/5bd8947bd16398aed218f07458aef72e67f2d130))

* docs(project): fix group project example

GroupManager.search is removed since 9a66d78, use list(search=&#39;keyword&#39;) instead ([`e680943`](https://github.com/python-gitlab/python-gitlab/commit/e68094317ff6905049e464a59731fe4ab23521de))

### Feature

* feat: add users activate, deactivate functionality

These were introduced in GitLab 12.4 ([`32ad669`](https://github.com/python-gitlab/python-gitlab/commit/32ad66921e408f6553b9d60b6b4833ed3180f549))

* feat: send python-gitlab version as user-agent ([`c22d49d`](https://github.com/python-gitlab/python-gitlab/commit/c22d49d084d1e03426cfab0d394330f8ab4bd85a))

* feat: add deployment creation

Added in GitLab 12.4

Fixes #917 ([`ca256a0`](https://github.com/python-gitlab/python-gitlab/commit/ca256a07a2cdaf77a5c20e307d334b82fd0fe861))

* feat(test): unused unittest2, type -&gt; isinstance ([`33b1801`](https://github.com/python-gitlab/python-gitlab/commit/33b180120f30515d0f76fcf635cb8c76045b1b42))

* feat(doc): remove refs to api v3 in docs ([`6beeaa9`](https://github.com/python-gitlab/python-gitlab/commit/6beeaa993f8931d6b7fe682f1afed2bd4c8a4b73))

* feat(auth): remove deprecated session auth ([`b751cdf`](https://github.com/python-gitlab/python-gitlab/commit/b751cdf424454d3859f3f038b58212e441faafaf))

### Fix

* fix(projects): support `approval_rules` endpoint for projects

The `approvers` API endpoint is deprecated [1]. GitLab instead uses
the `approval_rules` API endpoint to modify approval settings for
merge requests. This adds the functionality for project-level
merge request approval settings.

Note that there does not exist an endpoint to &#39;get&#39; a single
approval rule at this moment - only &#39;list&#39;.

[1] https://docs.gitlab.com/ee/api/merge_request_approvals.html ([`2cef2bb`](https://github.com/python-gitlab/python-gitlab/commit/2cef2bb40b1f37b97bb2ee9894ab3b9970cef231))

### Test

* test(projects): support `approval_rules` endpoint for projects ([`94bac44`](https://github.com/python-gitlab/python-gitlab/commit/94bac4494353e4f597df0251f0547513c011e6de))

* test: remove warning about open files from test_todo()

When running unittests python warns that the json file from test_todo()
was still open. Use with to open, read, and create encoded json data
that is used by resp_get_todo(). ([`d6419aa`](https://github.com/python-gitlab/python-gitlab/commit/d6419aa86d6ad385e15d685bf47242bb6c67653e))

### Unknown

* Merge pull request #931 from python-gitlab/choree/1-13-0

chore: bump version to 1.13.0 ([`f39c68f`](https://github.com/python-gitlab/python-gitlab/commit/f39c68fd0b180ba72dd11e3cbad932d16d4bb484))

* Merge pull request #919 from appian/project-approval-rules

fix(projects): support `approval_rules` endpoint for projects ([`fddc25a`](https://github.com/python-gitlab/python-gitlab/commit/fddc25adac16a74f61d81871f9ae13c0227d92d6))

* Merge pull request #923 from python-gitlab/feat/users-activate-deactivate

feat: add users activate, deactivate functionality ([`912e16b`](https://github.com/python-gitlab/python-gitlab/commit/912e16b95611715b4df3fae019687f7616af51c1))

* Merge pull request #922 from python-gitlab/chore/latest-docker-image

chore(ci): update latest docker image for every tag ([`ac2266b`](https://github.com/python-gitlab/python-gitlab/commit/ac2266b66553cec11740bd5246e23d649606b5ef))

* Merge pull request #921 from python-gitlab/feat/python-gitlab-agent

feat: send python-gitlab version as user-agent ([`8cb5488`](https://github.com/python-gitlab/python-gitlab/commit/8cb5488142ca7fc7563fac65b434b672a14369fc))

* Merge pull request #920 from python-gitlab/feat/deployment-create

feat: add deployment creation ([`dad6805`](https://github.com/python-gitlab/python-gitlab/commit/dad68050c1269519f35dcdb29dc94a03f47532c5))

* Merge pull request #916 from python-gitlab/chore/add-test-to-dist

chore(dist): add test data ([`e790b1e`](https://github.com/python-gitlab/python-gitlab/commit/e790b1ec40ed690152776a87c15e7f7d5d3b9136))

* Merge pull request #914 from terminalmage/issue913

Remove inaccurate projects.get() example ([`d2c9cee`](https://github.com/python-gitlab/python-gitlab/commit/d2c9ceece5d6473f286e00963252abbcf1a2a17c))

* Merge pull request #911 from xdavidwu/fix-project-doc

docs(project): fix group project example ([`d853a76`](https://github.com/python-gitlab/python-gitlab/commit/d853a767ac8835615e0fded3087f55ca8594c1ed))

* Merge pull request #906 from jouve/test-cleanup

unused unittest2, type -&gt; isinstance ([`42a1ba6`](https://github.com/python-gitlab/python-gitlab/commit/42a1ba6be175a9838c589cb1e40636b3910db505))

* Merge pull request #904 from jouve/remove-cred-auth

remove deprecated session auth ([`67a9c1f`](https://github.com/python-gitlab/python-gitlab/commit/67a9c1f1c62393b02919d25bcc98c3683d92576a))

* Merge pull request #908 from derekschrock/todo-units-test

Remove warning about open files from test_todo() ([`ff808ee`](https://github.com/python-gitlab/python-gitlab/commit/ff808ee94a73d65802a21ff1350090885d4befd5))

* Merge pull request #905 from jouve/doc-v3

remove references to api v3 in docs ([`92ba028`](https://github.com/python-gitlab/python-gitlab/commit/92ba0283b63e562e181061252787e0e46da83a29))


## v1.12.1 (2019-10-07)

### Fix

* fix: fix not working without auth ([`03b7b5b`](https://github.com/python-gitlab/python-gitlab/commit/03b7b5b07e1fd2872e8968dd6c29bc3161c6c43a))

### Unknown

* Merge pull request #901 from python-gitlab/fix/non-auth

fix: fix not working without auth ([`f4b2927`](https://github.com/python-gitlab/python-gitlab/commit/f4b29278771e48320e2da4bacc4544d263d1754c))


## v1.12.0 (2019-10-06)

### Chore

* chore: bump to 1.12.0 ([`4648128`](https://github.com/python-gitlab/python-gitlab/commit/46481283a9985ae1b07fe686ec4a34e4a1219b66))

* chore(ci): build test images on tag ([`0256c67`](https://github.com/python-gitlab/python-gitlab/commit/0256c678ea9593c6371ffff60663f83c423ca872))

### Documentation

* docs(project): add submodule docs ([`b5969a2`](https://github.com/python-gitlab/python-gitlab/commit/b5969a2dcea77fa608cc29be7a5f39062edd3846))

* docs(projects): add note about project list

Fixes #795 ([`44407c0`](https://github.com/python-gitlab/python-gitlab/commit/44407c0f59b9602b17cfb93b5e1fa37a84064766))

* docs(repository-tags): fix typo

Closes #879 ([`3024c5d`](https://github.com/python-gitlab/python-gitlab/commit/3024c5dc8794382e281b83a8266be7061069e83e))

* docs(todo): correct todo docs ([`d64edcb`](https://github.com/python-gitlab/python-gitlab/commit/d64edcb4851ea62e72e3808daf7d9b4fdaaf548b))

### Feature

* feat(project): implement update_submodule ([`4d1e377`](https://github.com/python-gitlab/python-gitlab/commit/4d1e3774706f336e87ebe70e1b373ddb37f34b45))

* feat(ci): improve functionnal tests ([`eefceac`](https://github.com/python-gitlab/python-gitlab/commit/eefceace2c2094ef41d3da2bf3c46a58a450dcba))

* feat(project): add file blame api

https://docs.gitlab.com/ee/api/repository_files.html#get-file-blame-from-repository ([`f5b4a11`](https://github.com/python-gitlab/python-gitlab/commit/f5b4a113a298d33cb72f80c94d85bdfec3c4e149))

* feat: add support for job token

See https://docs.gitlab.com/ee/api/jobs.html#get-job-artifacts for usage ([`cef3aa5`](https://github.com/python-gitlab/python-gitlab/commit/cef3aa51a6928338c6755c3e6de78605fae8e59e))

* feat(user): add status api ([`62c9fe6`](https://github.com/python-gitlab/python-gitlab/commit/62c9fe63a47ddde2792a4a5e9cd1c7aa48661492))

### Fix

* fix(cli): fix cli command user-project list ([`c17d7ce`](https://github.com/python-gitlab/python-gitlab/commit/c17d7ce14f79c21037808894d8c7ba1117779130))

* fix(labels): don&#39;t mangle label name on update ([`1fb6f73`](https://github.com/python-gitlab/python-gitlab/commit/1fb6f73f4d501c2b6c86c863d40481e1d7a707fe))

* fix(todo): mark_all_as_done doesn&#39;t return anything ([`5066e68`](https://github.com/python-gitlab/python-gitlab/commit/5066e68b398039beb5e1966ba1ed7684d97a8f74))

### Refactor

* refactor: remove obsolete test image

Follow up of #896 ([`a14c02e`](https://github.com/python-gitlab/python-gitlab/commit/a14c02ef85bd4d273b8c7f0f6bd07680c91955fa))

* refactor: remove unused code, simplify string format ([`c7ff676`](https://github.com/python-gitlab/python-gitlab/commit/c7ff676c11303a00da3a570bf2893717d0391f20))

### Style

* style: format with black ([`fef085d`](https://github.com/python-gitlab/python-gitlab/commit/fef085dca35d6b60013d53a3723b4cbf121ab2ae))

### Test

* test(submodules): correct test method ([`e59356f`](https://github.com/python-gitlab/python-gitlab/commit/e59356f6f90d5b01abbe54153441b6093834aa11))

* test(func): disable commit test

GitLab seems to be randomly failing here ([`c9c76a2`](https://github.com/python-gitlab/python-gitlab/commit/c9c76a257d2ed3b394f499253d890c2dd9a01e24))

* test(todo): add unittests ([`7715567`](https://github.com/python-gitlab/python-gitlab/commit/77155678a5d8dbbf11d00f3586307694042d3227))

* test(status): add user status test ([`fec4f9c`](https://github.com/python-gitlab/python-gitlab/commit/fec4f9c23b8ba33bb49dca05d9c3e45cb727e0af))

* test: re-enabled py_func_v4 test ([`49d84ba`](https://github.com/python-gitlab/python-gitlab/commit/49d84ba7e95fa343e622505380b3080279b83f00))

### Unknown

* Merge pull request #899 from python-gitlab/chore/package-version

chore: bump to 1.12.0 ([`35cc8c7`](https://github.com/python-gitlab/python-gitlab/commit/35cc8c789fda4977add7f399bf426352b1aa246f))

* Merge pull request #898 from python-gitlab/feat/update_submodule

Feat/update submodule ([`6f4332d`](https://github.com/python-gitlab/python-gitlab/commit/6f4332db37b0a609ec4bd5e2c0b7ffc01717599c))

* Merge pull request #897 from python-gitlab/refactor/remove-obsolete-image

refactor: remove obsolete test image ([`fcea41c`](https://github.com/python-gitlab/python-gitlab/commit/fcea41c61f7776cf57ed5001facbc1e77d2834c4))

* Merge pull request #892 from godaji/remove-unused-code

Remove unused code and simplify string format. ([`214f7ef`](https://github.com/python-gitlab/python-gitlab/commit/214f7ef5f3b6e99b7756982c5b883e40d3b22657))

* Merge pull request #896 from jouve/fix-functionnal-test

improve functionnal tests ([`d7d2260`](https://github.com/python-gitlab/python-gitlab/commit/d7d2260945994a9e73fe3f7f9328f3ec9d9c54d4))

* Merge pull request #894 from minitux/master

feat (project): add file blame api ([`082a624`](https://github.com/python-gitlab/python-gitlab/commit/082a62456deaa68274ed1c44a744c79c5356a622))

* Merge pull request #891 from python-gitlab/docs/project-note-list

docs(projects): add note about project list ([`ba2b60e`](https://github.com/python-gitlab/python-gitlab/commit/ba2b60e32c12cacf18762a286d05e073529b9898))

* Merge pull request #886 from LuckySB/cli_user_project

fix cli command user-project list ([`88b1833`](https://github.com/python-gitlab/python-gitlab/commit/88b183376de5b8c986eac24955ef129ca4d781cc))

* Merge pull request #885 from sathieu/patch-1

Don&#39;t mangle label name on update ([`ff10726`](https://github.com/python-gitlab/python-gitlab/commit/ff10726d70a62d32ef39398a431def9656c93927))

* Merge pull request #880 from python-gitlab/docs/tags-fix-typo

docs(repository-tags): fix typo ([`c287bdd`](https://github.com/python-gitlab/python-gitlab/commit/c287bdd0889881d89f991d3929ae513d91b5894c))

* Merge pull request #878 from python-gitlab/test/todo-unit-test

Test/todo unit test ([`040894d`](https://github.com/python-gitlab/python-gitlab/commit/040894d245709c5c2524d59d2b228a21dd74d1a4))

* Merge pull request #876 from sathieu/job_token

Add support for job token ([`8474829`](https://github.com/python-gitlab/python-gitlab/commit/8474829a3fe40aca8f5d4c1c627908f0830a8f59))

* Merge pull request #875 from python-gitlab/feat/status-api

feat(user): add status api ([`b7f3342`](https://github.com/python-gitlab/python-gitlab/commit/b7f33429c75ed2f464ebd9b4d3c56d3479df3faa))

* Merge pull request #874 from python-gitlab/test/py-fun-test

test: re-enabled py_func_v4 test ([`1490b0e`](https://github.com/python-gitlab/python-gitlab/commit/1490b0e7f175d54cc6d35de7aac6d9e45c0e3d51))


## v1.11.0 (2019-08-31)

### Chore

* chore: bump package version ([`37542cd`](https://github.com/python-gitlab/python-gitlab/commit/37542cd28aa94ba01d5d289d950350ec856745af))

### Feature

* feat: add methods to retrieve an individual project environment ([`29de40e`](https://github.com/python-gitlab/python-gitlab/commit/29de40ee6a20382c293d8cdc8d831b52ad56a657))

* feat: group labels with subscriptable mixin ([`4a9ef9f`](https://github.com/python-gitlab/python-gitlab/commit/4a9ef9f0fa26e01fc6c97cf88b2a162e21f61cce))

### Fix

* fix(projects): avatar uploading for projects ([`558ace9`](https://github.com/python-gitlab/python-gitlab/commit/558ace9b007ff9917734619c05a7c66008a4c3f0))

* fix: remove empty list default arguments

Signed-off-by: Frantisek Lachman &lt;flachman@redhat.com&gt; ([`6e204ce`](https://github.com/python-gitlab/python-gitlab/commit/6e204ce819fc8bdd5359325ed7026a48d63f8103))

* fix: remove empty dict default arguments

Signed-off-by: Frantisek Lachman &lt;flachman@redhat.com&gt; ([`8fc8e35`](https://github.com/python-gitlab/python-gitlab/commit/8fc8e35c63d7ebd80408ae002693618ca16488a7))

* fix: add project and group label update without id to fix cli ([`a3d0d7c`](https://github.com/python-gitlab/python-gitlab/commit/a3d0d7c1e7b259a25d9dc84c0b1de5362c80abb8))

### Test

* test: add group label cli tests ([`f7f24bd`](https://github.com/python-gitlab/python-gitlab/commit/f7f24bd324eaf33aa3d1d5dd12719237e5bf9816))

### Unknown

* Merge pull request #865 from orf/retrieve-environment

feat: add methods to retrieve an individual project environment ([`0389e66`](https://github.com/python-gitlab/python-gitlab/commit/0389e664c0a04021b3df097bacad3940f158607f))

* Merge pull request #861 from ravanscafi/fix-project-avatar

Fix avatar uploading for projects ([`99a9415`](https://github.com/python-gitlab/python-gitlab/commit/99a941526a1845559d92b607fd9e2d86efb7e7b6))

* Merge pull request #860 from lachmanfrantisek/fix-mutable-default-arguments

Fix mutable default arguments ([`e8a3585`](https://github.com/python-gitlab/python-gitlab/commit/e8a3585ed0e7dfa2f64f6c3378a598120f5f8167))

* Merge pull request #847 from sidisel-albertolopez/feat/grouplabels

feat: Add grouplabel support with subscribable mixin ([`edb3359`](https://github.com/python-gitlab/python-gitlab/commit/edb3359fb3a77050d3e162da641445952397279b))


## v1.10.0 (2019-07-22)

### Chore

* chore: bump package version to 1.10.0 ([`c7c8470`](https://github.com/python-gitlab/python-gitlab/commit/c7c847056b6d24ba7a54b93837950b7fdff6c477))

* chore(setup): add 3.7 to supported python versions ([`b1525c9`](https://github.com/python-gitlab/python-gitlab/commit/b1525c9a4ca2d8c6c14d745638b3292a71763aeb))

* chore: move checks back to travis ([`b764525`](https://github.com/python-gitlab/python-gitlab/commit/b7645251a0d073ca413bba80e87884cc236e63f2))

* chore: disable failing travis test ([`515aa9a`](https://github.com/python-gitlab/python-gitlab/commit/515aa9ac2aba132d1dfde0418436ce163fca2313))

* chore(ci): rebuild test image, when something changed ([`2fff260`](https://github.com/python-gitlab/python-gitlab/commit/2fff260a8db69558f865dda56f413627bb70d861))

* chore(ci): update the GitLab version in the test image ([`c410699`](https://github.com/python-gitlab/python-gitlab/commit/c41069992de392747ccecf8c282ac0549932ccd1))

* chore(ci): fix gitlab PyPI publish ([`3e37df1`](https://github.com/python-gitlab/python-gitlab/commit/3e37df16e2b6a8f1beffc3a595abcb06fd48a17c))

* chore(ci): add automatic GitLab image pushes ([`95c9b6d`](https://github.com/python-gitlab/python-gitlab/commit/95c9b6dd489fc15c7dfceffca909917f4f3d4312))

* chore: add a tox job to run black

Allow lines to be 88 chars long for flake8. ([`c27fa48`](https://github.com/python-gitlab/python-gitlab/commit/c27fa486698e441ebc16448ee93e5539cb885ced))

* chore(ci): use reliable ci system ([`724a672`](https://github.com/python-gitlab/python-gitlab/commit/724a67211bc83d67deef856800af143f1dbd1e78))

* chore(ci): don&#39;t try to publish existing release ([`b4e818d`](https://github.com/python-gitlab/python-gitlab/commit/b4e818db7887ff1ec337aaf392b5719f3931bc61))

* chore: release tags to PyPI automatically

Fixes #609 ([`3133b48`](https://github.com/python-gitlab/python-gitlab/commit/3133b48a24ce3c9e2547bf2a679d73431dfbefab))

* chore(tests): add rate limit tests ([`e216f06`](https://github.com/python-gitlab/python-gitlab/commit/e216f06d4d25d37a67239e93a8e2e400552be396))

### Documentation

* docs(snippets): fix project-snippets layout

Fixes #828 ([`7feb97e`](https://github.com/python-gitlab/python-gitlab/commit/7feb97e9d89b4ef1401d141be3d00b9d0ff6b75c))

* docs(projects): add mention about project listings

Having exactly 20 internal and 5 private projects in the group
spent some time debugging this issue.

Hopefully that helped: https://github.com/python-gitlab/python-gitlab/issues/93

Imho should be definitely mention about `all=True` parameter. ([`f604b25`](https://github.com/python-gitlab/python-gitlab/commit/f604b2577b03a6a19641db3f2060f99d24cc7073))

* docs(readme): fix six url

six URL was pointing to 404 ([`0bc30f8`](https://github.com/python-gitlab/python-gitlab/commit/0bc30f840c9c30dd529ae85bdece6262d2702c94))

* docs: re-order api examples

`Pipelines and Jobs` and `Protected Branches` are out of order in contents and sometimes hard to find when looking for examples. ([`5d149a2`](https://github.com/python-gitlab/python-gitlab/commit/5d149a2262653b729f0105639ae5027ae5a109ea))

* docs: add pipeline deletion ([`2bb2571`](https://github.com/python-gitlab/python-gitlab/commit/2bb257182c237384d60b8d90cbbff5a0598f283b))

* docs(api-usage): fix project group example

Fixes #798 ([`40a1bf3`](https://github.com/python-gitlab/python-gitlab/commit/40a1bf36c2df89daa1634e81c0635c1a63831090))

* docs: remove v3 support ([`7927663`](https://github.com/python-gitlab/python-gitlab/commit/792766319f7c43004460fc9b975549be55430987))

* docs: Add an example of trigger token usage

Closes #752 ([`ea1eefe`](https://github.com/python-gitlab/python-gitlab/commit/ea1eefef2896420ae4e4d248155e4c5d33b4034e))

* docs(readme): add more info about commitlint, code-format ([`286f703`](https://github.com/python-gitlab/python-gitlab/commit/286f7031ed542c97fb8792f61012d7448bee2658))

* docs(readme): provide commit message guidelines

Fixes #660 ([`bed8e1b`](https://github.com/python-gitlab/python-gitlab/commit/bed8e1ba80c73b1d976ec865756b62e66342ce32))

* docs(setup): use proper readme on PyPI ([`6898097`](https://github.com/python-gitlab/python-gitlab/commit/6898097c45d53a3176882a3d9cb86c0015f8d491))

* docs(groups): fix typo

Fixes #635 ([`ac2d65a`](https://github.com/python-gitlab/python-gitlab/commit/ac2d65aacba5c19eca857290c5b47ead6bb4356d))

* docs(projects): fix typo in code sample

Fixes #630 ([`b93f2a9`](https://github.com/python-gitlab/python-gitlab/commit/b93f2a9ea9661521878ac45d70c7bd9a5a470548))

* docs(cli): add PyYAML requirement notice

Fixes #606 ([`d29a489`](https://github.com/python-gitlab/python-gitlab/commit/d29a48981b521bf31d6f0304b88f39a63185328a))

* docs(readme): add docs build information ([`6585c96`](https://github.com/python-gitlab/python-gitlab/commit/6585c967732fe2a53c6ad6d4d2ab39aaa68258b0))

* docs: add MR approvals in index ([`0b45afb`](https://github.com/python-gitlab/python-gitlab/commit/0b45afbeed13745a2f9d8a6ec7d09704a6ab44fb))

* docs(api-usage): add rate limit documentation ([`ad4de20`](https://github.com/python-gitlab/python-gitlab/commit/ad4de20fe3a2fba2d35d4204bf5b0b7f589d4188))

* docs(projects): fix typo ([`c6bcfe6`](https://github.com/python-gitlab/python-gitlab/commit/c6bcfe6d372af6557547a408a8b0a39b909f0cdf))

* docs: trigger_pipeline only accept branches and tags as ref

Fixes #430 ([`d63748a`](https://github.com/python-gitlab/python-gitlab/commit/d63748a41cc22bba93a9adf0812e7eb7b74a0161))

* docs: fix invalid Raise attribute in docstrings ([`95a3fe6`](https://github.com/python-gitlab/python-gitlab/commit/95a3fe6907676109e1cd2f52ca8f5ad17e0d01d0))

* docs: add missing = ([`391417c`](https://github.com/python-gitlab/python-gitlab/commit/391417cd47d722760dfdaab577e9f419c5dca0e0))

* docs: remove the build warning about _static ([`764d3ca`](https://github.com/python-gitlab/python-gitlab/commit/764d3ca0087f0536c48c9e1f60076af211138b9b))

* docs: fix &#34;required&#34; attribute ([`e64d0b9`](https://github.com/python-gitlab/python-gitlab/commit/e64d0b997776387f400eaec21c37ce6e58d49095))

* docs: add missing requiredCreateAttrs ([`b08d74a`](https://github.com/python-gitlab/python-gitlab/commit/b08d74ac3efb505961971edb998ce430e430d652))

* docs: add a note for python 3.5 for file content update

The data passed to the JSON serializer must be a string with python 3.
Document this in the exemples.

Fix #175 ([`ca014f8`](https://github.com/python-gitlab/python-gitlab/commit/ca014f8c3e4877a4cc1ae04e1302fb57d39f47c4))

* docs: improve the pagination section ([`29e2efe`](https://github.com/python-gitlab/python-gitlab/commit/29e2efeae22ce5fa82e3541360b234e0053a65c2))

* docs: notes API ([`3e026d2`](https://github.com/python-gitlab/python-gitlab/commit/3e026d2ee62eba3ad92ff2cdd53db19f5e0e9f6a))

* docs: snippets API ([`35b7f75`](https://github.com/python-gitlab/python-gitlab/commit/35b7f750c7e38a39cd4cb27195d9aa4807503b29))

* docs: tags API ([`dd79eda`](https://github.com/python-gitlab/python-gitlab/commit/dd79eda78f91fc7e1e9a08b1e70ef48e3b4bb06d))

* docs: system hooks API ([`5c51bf3`](https://github.com/python-gitlab/python-gitlab/commit/5c51bf3d49302afe4725575a83d81a8c9eeb8779))

* docs: add ApplicationSettings API ([`ab7d794`](https://github.com/python-gitlab/python-gitlab/commit/ab7d794251bcdbafce69b1bde0628cd3b710d784))

* docs: repository files API ([`f00340f`](https://github.com/python-gitlab/python-gitlab/commit/f00340f72935b6fd80df7b62b811644b63049b5a))

* docs: project repository API ([`71a2a4f`](https://github.com/python-gitlab/python-gitlab/commit/71a2a4fb84321e73418fda1ce4e4d47177af928c))

* docs: add milestones API ([`7411907`](https://github.com/python-gitlab/python-gitlab/commit/74119073dae18214df1dd67ded6cd57abda335d4))

* docs: add MR API ([`5614a7c`](https://github.com/python-gitlab/python-gitlab/commit/5614a7c9bf62aede3804469b6781f45d927508ea))

* docs: add licenses API ([`4540614`](https://github.com/python-gitlab/python-gitlab/commit/4540614a38067944c628505225bb15928d8e3c93))

* docs: add labales API ([`31882b8`](https://github.com/python-gitlab/python-gitlab/commit/31882b8a57f3f4c7e4c4c4b319af436795ebafd3))

* docs: add deploy keys API ([`ea089e0`](https://github.com/python-gitlab/python-gitlab/commit/ea089e092439a8fe95b50c3d0592358550389b51))

* docs: issues API ([`41cbc32`](https://github.com/python-gitlab/python-gitlab/commit/41cbc32621004aab2cae5f7c14fc60005ef7b966))

* docs: commits API ([`07c5594`](https://github.com/python-gitlab/python-gitlab/commit/07c55943eebb302bc1b8feaf482d929c83e9ebe1))

* docs: groups API documentation ([`4d871aa`](https://github.com/python-gitlab/python-gitlab/commit/4d871aadfaa9f57f5ae9f8b49f8367a5ef58545d))

* docs: Add builds-related API docs ([`8e6a944`](https://github.com/python-gitlab/python-gitlab/commit/8e6a9442324926ed1dec0a8bfaf77792e4bdb10f))

* docs: fork relationship API ([`21f48b3`](https://github.com/python-gitlab/python-gitlab/commit/21f48b357130720551d5cccbc62f5275fe970378))

* docs: project search API ([`e4cd04c`](https://github.com/python-gitlab/python-gitlab/commit/e4cd04c225e2160f02a8f292dbd4c0f6350769e4))

* docs: document hooks API ([`b21dca0`](https://github.com/python-gitlab/python-gitlab/commit/b21dca0acb2c12add229a1742e0c552aa50618c1))

* docs: add project members doc ([`dcf31a4`](https://github.com/python-gitlab/python-gitlab/commit/dcf31a425217efebe56d4cbc8250dceb3844b2fa))

* docs: document projects API ([`967595f`](https://github.com/python-gitlab/python-gitlab/commit/967595f504b8de076ae9218a96c3b8dd6273b9d6))

* docs: crossref improvements ([`6f9f42b`](https://github.com/python-gitlab/python-gitlab/commit/6f9f42b64cb82929af60e299c70773af6d406a6e))

* docs: start a FAQ ([`c305459`](https://github.com/python-gitlab/python-gitlab/commit/c3054592f79caa782ec79816501335e9a5c4e9ed))

* docs: do not use the :option: markup ([`368017c`](https://github.com/python-gitlab/python-gitlab/commit/368017c01f15013ab4cc9405c246a86e67f3b067))

### Feature

* feat: add mr rebase method ([`bc4280c`](https://github.com/python-gitlab/python-gitlab/commit/bc4280c2fbff115bd5e29a6f5012ae518610f626))

* feat: get artifact by ref and job ([`cda1174`](https://github.com/python-gitlab/python-gitlab/commit/cda117456791977ad300a1dd26dec56009dac55e))

* feat: add support for board update

Closes #801 ([`908d79f`](https://github.com/python-gitlab/python-gitlab/commit/908d79fa56965e7b3afcfa23236beef457cfa4b4))

* feat: add support for issue.related_merge_requests

Closes #794 ([`90a3631`](https://github.com/python-gitlab/python-gitlab/commit/90a363154067bcf763043124d172eaf705c8fe90))

* feat: bump version to 1.9.0 ([`aaed448`](https://github.com/python-gitlab/python-gitlab/commit/aaed44837869bd2ce22b6f0d2e1196b1d0e626a6))

* feat: implement artifacts deletion

Closes #744 ([`76b6e1f`](https://github.com/python-gitlab/python-gitlab/commit/76b6e1fc0f42ad00f21d284b4ca2c45d6020fd19))

* feat: add endpoint to get the variables of a pipeline

It adds a new endpoint which was released in the Gitlab CE 11.11.

Signed-off-by: Agustin Henze &lt;tin@redhat.com&gt; ([`564de48`](https://github.com/python-gitlab/python-gitlab/commit/564de484f5ef4c76261057d3d2207dc747da020b))

* feat(GitLab Update): delete ProjectPipeline (#736)

* feat(GitLab Update): delete ProjectPipeline

As of Gitlab 11.6 it is now possible to delete a pipeline - https://docs.gitlab.com/ee/api/pipelines.html#delete-a-pipeline ([`768ce19`](https://github.com/python-gitlab/python-gitlab/commit/768ce19c5e5bb197cddd4e3871c175e935c68312))

* feat: Added approve &amp; unapprove method for Mergerequests

Offical GitLab API supports this for GitLab EE ([`53f7de7`](https://github.com/python-gitlab/python-gitlab/commit/53f7de7bfe0056950a8e7271632da3f89e3ba3b3))

* feat: obey the rate limit

done by using the retry-after header

Fixes #166 ([`2abf9ab`](https://github.com/python-gitlab/python-gitlab/commit/2abf9abacf834da797f2edf6866e12886d642b9d))

### Fix

* fix: improve pickle support ([`b4b5dec`](https://github.com/python-gitlab/python-gitlab/commit/b4b5decb7e49ac16d98d56547a874fb8f9d5492b))

* fix(cli): allow --recursive parameter in repository tree

Fixes #718
Fixes #731 ([`7969a78`](https://github.com/python-gitlab/python-gitlab/commit/7969a78ce8605c2b0195734e54c7d12086447304))

* fix(cli): don&#39;t fail when the short print attr value is None

Fixes #717
Fixes #727 ([`8d1552a`](https://github.com/python-gitlab/python-gitlab/commit/8d1552a0ad137ca5e14fabfc75f7ca034c2a78ca))

* fix(cli): fix update value for key not working ([`b766203`](https://github.com/python-gitlab/python-gitlab/commit/b7662039d191ebb6a4061c276e78999e2da7cd3f))

* fix: convert # to %23 in URLs

Refactor a bit to handle this change, and add unit tests.

Closes #779 ([`14f5385`](https://github.com/python-gitlab/python-gitlab/commit/14f538501bfb47c92e02e615d0817675158db3cf))

* fix: pep8 errors

Errors have not been detected by broken travis runs. ([`334f9ef`](https://github.com/python-gitlab/python-gitlab/commit/334f9efb18c95bb5df3271d26fa0a55b7aec1c7a))

* fix(api): Make *MemberManager.all() return a list of objects

Fixes #699 ([`d74ff50`](https://github.com/python-gitlab/python-gitlab/commit/d74ff506ca0aadaba3221fc54cbebb678240564f))

* fix: use python2 compatible syntax for super ([`b08efcb`](https://github.com/python-gitlab/python-gitlab/commit/b08efcb9d155c20fa938534dd2d912f5191eede6))

* fix: re-add merge request pipelines ([`877ddc0`](https://github.com/python-gitlab/python-gitlab/commit/877ddc0dbb664cd86e870bb81d46ca614770b50e))

* fix(api): Don&#39;t try to parse raw downloads

http_get always tries to interpret the retrieved data if the
content-type is json. In some cases (artifact download for instance)
this is not the expected behavior.

This patch changes http_get and download methods to always get the raw
data without parsing.

Closes #683 ([`35a6d85`](https://github.com/python-gitlab/python-gitlab/commit/35a6d85acea4776e9c4ad23ff75259481a6bcf8d))

* fix(api): avoid parameter conflicts with python and gitlab

Provide another way to send data to gitlab with a new `query_parameters`
argument. This parameter can be used to explicitly define the dict of
items to send to the server, so that **kwargs are only used to specify
python-gitlab specific parameters.

Closes #566
Closes #629 ([`4bd027a`](https://github.com/python-gitlab/python-gitlab/commit/4bd027aac41c41f7e22af93c7be0058d2faf7fb4))

* fix: remove decode() on error_message string

The integration tests failed because a test called &#39;decode()&#39; on a
string-type variable - the GitLabException class handles byte-to-string
conversion already in its __init__. This commit removes the call to
&#39;decode()&#39; in the test.

Traceback (most recent call last): File “./tools/python_test_v4.py”, line 801, in <module> assert ‘Retry later’ in error_message.decode() AttributeError: ‘str’ object has no attribute ‘decode’ ``` (16bda20)

  • fix: handle empty ‘Retry-After’ header from GitLab

When requests are throttled (HTTP response code 429), python-gitlab assumed that ‘Retry-After’ existed in the response headers. This is not always the case and so the request fails due to a KeyError. The change in this commit adds a rudimentary exponential backoff to the ‘http_request’ method, which defaults to 10 retries but can be set to -1 to retry without bound. (7a3724f)

  • fix(api): make reset_time_estimate() work again

Closes #672 (cb388d6)

  • fix: enable use of YAML in the CLI

In order to use the YAML output, PyYaml needs to be installed on the docker image. This commit adds the installation to the dockerfile as a separate layer. (ad0b476)

  • fix: docker entry point argument passing

Fixes the problem of passing spaces in the arguments to the docker entrypoint.

Before this fix, there was virtually no way to pass spaces in arguments such as task description. (67ab637)

  • fix(cli): exit on config parse error, instead of crashing

  • Exit and hint user about possible errors

  • test: adjust test cases to config missing error (6ad9da0)

  • fix(docker): use docker image with current sources (06e8ca8)

  • fix(cli): print help and usage without config file

Fixes #560 (6bb4d17)

Refactor#

  • refactor: format everything black (318d277)

  • refactor: rename MASTER_ACCESS

to MAINTAINER_ACCESS to follow GitLab 11.0 docs

See: https://docs.gitlab.com/ce/user/permissions.html#project-members-permissions (c38775a)

Style#

  • style: format with black again (22b5082)

Test#

  • test: minor test fixes (3b523f4)

  • test: add project releases test

Fixes #762 (8ff8af0)

  • test: increase speed by disabling the rate limit faster (497f56c)

  • test: always use latest version to test (82b0fc6)

  • test: update the tests for GitLab 11.11

Changes in GitLab make the functional tests fail:

  • Some actions add new notes and discussions: do not use hardcoded values in related listing asserts

  • The feature flag API is buggy (errors 500): disable the tests for now (622854f)

Unknown#

  • Merge pull request #842 from python-gitlab/chore/bump-package-version

chore: bump package version to 1.10.0 (2c1ea56)

  • Merge pull request #841 from python-gitlab/docs/project-snippets

docs(snippets): fix project-snippets layout (29d102f)

  • Merge pull request #840 from python-gitlab/docs/project-docs

docs(projects): add mention about project listings (de19296)

  • Merge pull request #838 from python-gitlab/pickle-fix

fix: improve pickle support (f0e3daa)

  • Merge pull request #839 from python-gitlab/dajsn-fix-readme-six-url

docs(readme): fix six url (8d54cf5)

  • Merge pull request #837 from python-gitlab/PR-bugfix-718

fix(cli): allow –recursive parameter in repository tree (27b9706)

  • Merge pull request #836 from python-gitlab/test/project-releases

test: add project releases test (262b222)

  • Merge pull request #835 from python-gitlab/bugfix-717

fix(cli): don’t fail when the short print attr value is None (0b0a60f)

  • Merge pull request #833 from python-gitlab/project-variable-update

fix(cli): fix update value for key not working (6c673c6)

  • Merge pull request #834 from python-gitlab/chore/setup-supported-versions

chore(setup): add 3.7 to supported python versions (8306ef2)

  • Merge pull request #832 from python-gitlab/test/always-latest

test: always use latest version to test (8f1ed93)

  • Merge pull request #823 from jeroen92/rebase-mr

Resolve #822, add mr rebase (b9877b4)

  • Merge pull request #831 from python-gitlab/chore/move-back-to-travis

chore: move checks back to travis (c8a7e31)

  • Merge pull request #830 from python-gitlab/chore/ci-disable-py-func

Chore/ci disable py func (2e42e28)

  • Merge pull request #827 from ahaynssen/master

docs: re-order api examples (5492b71)

  • Merge pull request #824 from python-gitlab/feat/add-ref-artifacts

feat: get artifact by ref and job (4a8503d)

  • Merge pull request #803 from python-gitlab/feat/related_mr

feat: add support for issue.related_merge_requests (ad1c0dd)

  • Merge pull request #804 from python-gitlab/feat/update_board

feat: add support for board update (f539c36)

  • Merge pull request #808 from minitux/patch-1 (2ea8eb8)

  • Merge pull request #805 from python-gitlab/chore/ci-rebuild-image

chore(ci): rebuild test image, when something changed (6625a06)

  • Merge pull request #802 from python-gitlab/chore/gitlab-11.11.3

chore(ci): update the GitLab version in the test image (51751c5)

  • Merge pull request #792 from python-gitlab/chore/enable-gitlab-ci-builds

chore(ci): add automatic GitLab image pushes (50c53c0)

  • Merge pull request #800 from python-gitlab/chore/ci-publish

chore(ci): fix gitlab PyPI publish (722a6ef)

  • Merge pull request #797 from python-gitlab/feat/version-bump

feat: bump version to 1.9.0 (4b04432)

  • Merge pull request #799 from python-gitlab/docs/fix-group-access

docs(api-usage): fix project group example (b5aaa3e)

  • Merge pull request #767 from python-gitlab/fix/744/delete_artifacts

feature: Implement artifacts deletion (4e1dd27)

  • Merge pull request #791 from python-gitlab/tests-for-gl-11.11

test: update the tests for GitLab 11.11 (e45a6e2)

  • Merge pull request #789 from python-gitlab/no-more-v3

docs: remove v3 support (e2115b1)

  • Merge pull request #785 from agustinhenze/add-pipeline-get-variables-endpoint

Add new endpoint to get the variables of a pipeline (463cedc)

  • Merge pull request #768 from python-gitlab/trigger_token_example

docs: Add an example of trigger token usage (5af0b52)

  • Merge pull request #790 from python-gitlab/fix/779

fix: convert # to %23 in URLs (101ccd1)

  • Merge pull request #788 from python-gitlab/black-in-tox

Add a tox job to run black (d135e4e)

  • Merge pull request #778 from python-gitlab/docs/readme-code-format

docs(readme): add more info about commitlint, code-format (794d64c)

  • Merge pull request #775 from python-gitlab/refactor/black

refactor: format everything black (290e5ed)

  • Merge pull request #776 from python-gitlab/revert-760-custom_cli_actions_fix

Revert “Custom cli actions fix” (ef32990)

  • Revert “Custom cli actions fix” (d3a20c5)

  • Merge pull request #760 from kkoralsky/custom_cli_actions_fix

Custom cli actions fix (e8823e9)

  • Merge pull request #759 from kkoralsky/registry_api

registry api implementation (84bcdc0)

  • Merge pull request #773 from python-gitlab/chore/ci-reliable-system

chore(ci): use reliable ci system (3dc6413)

  • documentation fix (2d9078e)

  • whitespaces (c91230e)

  • documentation (4d31b9c)

  • fix docstring & improve coding style (3cede7b)

  • register cli action for delete_in_bulk (0b79ce9)

  • fix repository_id marshaling in cli (340cd37)

  • merged new release & registry apis (910c286)

  • Merge pull request #769 from python-gitlab/pep-fixes

fix: pep8 errors (a730598)

  • Merge pull request #746 from therealgambo/master

add project releases api (16de1b0)

  • fix -/_ replacament for *Manager custom actions (6158fd2)

  • dont ask for id attr if this is *Manager originating custom action (adb6305)

  • Use NoUpdateMixin for now (8e55a3c)

  • add project releases api (3680545)

  • Merge pull request #714 from jaraco/feature/runpy-invoke

Add runpy hook, allowing invocation with ‘python -m gitlab’. (a3a7713)

  • Add runpy hook. Fixes #713.

Allows for invocation with ‘python -m gitlab’ (cd2a14e)

  • Merge pull request #738 from jeroendecroos/Gitlab_from_config_inheritance

Make gitlab.Gitlab.from_config a classmethod (6bd1902)

  • Make gitlab.Gitlab.from_config a classmethod (0b70da3)

  • Merge pull request #732 from hakanf/master

Re-enable command specific help messages (a6e10f9)

  • Use sys.exit as in rest of code (6fe2988)

  • Merge pull request #729 from xarx00/PR-bugfix-716

Fix for #716: %d replaced by %s (bc973d4)

  • Re-enable command specific help mesaages

This makes sure that the global help message wont be printed instead of the command spedific one unless we fail to read the configuration file (a8caddc)

  • Fix for #716: %d replaced by %s (675f879)

  • Merge pull request #725 from python-gitlab/fix/699

fix(api): Make *MemberManager.all() return a list of objects (1792442)

  • Merge pull request #721 from purificant/fix_typo

fix tiny typo (b21fa28)

  • fix tiny typo (2023875)

  • Merge pull request #707 from python-gitlab/fix/python-tests

fix: use python2 compatible syntax for super (e58d2a8)

  • Merge pull request #706 from python-gitlab/chore/ci-existing-release

chore(ci): don’t try to publish existing release (39cb97d)

  • Merge pull request #702 from jpiron/eq_hash

Implement eq and hash methods (a4ea0fe)

  • Merge pull request #705 from python-gitlab/release-1.8.0

Release version 1.8.0 (57fa4e3)

  • Release version 1.8.0 (4fce338)

  • Merge pull request #701 from jpiron/fix_all_behaviour

Fix all kwarg behaviour (8ce4e9e)

  • Implement eq and hash methods

To ease lists and sets manipulations. (3d60850)

  • Fix all kwarg behaviour

all kwarg is used to manage GitlabList generator behaviour. However, as it is not poped from kwargs, it is sent to Gitlab API. Some endpoints such as the project commits one, support a all attribute. This means a call like project.commits.list(all=True, ref_name=&#39;master&#39;) won’t return all the master commits as one might expect but all the repository’s commits. To prevent confusion, the same kwarg shouldn’t be used for 2 distinct purposes. Moreover according to the documentation, the all project commits API endpoint attribute doesn’t seem supported. (6b2bf5b)

  • Merge pull request #689 from python-gitlab/fix/wrong-rebase

fix: re-add merge request pipelines (31bca2f)

  • Merge pull request #685 from Joustie/master

feat: Added approve method for Mergerequests (641b80a)

  • Merge branch ‘master’ into master (b51d296)

  • Merge pull request #687 from python-gitlab/fix/683/raw_download

fix(api): Don’t try to parse raw downloads (52d7631)

  • Merge pull request #680 from python-gitlab/chore/automatic-deploy

chore: release tags to PyPI automatically (ca8c85c)

  • Merge pull request #681 from python-gitlab/no-param-conflicts

fix(api): avoid parameter conflicts with python and gitlab (572029c)

  • Merge pull request #678 from appian/backoff-requests

Fix missing “Retry-After” header and fix integration tests (89679ce)

  • Merge pull request #673 from python-gitlab/fix/672

fix(api): make reset_time_estimate() work again (ce2c835)

  • Merge pull request #664 from python-gitlab/docs/commit-message

docs(readme): provide commit message guidelines (85ac102)

  • Merge pull request #659 from python-gitlab/docs/readme-pypi

docs(setup): use proper readme on PyPI (9be82e1)

  • Merge pull request #657 from python-gitlab/release-1.7.0

Prepare the 1.7.0 release (704ca51)

  • Prepare the 1.7.0 release (456f3c4)

  • Merge pull request #656 from esabouraud/feature-protectedbranchesoptions

Issue 653 Add access control options to protected branch creation (59e3e45)

  • Add access control options to protected branch creation (cebbbf6)

  • Merge pull request #652 from roozbehf/fix/docker-enable-use-of-yaml

fix: enable use of YAML in the CLI (728f2dd)

  • Merge pull request #651 from roozbehf/fix/docker-entrypoint-arguments

fix: docker entry point argument passing (f945910)

  • Merge pull request #641 from python-gitlab/refactor/excpetion_msg

Improve error message handling in exceptions (7bd41cb)

  • Merge pull request #625 from python-gitlab/fix/611/resource_label_event

Add support to resource label events (20eb7d8)

  • Merge pull request #642 from python-gitlab/feature/589/member_all

[feature] Add support for members all() method (22536f3)

  • [feature] Add support for members all() method

Closes #589 (ef1523a)

  • Improve error message handling in exceptions

  • Depending on the request Gitlab has a ‘message’ or ‘error’ attribute in the json data, handle both

  • Add some consistency by converting messages to unicode or str for exceptions (depending on the python version)

Closes #616 (1fb1296)

  • Merge pull request #639 from python-gitlab/fix/628/doc_typo

[docs] Fix typo in custom attributes example (011274e)

  • Merge pull request #638 from python-gitlab/fix/633/milestone_filter

[docs] Fix the milestone filetring doc (iid -> iids) (e6df9a8)

  • [docs] Fix typo in custom attributes example

Closes #628 (bb251b8)

  • [docs] Fix the milestone filetring doc (iid -> iids)

Fixes #633 (0c9a00b)

  • Add support to resource label events

Closes #611 (95d0d74)

  • Merge pull request #634 from python-gitlab/docs/project-typo

docs(projects): fix typo in code sample

Closes #630 (c8eaeb2)

  • Merge pull request #636 from python-gitlab/docs/groups-fix-typo

docs(groups): fix typo (c72a87a)

  • Merge pull request #627 from nicgrayson/fix-docs-typo

Fix 3 typos in docs (7f09666)

  • Fix 3 typos (a5ab2bb)

  • Merge pull request #624 from python-gitlab/update/docker-image

Use the pythongitlab/test-python-gitlab docker image for tests (742243f)

  • Merge pull request #619 from python-gitlab/issue/595

[docs] Add an example of pipeline schedule vars listing (fcce7a3)

  • Merge pull request #626 from python-gitlab/fix/596/maintainer_wanted

[README] Remove the “maintainer(s) wanted” notice (bc6ce04)

  • [README] Remove the “maintainer(s) wanted” notice

Closes #596 (f51fa19)

  • [docs] Add an example of pipeline schedule vars listing

Closes #595 (f7fbfca)

  • Use the pythongitlab/test-python-gitlab docker image for tests

This images is updated to the latest GitLab CE.

Fix the diff() test to match the change in the API output. (2c6c929)

  • Merge pull request #620 from bittner/patch-1

Add Gitter badge to README (74623cf)

  • Add Gitter badge to README (31d1c5d)

  • Merge pull request #613 from mkosiarc/fixDoc

[docs] fix discussions typo (368a34d)

  • [docs] fix discussions typo (54b6a54)

  • Merge pull request #605 from python-gitlab/fix/docker

fix(docker): use docker image with current sources (c9f7986)

  • Merge pull request #608 from python-gitlab/ci-output-option

docs(cli): add PyYAML requirement notice (156a21e)

  • Merge pull request #607 from python-gitlab/refactor/rename-variable

refactor: rename MASTER_ACCESS (5ff2608)

  • Merge pull request #601 from max-wittig/fix/help-usage

fix(cli): print help and usage without config file (32b5122)

  • Merge pull request #600 from hans-d/docker

more flexible docker (3a8b1a0)

  • Merge branch ‘master’ into docker (756c73c)

  • Add project protected tags management (#581) (ea71f1d)

  • more flexible docker (21d2577)

  • README: add a note about maintainers (77f4d3a)

  • Merge pull request #586 from Halliburton-Landmark/project-issue-create-args

add missing comma in ProjectIssueManager _create_attrs (58d5c0a)

  • add missing comma in ProjectIssueManager _create_attrs

This fixes the argument handling for assignee/milestone ID when for project-issue create (83fb4f9)

  • [docs] Add a note about GroupProject limited API (9e60364)

  • Fix the https redirection test (6f80380)

  • [docs] add a warning about https://

http to https redirection cause problems. Make notes of this in the docs. (042b706)

  • [docs] fix cut and paste leftover (b02c30f)

  • Use https:// for gitlab URL (256518c)

  • [docs] Fix the owned/starred usage documentation

Closes #579 (ccf0c2a)

  • 1.6.0 release (d8c2488)

  • [cli] Fix the project-export download

Closes #559 (facbc8c)

  • Minor doc updates (e9506d1)

  • Add a FAQ (4d4c8ad)

  • Raise an exception on https redirects for PUT/POST

POST and PUT requests are modified by clients when redirections happen. A common problem with python-gitlab is a misconfiguration of the server URL: the http to https redirection breaks some requests.

With this change python-gitlab should detect problematic redirections, and raise a proper exception instead of failing with a cryptic error.

Closes #565 (a221d7b)

  • [docs] Add/updates notes about read-only objects

MR and issues attached to the root API or groups are not editable. Provide notes describing how to manage this. (80a68f9)

  • Merge pull request #572 from btmanm/master

Update projects.rst (ff6ca5d)

  • Update projects.rst (6ada4b0)

  • Merge pull request #569 from mattthias/patch-1

Minor typo “ou” vs. “or” (0a687d3)

  • Minor typo “ou” vs. “or”

This change fixes a minor type in the table of possible values for options in the global section. (a68f459)

  • Add support for project transfers from the projects interface. (#561)

See https://docs.gitlab.com/ee/api/projects.html#transfer-a-project-to-a-new-namespace (a1c79d2)

  • Added support for listing forks of a project (#562) (b325bd7)

  • MR: add the squash attribute for create/update

Closes #557 (35c8c82)

  • Implement MR.pipelines()

Closes #555 (32ae924)

  • Support group and global MR listing

Closes #553 (0379efa)

  • Project import: fix the override_params parameter

Closes #552 (3461904)

  • [cli] Fix the case where we have nothing to print (a139179)

  • [cli] Output: handle bytes in API responses

Closes #548 (bbef1f9)

  • Improve the snippets examples

closes #543 (bdbec67)

  • Merge pull request #542 from tpdownes/patch-1

Fix simple typo in identity modification example (9751ab6)

  • Fix simple typo in identity modification example (35fe227)

  • [docs] don’t use hardcoded values for ids (fe43a28)

  • 1.5.1 release (5e6330f)

  • Improve the protect branch creation example

Closes #536 (590c41a)

  • Fix the ProjectPipelineJob base class

Closes #537 (4cf8118)

  • Prepare the 1.5.0 release (eaa4450)

  • [cli] Fix the non-verbose output of ProjectCommitComment

Closes #433 (d5289fe)

  • Use the same description for **kwargs everywhere (b1c6392)

  • [docs] Add an example for external identities settings

Fixes #528 (21e382b)

  • Revert “make as_list work for all queries”

This reverts commit 8e787612fa77dc945a4c1327e9faa6eee10c48f2.

This change broke the basic generator usage (Fixes #534) (1a04634)

  • Add support for epics API (EE)

Fixes #525 (ba90e30)

  • README update (b2cb700)

  • ProjectPipelineJob objects can only be listed

And they are not directly related to ProjectJob objects.

Fixes #531 (e1af0a0)

  • Add support for the LDAP gorups API (ebf822c)

  • Add support for the EE license API (5183069)

  • Merge pull request #530 from stefancrain/master

Correct session example (3f88ad0)

  • Correct session example (01969c2)

  • Implement MR-level approvals

Fixes #323 (59a19ca)

  • Add push rules tests (8df6de9)

  • Add project push rules configuration (#520) (2c22a34)

  • [docs] projects.all() doesn’t exist in v4

Fixes #526 (617aa64)

  • Pull mirroring doesn’t return data (b610d66)

  • Add support for Project.pull_mirror (EE) (ebd6217)

  • Add support for board creation/deletion (EE) (f4c4e52)

  • Add support for LDAP groups (d6a61af)

  • Merge pull request #514 from jouve/generator

make as_list=False work for all=True queries (a6512f9)

  • Add support for issue links (EE)

Fixes #422 (8873eda)

  • Add geo nodes API support

Fixes #524 (39c8ad5)

  • Merge branch ‘master’ of github.com:python-gitlab/python-gitlab (5a855fd)

  • Merge pull request #522 from beyondliu/master

fix #521 change post_data default value to None (6dd8774)

  • Add basic testing forr EE endpoints

Today we don’t have a solution for easily deploying an EE instance so using the functional tools is not possible.

This patch provides a testing script that needs to be run against a private EE instance. (c88333b)

  • Add support for project-level MR approval configuration (473dc6f)

  • fix #521 change post_data default value to None (d4c1a8c)

  • make as_list work for all queries (8e78761)

  • Merge pull request #519 from jouve/silence

silence logs/warnings in unittests (bbefb99)

  • silence logs/warnings in unittests (3fa24ea)

  • Merge pull request #517 from jouve/dedup

projectpipelinejob was defined twice (92ca5c4)

  • projectpipelinejob was defined twice (17d9354)

  • Use python 2 on travis for now (33c2457)

  • tests: default to python 3

Fix the bytes/str issues (b3df26e)

  • Make ProjectCommitStatus.create work with CLI

Fixes #511 (34c8a03)

  • time_stats(): use an existing attribute if available

A time_stats attribute is returned by GitLab when fetching issues and merge requests (on reasonably recent GitLab versions). Use this info instead of making a new API call if possible.

Fixes #510 (f2223e2)

  • Update time stats docs (f8e6b13)

  • Fix the IssueManager path to avoid redirections (eae1805)

  • Add support for group badges

Also consolidate project/group badges tests, and add some docs

Fixes #469 (9412a5d)

  • Merge pull request #507 from Miouge1/badges

Add support for Project badges (01a41ef)

  • Add support for the gitlab CI lint API (40b9f4d)

  • Update the settings attributes (0cc9828)

  • Implement runner token validation (71368e7)

  • Runners can be created (registered) (782875a)

  • Implement runner jobs listing (0be81cb)

  • Add missing project attributes (096d9ec)

  • Add pipeline listing filters (51718ea)

  • Update MR attributes (2332904)

  • Implement the markdown rendering API

Testing will be enable when GitLab 11.0 is available. (9be50be)

  • Add support for group boards (fbd2010)

  • Fix the participants() decorator (8374bcc)

  • Issues: add missing attributes and methods (e901f44)

  • Update some group attributes (4ec8975)

  • Add feature flags deletion support (f082568)

  • Add support for environment stop() (9c19e06)

  • deploy key: add missing attributes (6779616)

  • Deployment: add list filters (ce7911a)

  • Add commit.merge_requests() support (c19ad90)

  • Enable mr.participant test (3c53f7f)

  • Implement commit.refs() (32569ea)

  • Add missing docs file (63a4c7c)

  • Implement user_agent_detail for snippets

Add a new UserAgentDetail mixin to avoid code duplication. (7025743)

  • Add support for Project badges (e00cad4)

  • Add support for merged branches deletion (590ea0d)

  • Add support for the discussions API

Fixes #501 (4461139)

  • Document the global per_page setting (660f0cf)

  • Merge pull request #505 from jouve/config_per_page

add per_page config option (d981904)

  • add per_page config option (589a9aa)

  • Add support for the search API

Fixes #470 (97c8619)

  • Add support for project import/export

Fixes #471 (b5f9616)

  • pep8 fix (42007ec)

  • Add support for user avatar upload

Fixes #308 (174185b)

  • travis-ci: remove the v3 tests (175abe9)

  • [docs] update the sphinx extension for v4 objects (194ed0b)

  • [docs] Rework the examples pages

  • Get rid of the .py files and bring all the python examples in the RST files

  • Fix a few things (5292ffb)

  • Add release notes for 1.5 (2c34237)

  • Drop GetFromListMixin (09d1ec0)

  • Drop API v3 support

Drop the code, the tests, and update the documentation. (fe89b94)

  • ChangeLog: fix link (7011694)

  • Prepare the 1.4.0 release (3ad706e)

  • pep8 fix (e6ecf65)

  • Deprecate GetFromListMixin

This mixin provides a workaround for get() for GitLab objects that don’t implement a ‘get a single object’ API. We are now getting conflicts because GitLab adds GET methods, and this is against the “Implement only what exists in the API” strategy.

Also use the proper GET API call for objects that support it. (a877514)

  • longer docker image startup timeout for tests (5335788)

  • Add docs for the files arg in http_* (79c4682)

  • Merge pull request #500 from ericfrederich/efficient_get

More efficient .get() for group members. (66d8f30)

  • More efficient .get() for group members.

Fixes #499 (dabfeb3)

  • api-usage: bit more detail for listing with all (4cc9739)

  • prepare release notes for 1.4 (68b798b)

  • [tests] fix functional tests for python3

Fixes #486 (3dc997f)

  • [docs] update service.available() example for API v4

Fixes #482 (6d4ef0f)

  • [docs] add a code example for listing commits of a MR

Fixes #491 (037585c)

  • [docs] move mr samples in rst file (a643763)

  • Merge pull request #484 from Matusf/docs-example-raises-attribute-error

Change method for getting content of snippet (85f2388)

  • Fix URL encoding on branch methods

Fixes #493 (736fece)

  • Add API v3 example (5c16c8d)

  • Merge pull request #488 from siemens/feat/rate-limit

feat: obey the rate limit (86a8251)

  • Revert “Token scopes are a list”

This reverts commit 32b399af0e506b38a10a2c625338848a03f0b35d. (25ed8e7)

  • Merge pull request #483 from ToonMeynen/patch-2

Update projects.py documentation (2b9ae5c)

  • Change method for getting content of snippet (505c749)

  • Update projects.py

Add missing attributes to file.create in order to make it work. (629b1e1)

  • Merge pull request #481 from max-wittig/docs/fix-typo

docs(projects): fix typo (f3533cd)

  • Fix the impersonation token deletion example

Fixes #476 (c5b9676)

  • [docs] Move notes examples in their own file

Fixes #472 (f980707)

  • Expose additional properties for Gitlab objects

  • url: the URL provided by the user (from config or constructor)

  • api_url: the computed base endpoint (URL/api/v?)

Fixes #474 (f09089b)

  • Token scopes are a list (32b399a)

  • [docs] fix GitLab refernce for notes (33b2b1c)

  • Provide a basic issue template (3d8d413)

  • Get rid of _sanitize_data

It was used in one class only, no need for added complexity. (79dc1f1)

  • Implement attribute types to handle special cases

Some attributes need to be parsed/modified to work with the API (for instance lists). This patch provides two attribute types that will simplify parts of the code, and fix some CLI bugs.

Fixes #443 (1940fee)

  • update docs copyright years (455a8fc)

  • [docs] Merge builds.rst and builds.py (78bb6b5)

  • Support downloading a single artifact file

Fixes #432 (9080f69)

  • pep8 fix (9cb6bbe)

  • [cli] Fix listing of strings (cb8ca65)

  • Add basic unit tests for v4 CLI (88391bf)

  • [cli] Restore the –help option behavior

Fixes #381 (7c6be94)

  • Add support for recursive tree listing

Fixes #452 (d35a31d)

  • [cli] Allow to read args from files

With the @/file/path syntax (similar to curl) user can provide values from attributes in files.

Fixes #448 (748d57e)

  • [docs] Commits: add an example of binary file creation

Binary files need to be encoded in base64.

Fixes #427 (c7b3f96)

  • [docs] Fix the time tracking examples

Fixes #449 (4a2ae8a)

  • tests: increase waiting time and hope for the best (2e51332)

  • Merge pull request #426 from tardyp/readmixin

introduce RefreshMixin (ee4591d)

  • introduce RefreshMixin

RefreshMixin allows to update a REST object so that you can poll on it. This is mostly useful for pipelines and jobs, but could be set on most of other objects, with unknown usecases. (3424333)

  • Merge pull request #446 from jwilk-forks/spelling

Fix typos in documentation (6bcc92a)

  • Fix typos in documentation (c976fec)

  • [cli] _id_attr is required on creation (e65dfa3)

  • CLI: display_list need to support **kwargs (5e27bc4)

  • [cli] fix listing for json and yaml output

Fixes #438 (4bdce7a)

  • Merge pull request #445 from esabouraud/feature-unshare

Add support for unsharing projects with groups (6c08266)

  • Add support for unsharing projects to v3 API (untested) (c8c4b42)

  • Add support for unsharing projects to v4 API (5fdd06e)

  • ProjectKeys can be updated

Closes #444 (9a30266)

  • Require requests>=2.4.2

Closes #441 (a7314ec)

  • Prepare the 1.3.0 release (10bd1f4)

  • Add docs for pipeline schedules (ac123df)

  • Move the pipelines doc to builds.rst (d416238)

  • Merge pull request #429 from Miouge1/doc-mr-labels

Add documentation about labels update (0cbd9c6)

  • Add documentation about labels update (eb5c149)

  • pep8 fixes (e7546de)

  • Remove pipeline schedules from v3 (not supported) (0a06779)

  • Merge branch ‘mlq-feature/pipeline-schedules’ (39a0429)

  • Project pipeline jobs (fd726cd)

  • Project pipeline schedules (31eb913)

  • Update pipeline schedules code (6a87d38)

  • Merge pull request #420 from tardyp/patch-2

make trigger_pipeline return the pipeline (70c779c)

  • Merge pull request #419 from tardyp/patch-1

Simplify the example for streamed artifacts (6ea7ab7)

  • fix pep8 (8134f84)

  • add a Simplified example for streamed artifacts

Going through an object adds a lot of complication. Adding example for unzipping on the fly (faeb1c1)

  • Default to API v4 (f276f13)

  • Gitlab can be used as context manager

Fixes #371 (b4f0317)

  • config: support api_version in the global section

Fixes #421 (29bd813)

  • make trigger_pipeline return the pipeline

Trigger_pipeline returns nothing, which makes it difficult to track the pipeline being trigger.

Next PR will be about updating a pipeline object to get latest status (not sure yet the best way to do it) (72ade19)

  • Add Gitlab and User events support

Closes #412 (1ca3080)

  • Add support for getting list of user projects

Fixes #403 (96a1a78)

  • Add support for MR participants API

Fixes #387 (08f19b3)

  • Update the groups documentation

Closes #410 (638da69)

  • Fix wrong tag example

Fixes #416 (e957817)

  • Add manager for jobs within a pipeline. (#413) (bdb6d63)

  • Merge pull request #408 from movermeyer/patch-1

Adding the supported version badge (5149651)

  • Merge pull request #409 from movermeyer/patch-2

Clarifying what compatible means (8a953c2)

  • Clarifying what supports means (b980c9f)

  • Adding the supported version badge (9253661)

  • Prepare v1.2.0 (3a119cd)

  • Respect content of REQUESTS_CA_BUNDLE and *_proxy envvars

Explicitly call the requests session.merge_environment_settings() method, which will use some environment variables to setup the session properly.

Closes #352 (6f50447)

  • Add doc for search by custom attribute (2e2a78d)

  • Add support for user/group/project filter by custom attribute

Closes #367 (65c64eb)

  • Add support for project and group custom variables

implements parts of #367 (fa52024)

  • Add support for features flags

Fixes #360 (f5850d9)

  • Add support for pagesdomains

Closes #362 (c281d95)

  • Add supported python versions in setup.py (6923f11)

  • Add support for subgroups listing

Closes #390 (928865e)

  • Add groups listing attributes (81c9d1f)

  • Merge pull request #406 from ericfrederich/pagination

Allow per_page to be used with generators. (79d2ca4)

  • Allow per_page to be used with generators.

Fixes #405 (3b1d1dd)

  • Update groups tests

Group search in gitlab 10.3 requires a query string with more than 3 characters. Not sure if feature or bug, but let’s handle it. (7efbc30)

  • Minor doc update (variables)

Fixes #400 (70e721f)

  • Update testing tools for /session removal (8ad4a76)

  • Remove now-invalid test (5a5cd74)

  • ProjectFile.create(): don’t modify the input data

Fixes #394 (0a38143)

  • submanagers: allow having undefined parameters

This might happen in CLI context, where recursion to discover parent attributes is not required (URL gets hardcoded)

Fix should fix the CLI CI. (6f36f70)

  • [docs] Add a note about password auth being removed from GitLab

Provide a code snippet demonstrating how to use cookie-based authentication.

Fixes #380 (e08d3fd)

  • Add missing doc file (93f1499)

  • [docstrings] Explicitly documentation pagination arguments

Fixes #393 (b0ce3c8)

  • mixins.py: Avoid sending empty update data to issue.save (#389) (0c3a6cb)

  • Update project services docs for v4

Fixes #396 (4e048e1)

  • Add support for award emojis

Fixes #361 (b33265c)

  • Make todo() raise GitlabTodoError on error (2167409)

  • Add doc to get issue from iid (#321) (b775069)

  • Merge pull request #382 from ptomato/subscribe-response-code

Expected HTTP response for subscribe is 201 (f624d2e)

  • Merge pull request #374 from benjamb/typos

Fix typos in docs (8f3b656)

  • Update pagination docs for ProjectCommit

In v3 pagination starts at page 0 instead of page 1.

Fixes: #377 (c6c0686)

  • Expected HTTP response for subscribe is 201

It seems that the GitLab API gives HTTP response code 201 (“created”) when successfully subscribing to an object, not 200. (0d5f275)

  • Fix typos in docs (7c886de)

  • Fix link to settings API (be386b8)

  • Revert “Add unit tests for mixin exceptions”

This reverts commit 4ee139ad5c58006da1f9af93fdd4e70592e6daa0. (084b905)

  • Project pipeline jobs (b861837)

  • Project pipeline schedules (34e32a0)

  • Add support for project housekeeping

Closes #368 (9ede652)

  • Add unit tests for mixin exceptions (4ee139a)

  • Add a SetMixin

Use it for UserCustomAttribute, will be useful for {Project,Group}CustomAttribute (#367) (a1b097c)

  • Add support for user_agent_detail (issues)

https://docs.gitlab.com/ce/api/issues.html#get-user-agent-details (397d677)

  • Merge pull request #369 from Lujeni/fix_typo_projects_documentation

[docs] Bad arguments in projetcs file documentation (ad35482)

  • [docs] Bad arguments in projetcs file documentation (5ee4e73)

  • update user docs with gitlab URLs (29d8d72)

  • Add support for user activities (44a7ef6)

  • generate coverage reports with tox (7fadf46)

  • typo (2d689f2)

  • Add support for impersonation tokens API

Closes #363 (8fec612)

  • Add missing mocking on unit test (700e84f)

  • Add support for oauth and anonymous auth in config/CLI (0732826)

  • Rework authentication args handling

  • Raise exceptions when conflicting arguments are used

  • Build the auth headers when instanciating Gitlab, not on each request

  • Enable anonymous Gitlab objects (#364)

Add docs and unit tests (e9b1583)

  • Remove deprecated objects/methods (ba6e09e)

  • Oauth token support (#357) (c30121b)

  • Merge branch ‘master’ of github.com:python-gitlab/python-gitlab (3bc3e60)

  • Merge pull request #365 from jeromerobert/master

[doc] Fix project.triggers.create example with v4 API (30b1c03)

  • [doc] Fix project.triggers.create example with v4 API (6c5ee84)

  • Merge pull request #342 from matejzero/mattermost

Add mattermost service support (82897b7)

  • Add users custome attributes support (4fb2e43)

  • 1.1.0 release (32f7e17)

  • improve comment in release notes (9eff543)

  • [doc] Add sample code for client-side certificates

Closes #23 (fa89746)

  • Module’s base objects serialization (#359)

Make gitlab objects serializable

With current implementation of API v3 and v4 support, some instances have properties of type module and are not serializable. Handle these properties manually with setstate and getstate methods. (226e6ce)

  • Pagination generators: expose more information

Expose the X-* pagination attributes returned by the Gitlab server when requesting lists.

Closes #304 (38d4467)

  • Add a contributed Dockerfile

Thanks oupala!

Closes #295 (fba7730)

  • Fix the CLI for objects without ID (API v4)

Fixes #319 (9dd410f)

  • Update the repository_blob documentation

Fixes #312 (d415cc0)

  • Add support for wiki pages (5082879)

  • Move the ProjectManager class for readability (4744200)

  • Add support for GPG keys

Closes #355 (d0c4118)

  • Add support for group milestones

Closes #349 (aba713a)

  • Move group related code for readability (cf6767c)

  • Update the ssl_verify docstring (4c3aa23)

  • Project: add support for printing_merge_request_link_enabled attr

Closes #353 (3a8c480)

  • ProjectFileManager: custom update() method

Closes #340 (fe5805f)

  • Document the Gitlab session parameter

Provide a proxy setup example.

Closes #341 (1b5d480)

  • [docs] document get_create_attrs in the API tutorial (b23e344)

  • Change ProjectUser and GroupProject base class

python-gitlab shouldn’t try to provide features that are not existing in the Gitlab API: GroupProject and ProjectUser objects should not provide unsupported API methods (no get, no create, no update).

This Closes #346 by making explicit that we don’t support these non-existant methods. (8c9ad29)

  • Remove support for “constructor types” in v4

In v3 we create objects from json dicts when it makes sense. Support for this feature has not been kept in v4, and we didn’t get requests for it so let’s drop the _constructor_types definitions. (32ea62a)

  • Snippet notes support all the CRUD methods

Fixes #343 (dc504ab)

  • Add mattermost service support (b5e6a46)

  • ProjectFileManager.create: handle / in file paths

Replace / with %2F as is done in other methods.

Fixes #339 (9d0a479)

  • Add support for listing project users

https://docs.gitlab.com/ce/api/projects.html#get-project-users

Closes #328 (d6fa94e)

  • [docs] improve the labels usage documentation

Closes #329 (5945537)

  • Drop leftover pdb call (316754d)

  • Tags release description: support / in tag names (f3f300c)

  • [docs] update the file upload samples

Closes #335 (72664c4)

  • Make the delete() method handle / in ids

Replace the / with the HTTP %2F as is done with other methods.

Closes #337 (8764903)

  • Fix trigger variables in v4 API (#334)

Fix trigger variables in v4 API

Close #333 (ac430a3)

  • Prepare the 1.0.2 release (9e09cf6)

  • ProjectFile: handle / in path for delete() and save()

Fixes #326 (05656bb)

  • Properly handle the labels attribute in ProjectMergeRequest

This should have made it into e09581fc but something went wrong (probably a PEBCAK).

Closes #325 (69f1045)

  • [docs] remove example usage of submanagers

Closes #324 (9484106)

  • 1.0.1 release (e5f59bd)

  • Add missing doc file (a346f92)

  • Fix a couple listing calls to allow proper pagination

Project.repository_tree and Project.repository_contributors return lists, so use http_list to allow users to use listing features such as all=True.

Closes #314 (80351ca)

  • CommitStatus: sha is parent attribute

Fixes #316 (7d6f3d0)

  • Merge pull request #317 from mion00/patch-1

Fix http_get method in get artifacts and job trace (d321847)

  • Fix http_get method in get artifacts and job trace (bb5a1df)

  • exception message: mimic v3 API (05da7ba)

  • Exceptions: use a proper error message (e35563e)

  • Fix the labels attrs on MR and issues

Fixes #306 (e09581f)

  • Fix password authentication for v4

Fixes #311 (89bf53f)

  • Merge pull request #309 from mkobit/patch-1

Minor typo fix in “Switching to v4” documentation (9d6036c)

  • Minor typo fix in “Switching to v4” documentation (5841070)

  • adds project upload feature (#239) (29879d6)

  • Merge pull request #307 from RobberPhex/fix-tag-api

Fix tag api (fd40fce)

  • add list method (b537b30)

  • GitlabError filled by response (4b36786)

  • Tag can get by id (cc249ce)

  • Update changelog, release notes and authors for v1.0 (3d8df3c)

  • Switch the version to 1.0.0

The v4 API breaks the compatibility with v3 (at the python-gitlab level), but I believe it is for the greater good. The new code is way easier to read and maintain, and provides more possibilities.

The v3 API will die eventually. (670217d)

  • pep8 fix (d0e2a15)

  • Improve the docs to make v4 a first class citizen (60efc83)

  • [v4] fix CLI for some mixin methods (0268fc9)

  • FIX Group.tranfer_project (947feaf)

  • tests: faster docker shutdown

Kill the test container violently, no need to wait for a proper shutdown. (d8db707)

  • tests: default to v4 API (0099ff2)

  • Add support for protected branches

This feature appeared in gitlab 9.5.

Fixes #299 (c99e399)

  • Merge branch ‘group-variables’ (fcccfbd)

  • Add support for group variables (eb191df)

  • [v4] More python functional tests (0e0d4ae)

  • update tox/travis for CLI v3/4 tests (311464b)

  • [tests] Use -n to not use a venv (5210956)

  • [v4] Make sudo the first argument in CLI help (022a0f6)

  • Fix the v4 CLI tests (id/iid) (b0af946)

  • [v4] Fix the CLI for project files (cda2d59)

  • Make CLI tests work for v4 as well (f00562c)

  • [v4] Use - instead of _ in CLI legacy output

This mimics the v3 behavior. (f762cf6)

  • make v3 CLI work again (59550f2)

  • CLI: yaml and json outputs for v4

Verbose mode only works with the legacy output. Also add support for filtering the output by defining the list of fields that need to be displayed (yaml and json only). (abade40)

  • [v4] CLI support is back (9783207)

  • [v4] drop unused CurrentUserManager.credentials_auth method (a4f0c52)

  • README: mention v4 support (b919555)

  • Update the objects doc/examples for v4 (4057644)

  • Fix Args attribute in docstrings (80eab7b)

  • [v4] Fix getting projects using full namespace (72e783d)

  • Fix URL for branch.unprotect (279704f)

  • on_http_error: properly wrap the function

This fixes the API docs. (4ed22b1)

  • [v4] fix the project attributes for jobs

builds_enabled and public_builds are now jobs_enabled and public_jobs. (d1e7cc7)

  • Fix Gitlab.version()

The method was overwritten by the result of the call. (45c4aaf)

  • Merge pull request #294 from wayfair/feature_internal_cert_configuration

Support SSL verification via internal CA bundle (0e70dd9)

  • Support SSL verification via internal CA bundle

  • Also updates documentation

  • See issues #204 and #270 (4af4748)

  • Merge pull request #278 from asfaltboy/link-docs-gitlab-token

Docs: Add link to gitlab docs on obtaining a token (657f011)

  • update tox/travis test envs (759f6ed)

  • Merge branch ‘rework_api’ (3ccdec0)

  • Docs: Add link to gitlab docs on obtaining a token

I find these sort of links very user friendly 😅 (9b8b806)

  • Make the project services work in v4 (2816c1a)

  • Fix v3 tests (eee39a3)

  • Update tests for list() changes (7592ec5)

  • remove py3.6 from travis tests (217dc3e)

  • Restore the prvious listing behavior

Return lists by default : this makes the explicit use of pagination work again.

Use generators only when as_list is explicitly set to False. (5a4aafb)

  • functional tests for v4

Update the python tests for v4, and fix the problems raised when running those tests. (d7c7911)

  • Restore correct exceptions

Match the exceptions raised in v3 for v4.

Also update the doc strings with correct information. (c15ba3b)

  • Merge pull request #282 from velvetz7/docs_typo

Fixed repository_compare examples (e87835f)

  • Changed attribution reference (73be8f9)

  • Fix merge_when_build_succeeds attribute name

Fixes #285 (374a6c4)

  • Fix merge_when_build_succeeds attribute name

Fixes #285 (67d9a89)

  • Merge branch ‘master’ into rework_api (274b3bf)

  • Merge pull request #286 from jonafato/python3.6

Declare support for Python 3.6 (cb8c1a1)

  • Merge pull request #287 from guyzmo/features/dependency_injection

Added dependency injection support for Session (46b7f48)

  • Added dependency injection support for Session

fixes #280

Signed-off-by: Guyzmo <guyzmo+github+pub@m0g.net> (116e3d4)

  • Declare support for Python 3.6

Add Python 3.6 environments to tox.ini and .travis.yml. (4c916b8)

  • fixed repository_compare examples (261db17)

  • remove useless attributes (fe3a06c)

  • Refactor the CLI

v3 and v4 CLI will be very different, so start moving things in their own folders.

For now v4 isn’t working at all. (e3d50b5)

  • Add missing doc files (fd5ac4d)

  • typo (67be226)

  • build submanagers for v3 only (ea79bdc)

  • Fix GroupProject constructor (afe4b05)

  • Merge pull request #276 from elisarver/patch-1

Missing expires_at in GroupMembers update (f19681f)

  • minor doc updates (6e5a6ec)

  • Fix changelog and release notes inclusion in sdist (1922cd5)

  • Rework documentation (1a7f672)

  • Missing expires_at in GroupMembers update

CreateAttrs was set twice in GroupMember due to possible copy-paste error. (d41e972)

  • Remove unused future.division import

We don’t do math. (2a0afc5)

  • add support for objects delete() (32c704c)

  • pep8 fixes (26c0441)

  • Document switching to v4 (186e11a)

  • 0.10 is old history: remove the upgrade doc (76e9b12)

  • 0.21.2 release (19f1b1a)

  • Add laziness to get()

The goal is to create empty objects (no API called) but give access to the managers. Using this users can reduce the number of API calls but still use the same API to access children objects.

For example the following will only make one API call but will still get the result right:

gl.projects.get(49, lazy=True).issues.get(2, lazy=True).notes.list()

This removes the need for more complex managers attributes (e.g. gl.project_issue_notes) (61fba84)

  • Drop invalid doc about raised exceptions (197ffd7)

  • Add new event types to ProjectHook (a0f215c)

  • Merge pull request #272 from astronouth7303/patch-1

Add new event types to ProjectHook (4ce2794)

  • Fix a few remaining methods (3488c5c)

  • Add new event types to ProjectHook

These are being returned in the live API, but can’t set them. (1a58f7e)

  • tests for objects mixins (68f4114)

  • Add tests for managers mixins (b776c5e)

  • Basic test for GitlabList (f2c4a6e)

  • Fix GitlabList.len (15511bf)

  • Unit tests for REST* classes (0d94ee2)

  • Merge branch ‘rework_api’ of github.com:python-gitlab/python-gitlab into rework_api (a5b39a5)

  • Fixed spelling mistake (#269) (2b1e0f0)

  • Tests and fixes for the http_* methods (ff82c88)

  • make the tests pass (f754f21)

  • Migrate all v4 objects to new API

Some things are probably broken. Next step is writting unit and functional tests.

And fix. (f418767)

  • Simplify SidekiqManager (0467f77)

  • New API: handle gl.auth() and CurrentUser* classes (a1c9e2b)

  • Add support for managers in objects for new API

Convert User* to the new REST* API. (a506902)

  • pep8 (9fbdb94)

  • Move the mixins in their own module (fb5782e)

  • Rework the manager and object classes

Add new RESTObject and RESTManager base class, linked to a bunch of Mixin class to implement the actual CRUD methods.

Object are generated by the managers, and special cases are handled in the derivated classes.

Both ways (old and new) can be used together, migrate only a few v4 objects to the new method as a POC.

TODO: handle managers on generated objects (have to deal with attributes in the URLs). (993d576)

  • pep8 again (d809fef)

  • Add lower-level methods for Gitlab()

Multiple goals:

  • Support making direct queries to the Gitlab server, without objects and managers.

  • Progressively remove the need to know about managers and objects in the Gitlab class; the Gitlab should only be an HTTP proxy to the gitlab server.

  • With this the objects gain control on how they should do requests. The complexities of dealing with object specifics will be moved in the object classes where they belong. (c5ad540)

  • import urlencode() from six.moves.urllib.parse instead of from urllib (#268)

Fixes AttributeError on Python 3, as urlencode function has been moved to urllib.parse module.

six.moves.urllib.parse.urlencode() is an py2.py3 compatible alias of urllib.parse.urlencode() on Python 3, and of urllib.urlencode() on Python 2. (88900e0)

  • Tests and fixes for the http_* methods (904c9fa)

  • make the tests pass (d0a9334)

  • Migrate all v4 objects to new API

Some things are probably broken. Next step is writting unit and functional tests.

And fix. (6be990c)

  • Simplify SidekiqManager (230b567)

  • New API: handle gl.auth() and CurrentUser* classes (7193034)

  • Add support for managers in objects for new API

Convert User* to the new REST* API. (5319d0d)

  • pep8 (29cb0e4)

  • Move the mixins in their own module (0748c89)

  • Rework the manager and object classes

Add new RESTObject and RESTManager base class, linked to a bunch of Mixin class to implement the actual CRUD methods.

Object are generated by the managers, and special cases are handled in the derivated classes.

Both ways (old and new) can be used together, migrate only a few v4 objects to the new method as a POC.

TODO: handle managers on generated objects (have to deal with attributes in the URLs). (29e0bae)

  • pep8 again (b7298de)

  • Add lower-level methods for Gitlab()

Multiple goals:

  • Support making direct queries to the Gitlab server, without objects and managers.

  • Progressively remove the need to know about managers and objects in the Gitlab class; the Gitlab should only be an HTTP proxy to the gitlab server.

  • With this the objects gain control on how they should do requests. The complexities of dealing with object specifics will be moved in the object classes where they belong. (7ddbd5e)

  • Prepare for v4 API testing (38bff3e)

  • [v4] Make project issues work properly

  • Use iids instead of ids

  • Add required duration argument for time_estimate() and add_spent_time() (ac3aef6)

  • Remove extra_attrs argument from _raw_list (unneeded) (f3b2855)

  • pep8 fix (0663184)

  • Fix python functional tests (f733ffb)

  • [v4] Make MR work properly

  • Use iids instead of ids (Fixes #266)

  • Add required duration argument for time_estimate() and add_spent_time() (1ab9ff0)

  • install doc: use sudo for system commands

Fixes #267 (a3b8858)

  • Changelog update (4bf251c)

  • Update API docs for v4 (1ac66bc)

  • Fix broken docs examples (746846c)

  • Prepare the 0.21.1 release (3ff7d9b)

  • move changelog and release notes at the end of index (d75e565)

  • [v4] Fix the jobs manager attribute in Project (4f1b952)

  • Prepare the 0.21 release (cd9194b)

  • update copyright years (ba41e5e)

  • [v4] Add support for dockerfiles API (0aa38c1)

  • [v4] Builds have been renamed to Jobs (deac5a8)

  • [v4] Triggers: update object

  • Add support for the description attribute

  • Add take_ownership support

  • Triggers now use id as identifier (29e735d)

  • add a warning about the upcoming v4 as default (5ea7f84)

  • Add v4 support to docs (f2b94a7)

  • Update release notes for v4 (627a6aa)

  • pep8 fix (03ac8da)

  • Merge branch ‘v4_support’ (766efe6)

  • [v4] User: drop the manager filters (dcbb501)

  • [v4] Remove deprecated objects methods and classes (8e4b65f)

  • Deprecate parameter related methods in gitlab.Gitlab

These methods change the auth information and URL, and might have some unwanted side effects.

Users should create a new Gitlab instance to change the URL and authentication information. (7ac1e4c)

  • pop8 fixes (441244b)

  • [v4] Users confirm attribute renamed skip_confirmation (cd98903)

  • [v4] repository tree: s/ref_name/ref/ (2dd84e8)

  • [v4] Try to make the files raw() method work (0d1ace1)

  • [v4] Update triggers endpoint and attrs (0c3fe39)

  • [v4] Milestones: iid => iids (449f607)

  • 202 is expected on some delete operations (b9eb10a)

  • [v4] Rename the ACCESS* variables (cd18aee)

  • [v4] GroupManager.search is not needed (9a66d78)

  • [v4] Rename the visibility attribute

Also change the value of the VISIBILITY_* consts, and move them to the objects module root.

TODO: deal the numerical value used by v3. (27c1e95)

  • [v4] Remove public attribute for projects (9b625f0)

  • [v4] MR s/build/pipeline/ in attributes (9de53bf)

  • [v4] Rename branch_name to branch (8b75bc8)

  • [v4] Update (un)subscribtion endpoints (90c8958)

  • [v4] Update user (un)block HTTP methods (5c8cb29)

  • [v4] Drop ProjectKeyManager.enable() (41f141d)

  • [v4] Add projects.list() attributes

All the ProjectManager filter methods can now be handled by projects.list(). (e789cee)

  • [v4] Update project fork endpoint (6684c13)

  • [v4] Update the licenses templates endpoint (206be8f)

  • [v4] Update project unstar endpoint (76ca234)

  • [v4] Update project keys endpoint (d71800b)

  • [v4] Update iid attr for issues and MRs (9259041)

  • [v4] projects.search() has been removed (af70ec3)

  • [v4] Drop teams support (17dffdf)

  • Add missing base.py file (3f7e5f3)

  • Duplicate the v3/objects.py in v4/

Using imports from v3/objects.py in v4/objects.py will have side effects. Duplication is not the most elegant choice but v4 is the future and v3 will die eventually. (3aa6b48)

  • Reorganise the code to handle v3 and v4 objects

Having objects managing both versions will only make the code more complicated, with lots of tests everywhere. This solution might generate some code duplication, but it should be maintainable. (e853a30)

  • Update Gitlab init docstring (f373885)

  • [v4] Update project search API

  • projects.search() is not implemented in v4

  • add the ‘search’ attribute to projects.list() (deecf17)

  • Initial, non-functional v4 support (c02dabd)

  • Add ‘search’ attribute to projects.list()

projects.search() has been deprecated by Gitlab (ce3dd0d)

  • Update URLs to reflect the github changes (7def297)

  • Fixed repository_tree and repository_blob path encoding (#265) (f3dfa6a)

  • MR: add support for time tracking features

Fixes #248 (324f81b)

  • Available services: return a list

The method returned a JSON string, which made no sense…

Fixes #258 (5b90061)

  • Make GroupProjectManager a subclass of ProjectManager

Fixes #255 (468246c)

  • Add support for nested groups (#257) (5afeeb7)

  • Add support for priority attribute in labels

Fixes #256 (5901a1c)

  • Support milestone start date (#251) (9561b81)

  • Merge pull request #249 from guikcd/patch-1

docs: s/correspnding/corresponding/ (f03613d)

  • s/correspnding/corresponding/ (e5c7246)

  • Feature/milestone merge requests (#247)

Added milestone.merge_requests() API (34c7a23)

  • Update User options for creation and update

Fixes #246 (9d80699)

  • Merge pull request #245 from TimNN/mr-time-stats

Add time_stats to ProjectMergeRequest (f05a24b)

  • add time_stats to ProjectMergeRequest (63a11f5)

  • Prepare 0.20 release (c545504)

  • Merge pull request #244 from gpocentek/issue/209

Make GroupProject inherit from Project (20d6678)

  • Stop listing if recursion limit is hit (#234) (989f3b7)

  • Provide API wrapper for cherry picking commits (#236) (22bf128)

  • add ‘delete source branch’ option when creating MR (#241) (8677f1c)

  • Merge pull request #243 from DmytroLitvinov/fix/bug_242

Change to correct logic of functions (cc4fe78)

  • Change to correct logic of functions (889bbe5)

  • Make GroupProject inherit from Project

Fixes #209 (380bcc4)

  • Implement pipeline creation API (#237) (8c27e70)

  • Properly handle extra args when listing with all=True

Fixes #233 (3b38844)

  • Add support for merge request notes deletion

Fixes #227 (e39d7ea)

  • Add DeployKey{,Manager} classes

They are the same as Key and KeyManager but the name makes more sense.

Fixes #212 (a3f2ab1)

  • Include chanlog and release notes in docs (ea0759d)

  • Minor changelog formatting update (99e6f65)

  • Make sure that manager objects are never overwritten

Group.projects (manager) can be replaced by a list of Project objects when creating/updating objects. The GroupObject API is more consistent and closer to the GitLab API, so make sure it is always used.

Fixes #209 (35339d6)

  • Changelog: improvements. Fixes #229 (#230)

  • change indentation so bullet points are not treated as quote

  • add links to releases

  • add dates to releases

  • use releases as headers (37ee7ea)

  • Time tracking (#222)

  • Added gitlab time tracking features

  • get/set/remove estimated time per issue

  • get/set/remove time spent per issue

  • Added documentation for time tracking functions (92151b2)

  • 0.19 release (cd69624)

  • {Project,Group}Member: support expires_at attribute

Fixes #224 (a273a17)

  • Handle settings.domain_whitelist, partly

The API doesn’t like receiving lists, although documentation says it’s what’s expected. To be investigated.

This fixes the tests. (41ca449)

  • Merge pull request #216 from ExodusIntelligence/hotfix-issue_due_date-215

added due_date attribute to ProjectIssue (1e0ae59)

  • Merge pull request #220 from alexwidener/master

Added pipeline_events to ProjectHook attrs (19c7784)

  • Added pipeline_events to ProejctHook attrs

Ran tests, all passed. (3f98e03)

  • fixes gpocentek/python-gitlab#215 (58708b1)

  • document the dynamic aspect of objects (2f274bc)

  • Deploy keys: rework enable/disable

The method have been moved to the keys manager class as they don’t make sens at all on the project keys themselves.

Update doc and add tests.

Fixes #196 (492a751)

  • Merge pull request #210 from comel/services-1

Add builds-email and pipelines-email services (dad1345)

  • Add builds-email and pipelines-email services (5cfa6fc)

  • deploy keys doc: fix inclusion (1d827bd)

  • Merge branch ‘nutztherookie-patch-1’ (5352c36)

  • Fix install doc

it’s just confusing that it would say “pip” again :) (4fba82e)

  • Add support for commit creation

Fixes #206 (ee666fd)

  • Add support for project runners

This API allows to enable/disable specific runners for a project, and to list the project associated runners.

Fix #205 (04435e1)

  • Support the scope attribute in runners.list() (de0536b)

  • Merge pull request #203 from vilhelmen/master

Update project.archive() docs (c538de7)

  • Update project.archive() docs (e7560a9)

  • Some objects need getRequires to be set to False (05b3abf)

  • Forbid empty id for get()

Unless the class explicitly defines it’s OK (getRequiresId set to True). (18415fe)

  • prepare the 0.18 release (8028ec7)

  • sudo: always use strings

The behavior seems to have changed on recent gitlab releases and providing an ID as int doesn’t work anymore. Using a string seems to make things work again.

Fixes #193 (d6c87d9)

  • Update known attributes for projects

Fixes #181 (3804661)

  • Fix duplicated data in API docs

Fixes #190 (73990b4)

  • Add functional tests for Snippet (d3d8baf)

  • Snippet: content() -> raw()

Using the content() method causes conflicts with the API content attribute. (064e2b4)

  • SnippetManager: all() -> public()

Rename the method to make what it does more explicit. (7453895)

  • [docs] Add doc for snippets (bd7d2f6)

  • Merge branch ‘guyzmo-features/personal_snippets’ (0a4d40e)

  • Merge branch ‘features/personal_snippets’ of https://github.com/guyzmo/python-gitlab into guyzmo-features/personal_snippets (26c8a0f)

  • [CLI] Fix wrong use of arguments

The previous change removed undefined arguments from the args dict, don’t try to use possibly missing arguments without a fallback value. (b05c0b6)

  • [CLI] ignore empty arguments

Gitlab 8.15 doesn’t appreciate arguments with None as value. This breaks the python-gitlab CLI.

Fixes #199 (f4fcf45)

  • [docs] artifacts example: open file in wb mode

Fixes #194 (35c6bbb)

  • [docs] update pagination section

First page is page 1.

Fixes #197 (d86ca59)

  • Added support for Snippets (new API in Gitlab 8.15)

cf Gitlab-CE MR !6373

Signed-off-by: Guyzmo <guyzmo+github@m0g.net> (6022dfe)

  • Merge pull request #192 from galet/gitlab-8.14-jira

Fix JIRA service editing for GitLab 8.14+ (15d3362)

  • Add jira_issue_transition_id to the JIRA service optional fields (f7e6482)

  • Fix JIRA service editing for GitLab 8.14+

GitLab simplified the configuration for JIRA service and renamed most of the fields. To maintain backward compatibility all mandatory fields were moved to optional section. (343c131)

  • prepare 0.17 release (932ccd2)

  • Merge pull request #186 from localmed/fix-should-remove-source-branch

Fix should_remove_source_branch (39288c8)

  • Rework requests arguments

  • Factorize the code

  • Don’t send empty auth information to requests (Fixes #188) (6e5734b)

  • Fix should_remove_source_branch (ac2bf24)

  • Add support for triggering a new build

Fixes #184 (de05dae)

  • CLI: add support for project all –all

Rework the extra opts definition to allow setting typed arguments.

Fixes #153 (f5f734e)

  • Merge pull request #183 from GregoryEAllen/master

Please add these missing attrs (840cb89)

  • Merge pull request #2 from GregoryEAllen/GregoryEAllen-patch-2

Add attr ‘updated_at’ to ProjectIssue (f290b2b)

  • Merge pull request #1 from GregoryEAllen/GregoryEAllen-patch-1

Add attr ‘created_at’ to ProjectIssueNote (14e7ccd)

  • Add attr ‘updated_at’ to ProjectIssue (a25fef5)

  • Add attr ‘created_at’ to ProjectIssueNote (5b24122)

  • Add support for templates API

Add gitlab CI and gitignores APIs

Rework the templates/license API docs (570e75d)

  • Restore the Gitlab.user_projects manager (463893f)

  • Make the manager objects create mor dynamic

For the gitlab.Gitlab object make the detection of “submanagers” more dynamic. This will avoid duplication of definitions.

Update the sphinx extension to add these managers in the list of attributes. (81e1c13)

  • Implement merge requests diff support (92180e4)

  • Remove deprecated methods

Also deprecate {un,}archive_() in favor of {un,}archive().

Fix #115 (c970a22)

  • Add a ‘report a bug’ link on doc (258aab4)

  • Implement repr for gitlab objects

Fix #114 (1833117)

  • Sphinx ext: factorize the build methods (7cfbe87)

  • Fix tuples definition (6c0a3d9)

  • pep8 fix (68c09b7)

  • API docs: add managers doc in GitlabObject’s (20143f5)

  • Build managers on demand on GitlabObject’s (e57a86b)

  • Fix docstring for http_{username,password} (11c1425)

  • Rework the API documentation

Update the sphinx extension to add method definition in the docs. This makes the documentation a bit more usable.

Hide attributes that should not have been exposed. They still exist in the code but their documentation doesn’t make much sense. (be83ff9)

  • fix line too long (9f7f45f)

  • Move deploy key enable/disable to the object

To keep things consistent with other objects, action methods are available on the object itself, not the manager. (c17ecc0)

  • Merge branch ‘master-project-deploy-keys’ of https://github.com/Asher256/python-gitlab into Asher256-master-project-deploy-keys (0c1817f)

  • add missing files in MANIFEST.in (12fca84)

  • ProjectHook: support the token attribute

Fix #170 (cd5f849)

  • Project deploy key response code = 201 (6bedfc3)

  • Fixing the response and project_id argument (72d982b)

  • Documentation for enable/disable deploy key functions (f9cb718)

  • New exception for ProjectKey.enable_deploy_key and disable_deploy_key (61d4cac)

  • enable/disable deploy key methos moved to the class ProjectKey() (fc5c52c)

  • Delete is used for ‘/projects/%s/deploy_keys/%s/disable’ (67aa795)

  • Feature: enable / disable the deploy key in a project (6310d71)

  • Merge pull request #178 from cgumpert/master

fix bug when retrieving changes for merge request (4689e73)

  • fix bug when retrieving changes for merge request

Erroneously a merge request would return its commit when being queried for its changes. (34d6050)

  • Merge pull request #172 from xiaopeng163/master

edit doc badge url in README.rst (ff32514)

  • edit doc badge url

Signed-off-by: Peng Xiao <xiaoquwl@gmail.com> (376acda)

  • Don’t overwrite attributes returned by the server

Fixes #171 (2c7a999)

  • README typo (62058f6)

  • Add support for the notification settings API (b15f17b)

  • Add support for broadcast messages API (6d3450c)

  • Add support for Gitlab.version() (c185fe2)

  • Add support for boards API

This is not fully usable because the gitlab API has some limitations:

  • not possible to create boards programmatically

  • not possible to get labels ID (https://gitlab.com/gitlab-org/gitlab-ce/issues/23448) (f332907)

  • Merge pull request #169 from hakkeroid/allow-iid-parameter-to-request-distinct-objects

Convert response list to single data source for iid requests (20fdbe8)

  • Convert response list to single data source for iid requests (23b5b6e)

  • Merge pull request #168 from hakkeroid/pass_kwargs_to_object_factory

Pass kwargs to object factory (9da5d69)

  • Add .tox to ignore to respect default tox settings (cc151f3)

  • Pass kwargs to the object factory (ef69808)

  • Merge pull request #165 from hakkeroid/patch-1

Fix ProjectBuild.play raising error even on success (5f444e4)

  • Fix ProjectBuild.play raises error on success

Running play on ProjectBuild raises a GitlabBuildPlayError although the request was successful. It looks like gitlab returns a 200-OK instead of 201-CREATED response and as such always raises an exception. (0793271)

  • README: add badges for pypi and RTD (945cc66)

  • Set version to 0.16 (46ea44a)

  • prepare the 0.16 release (117f7f5)

  • Implement ProjectBuild.play() (673dc36)

  • Merge pull request #159 from JonathonReinhart/158-erase-build

Add ProjectBuild.erase() (d4a24a5)

  • Update docs to use ProjectBuild.erase() (3b3930b)

  • Add ProjectBuild.erase()

We can’t use the existing delete() functionality, because GitLab uses POST /projects/:id/builds/:build_id/erase to erase a build. Instead of overriding delete(), we add a separate erase() method to keep the naming consistent, and allow potentially more fine-grained operations in the future.

  • https://docs.gitlab.com/ce/api/builds.html#erase-a-build (c2f45e9)

  • Workaround gitlab setup failure in tests

While running the functional tests in a venv, the token download somtimes fail. Try to get it multiple times before failing. (7d424ae)

  • rework travis and tox setup (3371e0e)

  • Use the plural merge_requests URL everywhere

This breaks compatibility with older gitlab versions but maintaining support for changed APIs is just too complex and time consuming. See issue #139 if you need a workaround.

Fixes #157 (cb30dd1)

  • Fix examples for file modification

Fixes #156 (d09eaa0)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (6f7e499)

  • Add support for –all in CLI

Fixes #153 (5860421)

  • Merge pull request #155 from rafaeleyng/add-only_allow_merge_if_build_succeeds

add only_allow_merge_if_build_succeeds option to project objects (26d97a7)

  • break lines too long (608ebbd)

  • add only_allow_merge_if_build_succeeds option to project objects (94932a0)

  • Merge pull request #154 from derek-austin/patch-1

Create a project in a group (4390afb)

  • Create a project in a group

Just a sketch, feel free to toss it and do it in the right way. (b057a94)

  • Merge pull request #150 from vilhelmen/master

Add branch protection notes (1e1d467)

  • Brief branch protection notes

You can pass developers_can_push and developers_can_merge to the protect function. Handy! (8a560c6)

  • Merge pull request #147 from derek-austin/derek-austin-patch-1

Missing coma concatenates array values (ddba752)

  • Missing coma concatenates array values

‘enabled_git_access_protocolgravatar_enabled’ were two distinct values in ApplicationSettings.optionalUpdateAttrs. (02a8bf4)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (53f9322)

  • Merge pull request #146 from galet/add-api-url-to-jira-params

JIRA service - add api_url to optional attributes (d83b838)

  • JIRA service - add api_url to optional attributes

The api_url attribute is mandatory at least since GitLab 8.11. Otherwise server returns gitlab.exceptions.GitlabUpdateError: 400: 400 (Bad request) “api_url” not given.

Keep it as optional to maintain backward compatibility with older GitLab versions. (c8c43ee)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (2ac42d6)

  • Merge pull request #144 from koyaan/master

Add the ability to fork to a specific namespace (449830f)

  • fix doc (0c1c894)

  • add doc (648dc86)

  • fix pep8 (a692d59)

  • Add the ability to fork to a specific namespace (4852462)

  • 0.15.1 release (90ad2de)

  • Properly fix _raw_list (dc3dcd1)

  • ‘path’ is an existing gitlab attr, don’t use it

Use path_ instead of path as parameter name for methods using it. Otherwise it might conflict with GitlabObject attributes. (b815f3a)

  • Fix and test pagination

Fixes #140 (c08c913)

  • minor RST fix (47cb278)

  • bump version and update changelog (79f46c2)

  • Add support for project deployments (8d7faf4)

  • Add support for access requests (40db4cd)

  • Add support for project pipelines (8257400)

  • Add support for project services API (ef2dbf7)

  • Remove unused ProjectTagReleaseManager class (ded5258)

  • Fix canGet attribute (typo) (0178f3d)

  • Remove _get_list_or_object() and its tests (451c174)

  • Let _data_for_gitlab return python data (a8f6fdd)

  • Refactor the Gitlab class

Make use of the raw* methods in the CRUD methods. (fe96edf)

  • fix pep8 test (e0d226b)

  • Remove method marked as deprecated 7 months ago (438dc2f)

  • Add copyright header to utils.py (83cb8c0)

  • Move the constants at the gitlab root level (2ced9d0)

  • Add sidekiq metrics support (23b2a30)

  • implement the todo API (131739f)

  • Update the ApplicationSettings attributes (1c53ecb)

  • Fix fork creation documentation

Fixes #136 (baa09fe)

  • Run more tests in travis

Travis has some limitations so this patch sets up some tricks to run the functional tests. (f82f962)

  • ignore pep8 error (fa75571)

  • add a basic HTTP debug method (c9915a4)

  • Update changelog/authors/version for 0.14 (e4624c9)

  • MR merge(): update the object (799b593)

  • MR (un)subscribe: don’t fail if state doesn’t change (d7967c6)

  • Handle empty messages from server in exceptions (178bfb7)

  • MR: fix updates (4a73b85)

  • fix labels deletion example (71edeeb)

  • Fix the listing of some resources

The parent ID wasn’t available in the generated objects, leading to exceptions when trying to use specific methods for these objects.

Fixes #132 (922041d)

  • MR: get list of changes and commits (92edb99)

  • remove debug print statement (4fd00f8)

  • Add support for project environments (5b08d2a)

  • add support for global deploy key listing (9bd2cb7)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (e3ac32f)

  • add a contributing section in README (e6ffd69)

  • doc: replace incorrect archive call() (e1f5e15)

  • document namespaces API (1f52cd2)

  • Merge pull request #131 from chrwen-omicron/enable_container_registry

Added a new project attribute to enable the container registry. (e0f2290)

  • Added a new project attribute to enable the container registry. (d61510e)

  • Add support from listing group issues (580f21e)

  • Docs: drop the FAQ

The only question is now documented in the API examples. (261f947)

  • Improve commit statuses and comments

Fixes #92 (f0fbefe)

  • tests: don’t use deprecated Content method (741896d)

  • CLI: refactor _die() (99d0177)

  • doc: fix doubled parameter (58ddf1d)

  • Replace Snippet.Content() with a new content() method

This new method use the standard lowercase name and implements data streaming. (832ed9f)

  • fix unit tests (3198ead)

  • Groups can be updated (048b1cf)

  • Add missing args in docstrings (075345a)

  • Allow to stream the downloads when appropriate

Some API calls will download possibly large data, resulting in a high memory usage and out-of-memory errors. For these API calls use the requests streaming capabilities and download chunked data. The caller is responsible of providing a callable to actually store the data.

The default callable just prints the data on stdout. (94aea52)

  • Implement ProjectBuild.keep_artifacts (e0cf1c2)

  • Gitlab: add managers for build-related resources (b339ed9)

  • Implement runners global API (6eb11fd)

  • Add docstring for settings manager in Gitlab class (52c8825)

  • Fix pep8 test (63f0c4d)

  • implement CLI for project archive/unarchive/share (fc68e9b)

  • Implement sharing project with a group (e7c4125)

  • Fix ProjectMember update (2df4c9e)

  • Update ProjectSnippet attributes

‘visibility_level’ has been added as an optional attribute to keep compatibility with older releases of gitlab.

Fixes #129 (3ad612d)

  • Implement archive/unarchive for a projet

The methods are called archive_ and unarchive_ to workaround a conflict with the deprecated archive method. Method will be renamed when the archive method is removed. (7ed34ed)

  • Fix the Project.archive call (565c35e)

  • Project: add VISIBILITY_* constants

They should be there instead of having them in the Group class. Variables in Group are keeped for compatibility. (2457823)

  • Implement user emails support (0be4761)

  • document users API (9ba2d89)

  • Add branches API documentation (cdd801e)

  • Merge pull request #128 from rafaeleyng/feat/add-note-events-to-project-hook

add note_events to project hooks attributes (c88c638)

  • add note_events to project hooks attributes (ca662e2)

  • MR: add (un)subscribe support (867b7ab)

  • Merge branch ‘label-subscribe’ (d340d31)

  • Add support for label (un)subscribe (6f29ff1)

  • add support for namespaces (79feb87)

  • milestone: optional listing attrs (dbad3bd)

  • update ProjectLabel attributes (c55fd4b)

  • Add support for project-issue move (73627a2)

  • project issue: proper update attributes (ca68f6d)

  • issues: add missing optional listing parameters (60c9910)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (2e0ac3f)

  • issues: add optional listing parameters (c85276a)

  • Merge pull request #125 from gpocentek/issue-122

Add support for build artifacts and trace (80a1908)

  • Add support for commit comments

https://github.com/gitlabhq/gitlabhq/blob/master/doc/api/commits.md (412e2bc)

  • commit status: optional get attrs (547f385)

  • commit status: add optional context url (0b8ed5a)

  • Make GroupProject more “python-gitlabish” (68d15fd)

  • Merge branch ‘master’ of https://github.com/missionrulz/python-gitlab into missionrulz-master (69e64a3)

  • typo in doc block (d9b9f92)

  • add to init.py & move manager after class declaration (8f707ac)

  • move into own class & create manager class (eb6c26f)

  • Merge pull request #124 from Condla/master

Fix: –title is required argument, when in reality optional (18de4ef)

  • Fix –title is not a required argument anymore (899490b)

  • Fix –title is not a required argument anymore (c24f0d9)

  • Fix that –title is a required argument, when trying to update a ProjectMilestone (bea8ea9)

  • Add support for build artifacts and trace

Fixes #122 (b3e0974)

  • Merge pull request #121 from PeterMosmans/httpauthextended

Added HTTPauth support for even more methods :) (422b163)

  • pylint fix (40d7969)

  • Added HTTPauth support for even more methods :) (59ed4fc)

  • add HTTP auth options to doc (6220308)

  • Merge pull request #120 from PeterMosmans/basicauth

Added support for HTTP basic authentication (11f1e2d)

  • Added support for HTTP basic authentication (e9e48b9)

  • project issue: doc and CLI for (un)subscribe (1b14f5c)

  • Merge pull request #118 from IvicaArsov/issues_subscribe_unsubscribe

Add support for subscribe and unsubscribe in issues (7bbbfbd)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (b8f19ca)

  • Add support for subscribe and unsubscribe in issues (d42687d)

  • version bump (0535808)

  • update changelog and authors (57936af)

  • Merge pull request #110 from chrwen-omicron/remove_next_url_from_cls_kwargs

Remove ‘next_url’ from kwargs before passing it to the cls constructor. (05dd8dc)

  • Manage optional parameters for list() and get()

  • List these elements in the API doc

  • Implement for License objects (fd45397)

  • fix pep8 tests (417d27c)

  • implement list/get licenses (62e4fb9)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (ee1620b)

  • implement star/unstar for projects (1de6b7e)

  • Deprecate Project.archive() (24c283f)

  • Merge pull request #113 from adamreid/master

Enable updates on ProjectIssueNotes (f5c75cb)

  • Rename some methods to better match the API URLs

Also deprecate the file_* methods in favor of the files manager. (45adb6e)

  • ProjectFile: file_path is required for deletion (8ce8218)

  • Rework the Gitlab.delete method

Fixes #107 (0a1bb94)

  • Revert “enable python 3.5 tests for travis”

This reverts commit 1915519f449f9b751aa9cd6bc584472602b58f36. (c3f5b3a)

  • Rework merge requests update

Fixes #76 (aff99b1)

  • enable python 3.5 tests for travis (1915519)

  • Enable deprecation warnings for gitlab only

Fixes #96 (d204e66)

  • Add new optional attributes for projects

Fixes #116 (f12c732)

  • Merge branch ‘master’ of https://github.com/gpocentek/python-gitlab (8edd7f7)

  • Remove unnecessary canUpdate property from ProjectIssuesNote (111b7d9)

  • Drop the next_url attribute when listing

Fixes #106 (64af398)

  • Implement project contributors (1600770)

  • Implement project compare

Fixes #112 (250f348)

  • Add support for Project raw_blob (7a8f81b)

  • Merge pull request #108 from guyzmo/using_requests_session

Adding a Session instance for all HTTP requests (23e8146)

  • Enable updates on ProjectIssueNotes (5fe7e27)

  • update docblock (cd13aff)

  • list projects under group (d4e2cd6)

  • Remove ‘next_url’ from kwargs before passing it to the cls constructor.

The ‘next_url’ argument causes problems in the _construct_url method if it doesn’t belong there. E.g. if you list all projects, change an attribute of a project and then try to save it, the _construct_url will use the ‘next_url’ from the list method and the save will fail. (c261875)

  • Adding a Session instance for all HTTP requests

The session instance will make it easier for setting up once headers, including the authentication payload, and it’s also making it easier to override HTTP queries handling, when using betamax for recording and replaying the test suites. (858352b)

  • Add missing group creation parameters

description and visibility_level are optional parameters for group creation. (61bc24f)

  • Add deletion support for issues and MR

This is supported in gitlabhq master branch for admin users (soft deletion). (9a9a4c4)

  • add “external” parameter for users (349f66e)

  • MR: add support for closes_issues (571a382)

  • MR: add support for cancel_merge_when_build_succeeds (f6a51d6)

  • minor docs fixes (ccbea3f)

  • Add support for MergeRequest validation

Both API and CLI support this feature.

fixes #105 (43e8a2a)

  • Update changelog and authors (bb463ae)

  • version bump (754d5e5)

  • Gitlab.update(): use the proper attributes if defined (f8528cc)

  • add a note about project search API (e48e4ac)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (e46c188)

  • pep8 ignore H803 errors (git messages) (86ade4a)

  • Merge pull request #98 from Asher256/fix-unicode-syntax-py3

Fix the ‘invalid syntax’ on Python 3.2, because of u’password’ (aea678b)

  • Fix the ‘invalid syntax’ on Python 3.2, because of u’password’

More informations regarding this issue:

Operating system: Debian Wheezy, with Python 3.2 and the last version of python-gitlab.

The gitlab module raised this exception, because of the ‘u’ (Unicode):

Traceback (most recent call last): File “push_settings.py”, line 14, in <module> from helper import ROOT_EMAIL, ADMINS, git, old_git File “/opt/scripts/gitlab/helpers/helper.py”, line 25, in <module> from gitlab import Gitlab File “/opt/scripts/gitlab/helpers/gitlab/init.py”, line 32, in <module> from gitlab.objects import * # noqa File “/opt/scripts/gitlab/helpers/gitlab/objects.py”, line 546 selfdict.pop(u’password’, None) ^ SyntaxError: invalid syntax It is a recent change: 01802c0 (Richard Hansen 2016-02-11 22:43:25 -0500 546) selfdict.pop(u’password’, None) 01802c0 (Richard Hansen 2016-02-11 22:43:25 -0500 547) otherdict.pop(u’password’, None)

To solve the issue, ‘u’ was removed. (7ed84a7)

  • Re-implement _custom_list in the Gitlab class

Rename the method _raw_list. This adds support for the all=True option to enable automatic recursion and avoid pagination if requested by the user.

Fixes #93 (453224a)

  • remove unused _returnClass attribute (44d0dc5)

  • CI: implement user get-by-username

fixes #95 (58433d2)

  • CLI: fix discovery of method to execute (7260684)

  • Improve the doc for UserManager

Describe parameters, return values and exceptions for search() and get_by_username(). (b79af1d)

  • Implement “user search” CLI (073d8d5)

  • Merge branch ‘rhansen-get-specific-user’ (6975ac6)

  • define UserManager.get_by_username() to get a user by username (ac2e534)

  • define UserManager.search() to search for users (8f59516)

  • define GitlabObject.eq() and ne() equivalence methods (01802c0)

  • define GitlabObject.as_dict() to dump object as a dict (f15a7cf)

  • Merge pull request #89 from ExodusIntelligence/master

Adding new ProjectHook attributes: (81be3cf)

  • Add a coverage tox env (2e1f84e)

  • Add some unit tests for CLI

Reorganize the cli.py code to ease the testing. (d2e30da)

  • Rework the CLI code

Add support for more subcommands. (8aa8d8c)

  • Merge pull request #90 from ms-boom/fix_custom_list

fix GitlabObject creation in _custom_list (f5ca0eb)

  • fix GitlabObject creation in _custom_list (293a9dc)

  • Add support for user block/unblock (e387de5)

  • Added missing comma (1f81c2d)

  • Adding new ProjectHook attributes:

  • build_events

  • enable_ssl_verification

See the two links below:

  • https://github.com/gitlabhq/gitlabhq/blob/master/doc/api/projects.md#add-project-hook

  • https://github.com/pyapi-gitlab/pyapi-gitlab/pull/173 (db9bbf6)

  • bump version to cleanup my mess on pypi (942468d)

  • Update ChangeLog and AUTHORS (74d82d4)

  • MANIFEST: add .j2 files in docs/ (a495eec)

  • CLI: fix {all,owned,search} project listing (522cfd1)

  • Partially revert 00ab7d00 (9ae26fe)

  • version bump (8642e9e)

  • Merge branch ‘test-script-cleanups’ of https://github.com/rhansen/python-gitlab into rhansen-test-script-cleanups (01e7c06)

  • don’t suppress docker’s standard error

While docker is quite noisy, suppressing stderr makes it difficult to troubleshoot problems. (0024552)

  • wait for the docker container to stop before removing it (52e4377)

  • use ‘docker stop’ instead of ‘docker kill’

The ‘stop’ command first tries SIGTERM before resorting to SIGKILL, which is a gentler way to stop processes. (SIGTERM gives processes an opportunity to clean up before exiting; SIGKILL can’t be caught so it is very abrupt.) (c56fc47)

  • add more log messages (2609cbb)

  • define a testcase() function; use it for tests (37f6d42)

  • use ${CONFIG} instead of repeating the filename (033881e)

  • fix usage error message (bc7332f)

  • Add docstrings to some methods (1b5c8f1)

  • Fix the RTD requirements (2e5476e)

  • improve error handling

Break up pipelines and check the exit status of non-basic commands to ensure that any problems cause the scripts/testcases to fail right away. (5dcceb8)

  • convert scripts to POSIX shell by eliminating bashisms (57f1ad5)

  • quote underquoted variable expansions

This protects against word splitting if the variable contains IFS characters, and it ensures that an empty variable doesn’t become an elided argument. (09ef253)

  • convert $GITLAB to a function

This makes it possible to quote the $CONFIG variable expansion. (c100a04)

  • convert $OK to a function

This makes it possible to quote the variable expansions. (8198e3f)

  • only run deactivate if it exists

The deactivate command only exists if activate is run, but cleanup() might be called before activate is run if there is an error. (6b298c6)

  • ensure that cleanup() runs if terminated by the user (17914a3)

  • check if docker container is up when waiting for gitlab

There’s no point in waiting for GitLab to come up if the docker container died. (58106a0)

  • error out if required utilities aren’t installed (b21fdda)

  • use the log functions for errors and status messages

This causes the error messages to go to standard error, and it makes it easy to prefix all log messages if desired. (867fe2f)

  • add logging and error handling helper functions (7c0e443)

  • compact some case statements (dfc6c70)

  • move common code to build_test_env.sh

Note that build_test_env.sh now creates and prepares the Python virtualenv (it didn’t before). (26999bf)

  • Automatic doc generation for BaseManager classes

Provide a sphinx extension that parses the required/optioanl attributes and add infoo to the class docstring. (a2eca72)

  • wrap long lines

Use line continuations to keep lines shorter than 80 columns. (6df844a)

  • travis lacks py35 support without tricks (770dd4b)

  • add python 3.5 test env (920d248)

  • add support for project builds (ebf36b8)

  • Fix Project.tree()

Add API tests for tree(), blob() and archive(). (fc8affd)

  • Fix project update (141f21a)

  • Rework the version import

This simplifies the setup.py script

Also provide a –version option for CLI (00ab7d0)

  • fix inclusion of api/*.rst (9f256a7)

  • Add sudo support (3711f19)

  • Fix the ‘password’ requirement for User creation (c579c80)

  • Add support for application settings (16d50cd)

  • Implement project variables support (e5438c6)

  • implement project triggers support (c11bebd)

  • Implement setting release info on a tag

Add the set_release_description() method to ProjectTag. Add python API test for this method. (7981987)

  • API tests for tags (0814d86)

  • ProjectTag supports deletion (gitlab 8.4.0) (339d329)

  • Implement ProjectMilestone.issues()

This lists the issues related to the milestone.

Add python API tests for issues. (db1fb89)

  • fix ProjectLabel get and delete (1ecb739)

  • wait a little before running the python tests (9709d79)

  • fix the API test for decode() (c22a19e)

  • increase the timeout value for tests (4e21343)

  • make connection exceptions more explicit (08d3ccf)

  • add a decode method for ProjectFile (2eac071)

  • README is an RST file… (d3a5701)

  • Update README with travis status (a4918a3)

  • fix the test_create_unknown_path test (bf985b3)

  • add a travis configuration file (e40d9ac)

  • Fix the json() method for python 3

Also add unit tests and fix pep8 test (d7271b1)

  • Merge branch ‘rhansen-fix-json’ (982f54f)

  • Merge branch ‘fix-json’ of https://github.com/rhansen/python-gitlab into rhansen-fix-json (26d73e2)

  • use a custom docker image for tests (3f38689)

  • skip BaseManager attributes when encoding to JSON

This fixes the following exception when calling User.json():

TypeError: &lt;gitlab.objects.UserKeyManager object at 0x7f0477391ed0&gt; is not JSON serializable ([`ca6da62`](https://github.com/python-gitlab/python-gitlab/commit/ca6da62010ee88e1b03f7a5abbf69479103aa1e1))
  • add a missing import statement

Add the import inside the function rather than at the top of the file because otherwise it would introduce a circular dependency. (c95b3c3)

  • Add an initial set of API tests (7e4e1a3)

  • include the docs in the tarball (bbcccaa)

  • 0.11.1 release update (5c4f77f)

  • add some CLI tests (097171d)

  • add unit tests for managers (6baea2f)

  • remove debugging print instruction (7e54a39)

  • Fix discovery of parents object attrs for managers (0e0c81d)

  • remove “=” in examples for consistency (a4e29f8)

  • (re)add CLI examples in the doc (1b64a47)

  • Merge pull request #82 from cdbennett/commitstatus

Support setting commit status (02c5398)

  • Support setting commit status

Support commit status updates. Commit status can be set by a POST to the appropriate commit URL. The status can be updated by a subsequent POST to the same URL with the same name and ref, but different values for state, description, etc.

Note: Listing the commit statuses is not yet supported. This is done through a different path on the server, under the repository path.

Example of use from the CLI:

# add a build status to a commit
gitlab project-commit-status create --project-id 2 \
    --commit-id a43290c --state success --name ci/jenkins \
    --target-url http://server/build/123 \
    --description &#34;Jenkins build succeeded&#34; ([`3371008`](https://github.com/python-gitlab/python-gitlab/commit/33710088913c96db8eb22289e693682b41054e39))
  • Support deletion without getting the object first

Use this feature in the CLI to avoid an extra API call to the server. (1d7ebea)

  • cli.py: make internal functions private (e5821e6)

  • Add a script to build a test env

functional_tests.sh has been split in 2 scripts to make easier the run of gitlab container. (572cfa9)

  • Rework gitlab._sanitize

Make it a recursive function and eliminate _sanitize_dict.

Add unit tests. (03d8041)

  • Improve the API documentation. (4781fd7)

  • Rewrite the README

And link to the docs on RTD. (3e8cf4e)

  • Bump version

And update copyright years. (ca44878)

  • Update AUTHORS (0163499)

  • Update ChangeLog for 0.11 (3fd64df)

  • add missing import (9c74442)

  • document the API migration from 0.10 (610bde8)

  • implement group search in CLI (5ea6d0a)

  • Add support for groups search

Factorize the code to avoid duplication with the ProjectManager class. Implement unit tests for the group search.

Original patchh from Daniel Serodio (PR #55). (5513d0f)

  • unit tests for config parser (0ae315a)

  • Implement ProjectManager search/list methods

The existing Gitlab methods are deprecated.

Unit tests have been added. (689ecae)

  • CLI: fix the discovery of possible actions (e48e149)

  • Create a manager for ProjectFork objects (e8631c1)

  • Merge branch ‘fgouteroux-add_fork_support’ (37912c1)

  • Merge branch ‘add_fork_support’ of https://github.com/fgouteroux/python-gitlab into fgouteroux-add_fork_support (77d34b3)

  • Deprecate the “old” Gitlab methods

Update the associated unit tests. (2bf9794)

  • add fork project support (cedf080)

  • README update (dc0099d)

  • Provide a getting started doc for the API (2237d85)

  • Remove extra dep on sphinx-argparse (64d6356)

  • Rework the requirements for RTD (4a53627)

  • Document installation using pip and git (7523a61)

  • Document the CLI (0ee53e0)

  • add unit tests for BaseManager (2a93c62)

  • GitLab -> Gitlab (class names) (fdf295f)

  • fix pretty_print with managers (bef97fe)

  • README update (d0da618)

  • Implement managers to get access to resources

This changes the ‘default’ API, using managers is the recommended way to get/list/create objects. Additional operations will be implemented in followup patchs.

Old methods are deprecated and will disappear in a while. (46f74e8)

  • update the docs copyright years (e5246bf)

  • add missing copyright header (b66672e)

  • Split code in multiple files (8fa4455)

  • remove deprecated methods (118b298)

  • python3: fix CLI error when arguments are missing (7c38ef6)

  • fix the tests (1db3cc1)

  • Rename the _created attribute _from_api (2a76b74)

  • Provide a create method for GitlabObject’s

Instead of using the constructor to do everything (get, list and create), we now provide a class method for each action. This should make code easier to read. (a636d5a)

  • Add the CLI -g short option for –gitlab (7e61a28)

  • Add a get method for GitlabObject

This change provides a way to implement GET for objects that don’t support it, but support LIST.

It is also a first step to a cleaner API. (74dc2ac)

  • functional_tests.sh: support python 2 and 3 (c580b1e)

  • Move request return_code tests in _raise_error_from_response (81b0a06)

  • Version bump (38f17c1)

  • update AUTHORS and ChangeLog (e673dab)

  • Add support for group members update

Closes #73 (99c4710)

  • Merge branch ‘master’ of github.com:gpocentek/python-gitlab (45becb9)

  • Sanitize the id used to construct URLs

Closes #28 (5d88f68)

  • Merge pull request #78 from cdbennett/fix_python3_sort_types

Use name as sort key to fix Python 3 TypeError (6f1fd7e)

  • Use name as sort key to fix Python 3 TypeError

Sort types explicitly by name to fix unorderable types TypeError in Python 3.

The call to sort() on cli.py line 259 produced the error:

TypeError: unorderable types: type() &lt; type() ([`363b75e`](https://github.com/python-gitlab/python-gitlab/commit/363b75e73c2b66ab625811accdb9d639fb068675))
  • try to fix the RTD build (acc1511)

  • Merge pull request #72 from pa4373/newuser-confirm-fix

Can bypassing confirm when creating new user now (d069381)

  • Can bypassing confirm when creating new user (a0fe68b)

  • Test branch creation et deletion (f07de94)

  • Fix GET/POST for project files (9c58013)

  • hide the action attribute (3270865)

  • Fix deletion of object not using ‘id’ as ID

Closes #68 (e5aa69b)

  • README: add missing import in sample (d8fdbc4)

  • setup.py: require requests>=1

Closes #69 (21fdf1b)

  • Provide a Gitlab.from_config method

It provides the Gitlab object creation from the ~/.python-gitlab.cfg, just like the CLI does. (fef8c7f)

  • update README for list(all=True) (6cc8126)

  • don’t list everything by default (a9e8da9)

  • fix pep8 test (e93188e)

  • Merge pull request #64 from jantman/issues/63

python-gitlab Issue #63 - implement pagination for list() (24d5035)

  • Merge pull request #66 from stefanklug/master

Fix error when fetching single MergeRequests (adbe0a4)

  • add support to update MergeRequestNotes (79d452d)

  • fix url when fetching a single MergeRequest (227f71c)

  • issue #63 add unit tests for ‘next’ link handling in list() (719526d)

  • issue #63 - revert logging additions (f9654cd)

  • python-gitlab Issue #63 - implement pagination for list() (33ceed6)

  • Fix the update/delete CLI subcommands

Also update the testing tool to test these features.

Closes #62 (802c144)

  • fix delete and update CLI methods (e57b779)

  • more README updates (0922ed5)

  • Improve the README a bit

Fix typos Detail which options are required in the [global] section (closes #61) (f6abd4d)

  • 0.9.1 release (1f48e65)

  • setup.py: restore the version discovery hack (9966616)

  • functional_test.sh: use a venv (e12abf1)

  • fix setuptool sdist (73c68db)

  • add tools/ to MANIFEST.in (82ff055)

  • add test files to MANIFEST.in (32daf2a)

  • add test-requirements.txt in MANIFEST.in (5c20201)

  • remove executable flag on cli.py (b8ee8f8)

  • get ready for a 0.9 release (dce3193)

  • Provide a basic functional test script

This can be used to quickly test the correct behavior of the CLI. The script is simple and doesn’t test much for now, but it’s a start. (1bc412e)

  • update copyright date (aae8e2d)

  • CLI: remove wrong attributes from the verbose output

These attributes comme from the command line arguments. (d254e64)

  • CLI: provide a –config-file option (711c5be)

  • Rename a few more private methods (bed3adf)

  • Move the CLI in the gitlab package

Setup an console_script entry point to create the executable script. (d7bea07)

  • Fix the tests when the host runs a web server (4c6c778)

  • Projects can be updated

Also fix the projects special listing (all, owned, …)

Closes #54 (7bdb1be)

  • improve handling of id attributes in CLI

closes #31 (8b42559)

  • rework (and fix) the CLI parsing (ede1224)

  • use more pythonic names for some methods (c2d1f8e)

  • make the tests pass (0032d46)

  • setup tox for py27 and py34 tests (8634a4d)

  • move the tests inside the package (03bbfa0)

  • Merge branch ‘tests’ of https://github.com/mjmaenpaa/python-gitlab into mjmaenpaa-tests

Conflicts: setup.py (0443256)

  • Deprecate some Gitlab object methods

raw* methods should never have been exposed; replace them with raw* methods

setCredentials and setToken are replaced with set_credentials and set_token (b7d04b3)

  • sphinx: don’t hardcode the version in conf.py (59173ce)

  • gitlab is now a package (d2e5700)

  • add a tox target to build docs (105896f)

  • Add a tox configuration file

Run pep8 tests only for now, and fix pep8 errors. (82a88a7)

  • Merge pull request #58 from massimone88/master

Used argparse library (99cc43a)

  • change changelog, change, add my name on collaborators, change version (0d5b988)

  • implemented argparse object for parsing the argument of the command line (d44b48d)

  • Merge branch ‘feature/impl_argparse’ into develop (fd473cd)

  • *clean import package +add folder .idea to gitignore (23fe3c9)

  • bug fixed on requiredArguments (d099b11)

  • remove “gitlab” of arguments because conflicts with “gitlab” attribute with GitlabObject class (bdc6f73)

  • remove forgotten argument (e6c85b5)

  • improvement argument required for each action add try/catch for error of parsing of not gitlabObject (2792091)

  • implement argparse library for parsing the arguments create constans for action name clean the code (9439ce4)

  • “timeout” option is an int, not a bool (2d48e71)

  • require sphinxcontrib-napoleon to build the docs (990eeca)

  • Make sphinx-configuration work with python2 (f22bfbd)

  • Updated few gitlab.py docstrings as an example about how to document api (3005b3d)

  • Simple sphinx-project that automatically creates api documentation. (e822b0b)

  • ignore egg-info dirs (d0884b6)

  • add a requirements.txt file (13cd78a)

  • Little documentation about sudo-usage (137ec47)

  • Forgot to add sudo-support to update (7d31e48)

  • Support labels in issues correctly (5d25344)

  • Send proper json with correct content-type and support sudo-argument

Use json-encoder to create proper gitlab-compatible json Send only attributes specified with requiredCreateAttrs and optionalCreateAttrs Send correct content-type header with json Sudo, page & per_page is supported for all methods by using **kwargs to pass them Changed rawPut to have same parameters as rawPost (96a44ef)

  • Update example about how to close issue in README (78c4b72)

  • Added missing optionalCreateAttrs for ProjectIssue. Fixed typo in ProjectTag. (72eb744)

  • Improved error reporting

  • Try to parse error response from gitlab.

  • Use one function (_raiseErrorFromResponse) to parse and raise exceptions related to errors reported by gitlab. (8e13487)

  • Improved exception-classes.

  • Added http status-code and gitlab error message to GitlabError-class.

  • Added new GitlabOperationError-class to help separate connection and authentication errors from other gitlab errors. (8351b2d)

  • Raise NotImplementedError on all cases, where can*-boolean is False (555cc45)

  • No reason to have separate _getListOrObject-method in Gitlab-class.

Changed GitlabObject-class version of _getListOrObject to classmethod. Removed _getListOrObject-method from Gitlab-class. Changed Gitlab-class to use GitlabObject-class version of _getListOrObject (90ebbeb)

  • bump version to 0.8 (296a72f)

  • “Document” the timeout option (39aa998)

  • Update the Changelog (8be5365)

  • CLI: support a timout option (1672529)

  • make sure to not display both id and idAttr (9744475)

  • ProjectLabel: use name as id attribute (f042d2f)

  • pretty_print: don’t display private attributes (fa92155)

  • Add Mika Mäenpää in the authors list (526f1be)

  • Merge pull request #45 from mjmaenpaa/labels_files

Classes for ProjectLabels and ProjectFiles (928b9f0)

  • Merge pull request #44 from mjmaenpaa/noid_objects

Support api-objects which don’t have id in api response. (afe0ab4)

  • Merge pull request #43 from mjmaenpaa/url_delete_attrs

Moved url attributes to separate list. Added list for delete attributes. (f7dfad3)

  • Merge pull request #40 from mjmaenpaa/py3

Python3 compatibility (1eccc3b)

  • Fixed object creation in list (134fc7a)

  • Classes for ProjectLabels and ProjectFiles (ad63e17)

  • Support api-objects which don’t have id in api response. (c3ab869)

  • Moved url attributes to separate list. Added list for delete attributes. (ea4c099)

  • Merge pull request #42 from mjmaenpaa/constructUrl

Moved url-construction to separate function (221f418)

  • Merge pull request #41 from mjmaenpaa/gitlab_get_exception

Gitlab.get() raised GitlabListError instead of GitlabGetError (9736e0b)

  • Moved url-construction to separate function (e14e3bf)

  • Gitlab.get() raised GitlabListError instead of GitlabGetError (ee54b3e)

  • Py3 compatibility with six (431e4bd)

  • Merge pull request #39 from mjmaenpaa/timeout

Timeout support (9f134fc)

  • Python 3 compatibility for cli-program (d714c4d)

  • Timeout support (d2e591e)

  • Python3 compatibility (15c0da5)

  • Merge pull request #38 from mjmaenpaa/currentuser_key

Changed CurrentUser.Key to use _getListOrObject-method like all other functions (4664ebd)

  • Merge pull request #37 from mjmaenpaa/list_kwargs

No reason to add kwargs to object in Gitlab.list()-method (2c86085)

  • Merge pull request #36 from mjmaenpaa/setFromDict

_setFromDict thinks False is None (4c5c39d)

  • CurrentUser.Key uses _getListOrObject-method (afcf1c2)

  • No reason to add kwargs to object in Gitlab.list()-method because GitlabObject constructor can handle them. (40ce81e)

  • _setFromDict thinks False is None (3cf35ce)

  • Added tests.

Uses httmock library to abstract away requests-library. Uses nose to actually run tests. (f458522)

  • Merge pull request #34 from tekacs/master

Update .sort to use key for Python 3.x. (ff2d84c)

  • Update .sort to use key for Python 3.x.

Rather than really dubious cmp function. (b483319)

  • Merge pull request #32 from patgmiller/master

refactor “_sanitize” for Python < 2.7 (6c4fc34)

  • refactor “_sanitize” for Python < 2.7 (89d3fa0)

  • changelog update (8846bf7)

  • bump version (3f0ac43)

  • update copyright years (c6f0a8d)

  • flake8 fixes (5d5e0f7)

  • Fix handling of boolean values

Gitlab expects an int (1 or 0) as value for boolean attributes. Transform python bool’s into int’s when creating or updating objects.

Closes #22 (d4803f9)

  • Support namespace/name for project id

Closes #28 (34d6952)

  • update AUTHORS (d38f219)

  • Merge pull request #27 from cdleonard/master

Fix encoding errors on display and update with redirected output (2b5ea46)

  • Support state_event in ProjectMilestone

Closes #30 (2281283)

  • add support for branches creation and deletion (97e2689)

  • add support for UserKey listing and deletion (09e4a64)

  • drop the module shebang (01335f3)

  • Fix encoding error when updating with redirected output

When output is redirected sys.stdout.encoding is None. Fix this by always encoding to utf-8, assuming gitlab handles that. The encoding used by the local system is irrelevant here. (ec185cf)

  • Fix encoding error when printing to redirected output

When redirecting output to a file sys.stdout.encoding is None, so use sys.getdefaultencoding() instead. (e236fd9)

  • Merge pull request #16 from locke105/master

Fix license classifier in setup.py (8ce3e30)

  • Fix license classifier in setup.py (994e464)

  • version bump

Update Changelog and AUTHORS (1fe783d)

  • projects listing: explicitly define arguments for pagination (4fcef67)

  • Merge pull request #13 from dpasqualin/master

Add support for extra parameters when listing all projects (Refs #12) (4b882b7)

  • ProjectMember: constructor should not create a User object (1c21423)

  • ids can be unicode

Fixes #15 (c6e371e)

  • Add support for extra parameters when listing all projects (Refs #12)

Signed-off-by: Diego Giovane Pasqualin <dpasqualin@c3sl.ufpr.br> (1b6c595)

  • version bump (04574f3)

  • support creation of projects for users (dc2bf5e)

  • Merge branch ‘ProjectFile’ (0ee6ca5)

  • Project: add methods for create/update/delete files (ba39e88)

  • support projects listing: search, all, owned (bd6b4ac)

  • system hooks can’t be updated (2b4924e)

  • Project.archive(): download tarball of the project (debe41a)

  • define new optional attributes for user creation (1cc7b17)

  • provide constants for access permissions in groups (7afd232)

  • update AUTHORS and Changelog (962e806)

  • Merge remote-tracking branch ‘github-mrts/master’ (7fb7c47)

  • add a Key() method for User objects (1969abb)

  • Merge pull request #10 from ksmets/master

Add SSH key for user (e31bb9e)

  • Add SSH key for user (909c10e)

  • Add support for project events. (32d4224)

  • Fix comments. (6705928)

  • Merge pull request #8 from Itxaka/master

fixed the requirements auto install from setup.py (37e6648)

  • fixed the requirements auto install from setup.py (01ade72)

  • version bump (5f0136c)

  • Add support for Gitlab 6.1 group members (71c8750)

  • minor syntax/pep8 updates (09ef68f)

  • drop leftovers from local tests (4f001b4)

  • Implement Gitlab 6.1 new methods

  • Project: tree, blob

  • ProjectCommit: diff, blob (c9aedf2)

  • ProjectMergeRequest: fix Note() method (4006ab2)

  • Allow to get a project commit (GitLab 6.1) (6b0c678)

  • Fix strings encoding (Closes #6) (64cead6)

  • version bump (ceda87a)

  • doc updates (b73c92d)

  • Merge branch ‘header-private-token’ of https://github.com/dekimsey/python-gitlab into token_in_header (9adb4fa)

  • provide a ChangeLog (2d5342b)

  • provide a AUTHORS file (7c85fb7)

  • cli: support ssl_verify config option (147a569)

  • Merge pull request #5 from marbindrakon/ssl_verify_option

Add ssl_verify option to Gitlab object. (bb7ba7a)

  • Add ssl_verify option to Gitlab object. Defauls to True (309f1fe)

  • Merge pull request #4 from erikjwaxx/master

Correct url for merge requests API. (7431d91)

  • Correct url for merge requests API. (5090ef4)

  • version bump (d1cd3dc)

  • provide a pip requirements.txt (c6fd8e8)

  • drop some debug statements (2807006)

  • include COPYING in distribution (d65b684)

  • Merge pull request #1 from dekimsey/team-api

Addded API for team access. (8f65cf8)

  • Merge remote-tracking branch ‘samcday/teams’ into team-api

Conflicts: gitlab.py (cb5b754)

  • Addded API for team access. (8a22958)

  • Use PRIVATE-TOKEN header for passing the auth token (d39c471)

  • improve pretty_print() (05ab473)

  • manage project branch protection with the cmd line (53562b3)

  • rework the script code organization (33c771d)

  • rework the cmd line options (02bd7cd)

  • make –verbose behave like –fancy (a9b5bf4)

  • fix parsing of options (2321631)

  • gitlab: make the current-user option work (4c998ea)

  • README: document –page and –per-page (a7f2065)

  • listing: list the –page and –per-page options (079c107)

  • ProjectBranch: commit is an other object (7e7b29c)

  • README: use - instead of _ in examples (b4bc9df)

  • drop the debian/ dir from master (7be3d54)

  • drop the tests dir, this is useless (7c358d3)

  • gitlab: be less verbose by default

Provide a –fancy option to output more data on list/get/create queries. (3b15c6d)

  • pretty_print: use - instead of _ (41b6dba)

  • id attr might not available (7175772)

  • allow to use dash (-) instead of underscore (_) in attribute names (5a20efb)

  • Merge branch ‘master’ into debian (93d5147)

  • provide a manifest for distribution (1c1702d)

  • update version in changelog (d9d6e0c)

  • Merge branch ‘master’ into debian (23753df)

  • gitlab: autogenerate some doc (39a4a20)

  • gitlab: update the object syntax (9ca47aa)

  • provide debian packaging (ef44b84)

  • python 3 support (e7ba350)

  • object creation: print the created object (c6174e5)

  • return explicit error message on 404 (a04a5a5)

  • gitlab: warn the user if an action cannot be performed (34e4304)

  • minor syntax change: canGetList => canList (49eab91)

  • setup a list of mandatory attributes for list and get methods (5dda6e6)

  • Manually parse the arguments

We can use a more common syntax (– prefix for options) this way. (a8072d9)

  • install the gitlab script (dd22ce1)

  • describe the gitlab script in README (204f681)

  • provide a basic CLI (a205914)

  • provide a ProjectSnippet.Content() method (72e097d)

  • add a GitlabObject.pretty_print method (abf1b0d)

  • deal with ids as strings (bc9d440)

  • raise an exception if deletion fails (4ee9c8c)

  • Allow creation of objects using the “hidden API” (1d55e67)

  • Basic team support. (5388d19)

  • Check the needed attributes to create objects

Provide a required and optional arguments lists for each object that can be created using the API (123a01e)

  • add a json() method to GitlabObject’s (8d65870)

  • implement project transfer support (1625e55)

  • add support for project deploy keys (1e3061c)

  • support for system hooks (42bef0a)

  • fix use of json() method from requests (af84700)

  • unittest for SSH keys (7631e5e)

  • some unit tests! (967ea88)

  • restore Gitlab.Issue() prototype (561f349)

  • move documentation and todo to README.md (c10b01e)

  • implement protect/unprotect for branches (a02180d)

  • typo (dd210be)

  • never add page and per_page attributes to the objects (96bf2b1)

  • ids for single items might be str (928d4fa)

  • add a pagination example (74ec951)

  • Allow to pass additional args to list constructors

This is needed mostly for pagination support. (0149020)

  • spacing (571ab0e)

  • fix the token authentication (938b1e6)

  • add a _ from private attibutes (523d764)

  • docstrings for the Gitlab class (046baf2)

  • cosmetics: make pep8 happy (9b64650)

  • add missing raise keywork (4d11843)

  • add a setup.py script (0dd1ede)

  • fix LGPL header and provide module informations (96e341e)

  • rework authentication API (eb4cd36)

  • Rework the API

objects can be created using the usual syntax, with one optioanl argument (int to get one object, dict to create an object, nothing to get a list of items). A save() method creates/updates the object on the server. A delete() method removes it from the server. (653843d)

  • link GitLab and User classes to their possible children (d1f80da)

  • raise an exception on 401 return code (01152da)

  • drop Session() and add a Gitlab.authenticate() method (c4920ee)

  • create Note classes linked to parent objetcs (bf25928)

  • add support for notes (0172900)

  • implement the Session() method (f188dcb)

  • add methods to Project objects to access related objects (ab82226)

  • store a mirror of the gitlab instance in created objects (02afd17)

  • Rework object creation from json (1fddcd2)

  • initial import (1d7e85d)