Updating mirror_overwrite_diverged_branches is not persisted

Summary

Updating gitlab.v4.objects.Project.only_mirror_protected_branches is not persisted

Steps to reproduce

Python3:

import gitlab
import urllib.parse

gl = gitlab.Gitlab("https://gitlab.ourcompany.com/", private_token="<mytoken>")
gl_project = gl.projects.get(647, lazy=True)
password = urllib.parse.quote("<mypassword>", safe="")
gl_project.import_url = f"https://{<myusername>}:{password}@git-codecommit.eu-central-1.amazonaws.com/v1/repos/{gl_project.name}"
gl_project.mirror = True
gl_project.mirror_user_id = 68
gl_project.mirror_overwrite_diverged_branches = True
gl_project.only_mirror_protected_branches = False
gl_project.save()

Example Project

What is the current bug behavior?

No error, but no effect either. Nothing is updated. When only calling gl_project.mirror_overwrite_diverged_branches = True (i.e. when not setting import_url), the GitLab server complains with status 400.

What is the expected correct behavior?

mirror_overwrite_diverged_branches should be persisted as True.

Relevant logs and/or screenshots

Output of checks

Results of GitLab environment info

GitLab 13.0.5, onprem, premium subscription

Results of GitLab application Check

Possible fixes