Skip to content

Releases: python-gitlab/python-gitlab

v4.13.0

08 Oct 13:28
Compare
Choose a tag to compare

v4.13.0 (2024-10-08)

Chore

  • chore(deps): update dependency pre-commit to v4 (#3008)

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

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

Feature

  • feat(api): add support for project Pages API (0ee0e02)

v4.12.2

01 Oct 17:19
Compare
Choose a tag to compare

v4.12.2 (2024-10-01)

Fix

  • fix: raise GitlabHeadError in project.files.head() method (#3006)

When an error occurs, raise GitlabHeadError in
project.files.head() method.

Closes: #3004 (9bf26df)

v4.12.1

30 Sep 17:36
Compare
Choose a tag to compare

v4.12.1 (2024-09-30)

Chore

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

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

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.4.1-ee.0 (64eed5d)

Fix

  • fix(ci): do not rely on GitLab.com runner arch variables (#3003) (c848d12)

  • fix(files): correctly raise GitlabGetError in get method (190ec89)

v4.12.0

28 Sep 00:55
Compare
Choose a tag to compare

v4.12.0 (2024-09-28)

Chore

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

  • chore: update pylint to 3.3.1 and resolve issues (#2997)

pylint 3.3.1 appears to have added "too-many-positional-arguments"
check with a value of 5.

I don't disagree with this, but we have many functions which exceed
this value. We might think about converting some of positional
arguments over to keyword arguments in the future. But that is for
another time.

For now disable the check across the project. (a0729b8)

  • chore(deps): update dependency types-setuptools to v75 (a2ab54c)

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.4.0-ee.0 (8601808)

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

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.3.2-ee.0 (5cd1ab2)

Feature

  • feat(build): build multi-arch images (#2987) (29f617d)

  • feat: introduce related_issues to merge requests (#2996) (174d992)

Fix

  • fix(api): head requests for projectfilemanager (#2977)

  • fix(api): head requests for projectfilemanager


Co-authored-by: Patrick Evans <patrick.evans@gehealthcare.com>
Co-authored-by: Nejc Habjan <hab.nejc@gmail.com> (96a18b0)

v4.11.1

13 Sep 13:32
Compare
Choose a tag to compare

v4.11.1 (2024-09-13)

Fix

  • fix(client): ensure type evaluations are postponed (b41b2de)

v4.11.0

13 Sep 12:28
Compare
Choose a tag to compare

v4.11.0 (2024-09-13)

Chore

  • chore(pre-commit): add deps (fe5e608)

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

  • chore(deps): update dependency types-setuptools to v74 (bdfaddb)

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

Documentation

  • docs(objects): fix typo in get latest pipeline (b9f5c12)

Feature

  • feat(client): make retries configurable in GraphQL (145870e)

  • feat(client): add retry handling to GraphQL client (8898c38)

  • feat(api): add exclusive GET attrs for /projects/:id/members (e637808)

  • feat: add a minimal GraphQL client (d6b1b0a)

  • feat(api): add exclusive GET attrs for /groups/:id/members (d44ddd2)

Refactor

  • refactor(client): move retry logic into utility (3235c48)

v4.10.0

28 Aug 00:52
Compare
Choose a tag to compare

v4.10.0 (2024-08-28)

Chore

  • chore(release): track tags for renovate (d600444)

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to 17c75b7 (12caaa4)

  • chore(deps): update dependency types-setuptools to v73 (d55c045)

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

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.3.1-ee.0 (3fdd130)

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

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.3.0-ee.0 (e5a46f5)

  • chore(deps): update dependency myst-parser to v4 (930d4a2)

  • chore(deps): update dependency sphinx to v8 (cb65ffb)

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.2.2-ee.0 (b2275f7)

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

Documentation

  • docs(faq): correct the attribute fetching example

There is an example about object attributes in the FAQ. It shows how to
properly fetch all attributes of all projects, by using list() followed
by a get(id) call.

Unfortunately this example used a wrong variable name, which caused it
not to work and which could have made it slightly confusing to readers.
This commit fixes that, by changing the variable name.

Now the example uses one variable for two Python objects. As they
correspond to the same GitLab object and the intended behavior is to
obtain that very object, just with all attributes, this is fine and is
probably what readers will find most useful in this context. (43a16ac)

Feature

  • feat(api): project/group hook test triggering

Add the ability to trigger tests of project and group hooks.

Fixes #2924 (9353f54)

Test

  • test(cli): allow up to 30 seconds for a project export

Before we allowed a maximum of around 15 seconds for the
project-export. Often times the CI was failing with this value.

Change it to a maximum of around 30 seconds. (bdc155b)

v4.9.0

06 Aug 12:12
Compare
Choose a tag to compare

v4.9.0 (2024-08-06)

Chore

  • chore(deps): update pre-commit hook maxbrunet/pre-commit-renovate to v38 (f13968b)

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

  • chore(deps): update dependency types-setuptools to v71 (d6a7dba)

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to 0dcddac (eb5c6f7)

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.2.1-ee.0 (d13a656)

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

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to e2355e1 (eb18552)

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

  • chore(ci): make pre-commit check happy

pre-commit incorrectly wants double back-quotes inside the code
section. Rather than fight it, just use single quotes. (67370d8)

Feature

  • feat(snippets): add support for listing all instance snippets (64ae61e)

v4.8.0

16 Jul 14:14
Compare
Choose a tag to compare

v4.8.0 (2024-07-16)

Chore

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.1.2-ee.0 (6fedfa5)

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

  • chore(ci): specify name of "stale" label

Saw the following error in the log:
[#2618] Removing the label "Stale" from this issue...
##[error][#2618] Error when removing the label: "Label does not exist"

My theory is that the case doesn't match ("Stale" != "stale") and that
is why it failed. Our label is "stale" so update this to match.
Thought of changing the label name on GitHub but then would also
require a change here to the "any-of-labels". So it seemed simpler to
just change it here.

It is confusing though that it detected the label "stale", but then
couldn't delete it. (44f62c4)

  • chore(ci): stale: allow issues/PRs that have stale label to be closed

If a stale label is manually applied, allow the issue or PR to be
closed by the stale job.

Previously it would require the stale label and to also have one of
'need info' or 'Waiting for response' labels added. (2ab88b2)

  • chore(ci): use codecov token when available (b74a6fb)

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to fe6cc89 (3f3ad80)

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

  • chore: add show_caller argument to utils.warn()

This allows us to not add the caller's location to the UserWarning
message. (7d04315)

  • chore: use correct type-hint for die() (9358640)

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.1.1-ee.0 (5e98510)

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to c7c3b69 (23393fa)

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

Documentation

  • docs: document how to use sudo if modifying an object

Add a warning about using sudo when saving.

Give an example of how to get an object, modify it, and then save
it using sudo

Closes: #532 (d509da6)

  • docs: variables: add note about filter for updating

Add a note about using filter when updating a variable.

Closes: #2835
Closes: #1387
Closes: #1125 (c378817)

Feature

  • feat(api): add support for project cluster agents (32dbc6f)

  • feat(api): add support for container registry protection rules (6d31649)

  • feat(api): add support for package protection rules (6b37811)

  • feat(api): add support for commit sequence (1f97be2)

Fix

  • fix: issues closed_by()/related_merge_requests() use http_list

The closed_by() and related_merge_requests() API calls return
lists. So use the http_list() method.

This will also warn the user if only a subset of the data is returned. (de2e4dd)

  • fix: Have participants() method use http_list()

Previously it was using http_get() but the participants API
returns a list of participants. Also by using this then we will warn
if only a subset of the participants are returned.

Closes: #2913 (d065275)

  • fix(files): CR: add explicit comparison to None

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

  • fix(files): make ref parameter optional in get raw file api

The ref parameter was made optional in gitlab v13.11.0. (00640ac)

  • fix(cli): generate UserWarning if list does not return all entries

Previously in the CLI, calls to list() would have get_all=False by
default. Therefore hiding the fact that not all items are being
returned if there were more than 20 items.

Added --no-get-all option to list actions. Along with the already
existing --get-all.

Closes: #2900 (e5a4379)

Refactor

  • refactor(package_protection_rules): add missing attributes (c307dd2)

Test

  • test(registry): disable functional tests for unavailable endpoints (ee393a1)

  • test(files): test with and without ref parameter in test case (f316b46)

  • test(files): omit optional ref parameter in test case (9cb3396)

  • test(fixtures): remove deprecated config option (2156949)

v4.7.0

28 Jun 00:47
Compare
Choose a tag to compare

v4.7.0 (2024-06-28)

Chore

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

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

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.0.2-ee.0 (51779c6)

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to 6b7558f (fd0f0b0)

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

  • chore(deps): update dependency types-setuptools to v70 (7767514)

  • chore(deps): update gitlab/gitlab-ee docker tag to v17.0.1-ee.0 (df0ff4c)

  • chore(deps): update python-semantic-release/upload-to-gh-release digest to 477a404 (02a551d)

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

  • chore: add a help message for gitlab project-key enable

Add some help text for gitlab project-key enable. This both adds
help text and shows how to use the new help feature.

Example:

$ gitlab project-key --help
usage: gitlab project-key [-h] {list,get,create,update,delete,enable} ...

options:
-h, --help show this help message and exit

action:
{list,get,create,update,delete,enable}
Action to execute on the GitLab resource.
list List the GitLab resources
get Get a GitLab resource
create Create a GitLab resource
update Update a GitLab resource
delete Delete a GitLab resource
enable Enable a deploy key for the project (1291dbb)

  • chore: sort CLI behavior-related args to remove

Sort the list of CLI behavior-related args that are to be removed. (9b4b0ef)

Feature

  • feat(api): add support for latest pipeline (635f5a7)

  • feat: add --no-mask-credentials CLI argument

This gives the ability to not mask credentials when using the
--debug argument. (18aa1fc)

Fix

  • fix: add ability to add help to custom_actions

Now when registering a custom_action can add help text if desired.

Also delete the VerticalHelpFormatter as no longer needed. When the
help value is set to None or some other value, the actions will get
printed vertically. Before when the help value was not set the actions
would all get put onto one line. (9acd2d2)