-
Notifications
You must be signed in to change notification settings - Fork 644
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Namespace Error / Namespace Ignored #2895
Comments
It's not correct in my view to do it like this, but after creating it I could in theory do:
|
I don't know the answer to your question. But I do recommend looking at the upstream documentation as that is the source of truth for the API. https://docs.gitlab.com/ee/api/projects.html That might have some info on what is going wrong. |
Also using |
I guess the issue is that I try to create a new Project as a User (admin only). But maybe, by creating Project as a User, it will use the user's namespace only. This works correctly:
But then of course I need to manually add the User Later:
And this has the additional Issue that the User will NOT be the owner of the Repository. EDIT 1: Actually this might just be what I did previously using the now deprecated gitlab BASH API. EDIT 2: Final Solution
|
I think you got things working. If so I'm glad to hear that. One thing I did notice in your very first example the code does say
Just pointing that out in case somehow And if the |
@JohnVillalovos no, I was using When I used |
@luckylinux One thought. Is it possible the user doesn't have permissions to that namespace? Also maybe print out the value that was received from:
In case the group was not the group you were expecting from the search. |
Description of the problem, including code/CLI snippet
I am getting started with this Library and most Things work quite well.
I cannot say the same about the Namespace/Groups though.
Code according to the Documentation:
Result:
If I use
namespace
instead ofnamespace_id
:Then I get:
Expected Behavior
Able to create a Project in the Requested Namespace.
Actual Behavior
Either an Error Occurs (if Code is according to the Documentation), or the
namespace
is completely ignored and thename
of the Project is used instead.I attempted to fix this later by trying to Update the Project:
This however would not do anything 😞.
Specifications
4.6.0
gitlab-ce 17.0.2-ce.0
The text was updated successfully, but these errors were encountered: