-
Description of the problem, including code/CLI snippetI am trying to create projects in subgroups by a python script using And Settings -> * Repository* - > Protected branches looks like this: The creation of the project is done by
As a result I get a new project. The result of a
However, the
I get
with my main problem being: Expected BehaviorI would expect the Actual BehaviorThe Specifications
Is this the desired behavior? If so, how can I protect the |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
My first thought is that it is an upstream GitLab issue.
Upstream API document: https://docs.gitlab.com/ee/api/projects.html#create-a-project As I have never used a template before, are you sure that using a template means it will create a protected branch? As a workaround you can protect the branch after creating the project: https://python-gitlab.readthedocs.io/en/stable/gl_objects/protected_branches.html#examples |
Beta Was this translation helpful? Give feedback.
-
Well, from my understanding the created project should be a quasi-copy of the template source. Also, I would expect any newly created project to have a protected main branch.
Thanks, I saw that already. Re-tried it and now I can protected the main branch after project creation with
|
Beta Was this translation helpful? Give feedback.
Well, from my understanding the created project should be a quasi-copy of the template source. Also, I would expect any newly created project to have a protected main branch.
Thanks, I saw that already. Re-tried it and now I can protected the main branch after project creation with